Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add restart_coszen namelist option #480

Merged
merged 38 commits into from
Jul 17, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
183218a
updated orbital calculations needed for cesm
Apr 23, 2020
10e7c20
fixed problems in updated orbital calculations needed for cesm
Apr 29, 2020
ce8e5a9
update CICE6 to support coupling with UFS
apcraig May 10, 2020
8f0b5ee
Merge pull request #2 from apcraig/ufs01
dabail10 May 10, 2020
7ac0e3d
Merge pull request #1 from ESCOMP/nuopc
DeniseWorthen May 12, 2020
80c9e6e
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 May 19, 2020
53715ea
put in changes so that both ufsatm and cesm requirements for potentia…
May 25, 2020
7e43703
Merge pull request #3 from mvertens/mvertens/nuopc
dabail10 May 26, 2020
f41f1e9
Merge remote-tracking branch 'upstream/nuopc' into HEAD
DeniseWorthen Jun 22, 2020
e70d1ab
update icepack submodule
DeniseWorthen Jun 22, 2020
308a1d4
Revert "update icepack submodule"
DeniseWorthen Jun 22, 2020
7848fdf
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jun 24, 2020
6982ee4
Merge remote-tracking branch 'upstream/nuopc' into HEAD
DeniseWorthen Jun 25, 2020
089f60f
update comp_ice.backend with temporary ice_timers fix
DeniseWorthen Jun 25, 2020
6affdcf
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jun 29, 2020
b5a6058
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jul 1, 2020
415df0e
Merge branch 'nuopc' of https://github.com/ESCOMP/CICE into nuopc
dabail10 Jul 1, 2020
b4da8a6
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jul 1, 2020
239c7de
Merge branch 'nuopc' of https://github.com/ESCOMP/CICE into nuopc
dabail10 Jul 1, 2020
ad03424
Fix threading problem in init_bgc
dabail10 Jul 1, 2020
73e7774
Fix additional OMP problems
dabail10 Jul 1, 2020
46fcfba
changes for coldstart running
DeniseWorthen Jul 2, 2020
c762336
Move the forapps directory
dabail10 Jul 2, 2020
6bccf71
remove cesmcoupled ifdefs
DeniseWorthen Jul 2, 2020
902e883
Fix logging issues for NUOPC
dabail10 Jul 2, 2020
178693a
Merge branch 'nuopc' of https://github.com/ESCOMP/CICE into nuopc
dabail10 Jul 2, 2020
b4afd2e
removal of many cpp-ifdefs
Jul 4, 2020
3a1b88b
fix compile errors
DeniseWorthen Jul 4, 2020
41855fd
fixes to get cesm working
Jul 4, 2020
aea1aa8
update to latest nuopc changes
Jul 4, 2020
e4c989c
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jul 6, 2020
30a81cc
fixed white space issue
Jul 7, 2020
8ebdda9
Merge pull request #4 from mvertens/nuopc
dabail10 Jul 7, 2020
27dd3b7
Add restart_coszen namelist option
dabail10 Jul 7, 2020
6b4a277
Merge branch 'nuopc' into coszen
dabail10 Jul 7, 2020
c1065bc
Merge branch 'master' of https://github.com/CICE-Consortium/CICE into…
dabail10 Jul 15, 2020
5062da5
Move restart_coszen to forcing_nml
dabail10 Jul 16, 2020
a4d2cd2
Update documentation on restart_coszen
dabail10 Jul 16, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fixes to get cesm working
  • Loading branch information
Mariana Vertenstein committed Jul 4, 2020
commit 41855fde3b5a463b20455cc4bfb8a5af6a16436f
7 changes: 3 additions & 4 deletions cicecore/drivers/nuopc/cmeps/cice_wrapper_mod.F90
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
module cice_wrapper_mod

#ifdef CESMCOUPLED
use perf_mod, only : t_startf, t_stopf, t_barrierf
#endif

use perf_mod , only : t_startf, t_stopf, t_barrierf
use shr_file_mod , only : shr_file_getlogunit, shr_file_setlogunit

#else
contains

#ifndef CESMCOUPLED
! These are just stub routines put in place to remove

subroutine shr_file_setLogUnit(nunit)
Expand Down
159 changes: 53 additions & 106 deletions cicecore/drivers/nuopc/cmeps/ice_prescribed_mod.F90
Original file line number Diff line number Diff line change
@@ -1,28 +1,34 @@
module ice_prescribed_mod

! !DESCRIPTION:
! The prescribed ice model reads in ice concentration data from a netCDF
! file. Ice thickness, temperature, the ice temperature profile are
! prescribed. Air/ice fluxes are computed to get surface temperature,
! Ice/ocean fluxes are set to zero, and ice dynamics are not calculated.
! Regridding and data cycling capabilities are included.

#ifndef CESMCOUPLED

use ice_kinds_mod

implicit none
private ! except

! MEMBER FUNCTIONS:
public :: ice_prescribed_init ! initialize input data stream

logical(kind=log_kind), parameter, public :: prescribed_ice = .false. ! true if prescribed ice

#else
contains
! This is a stub routine for now
subroutine ice_prescribed_init(mpicom, compid, gindex)
integer(kind=int_kind), intent(in) :: mpicom
integer(kind=int_kind), intent(in) :: compid
integer(kind=int_kind), intent(in) :: gindex(:)
! do nothing
end subroutine ice_prescribed_init

! !DESCRIPTION:
! The prescribed ice model reads in ice concentration data from a netCDF
! file. Ice thickness, temperature, the ice temperature profile are
! prescribed. Air/ice fluxes are computed to get surface temperature,
! Ice/ocean fluxes are set to zero, and ice dynamics are not calculated.
! Regridding and data cycling capabilities are included.
#else

! !USES:
use shr_nl_mod, only : shr_nl_find_group_name
use shr_nl_mod , only : shr_nl_find_group_name
use shr_strdata_mod
use shr_dmodel_mod
use shr_string_mod
Expand All @@ -31,24 +37,23 @@ module ice_prescribed_mod
use shr_mct_mod
use mct_mod
use pio

use ice_broadcast
use ice_communicate , only : my_task, master_task, MPI_COMM_ICE
use ice_communicate , only : my_task, master_task, MPI_COMM_ICE
use ice_kinds_mod
use ice_fileunits
use ice_exit , only : abort_ice
use ice_domain_size , only : nx_global, ny_global, ncat, nilyr, nslyr, max_blocks
use ice_exit , only : abort_ice
use ice_domain_size , only : nx_global, ny_global, ncat, nilyr, nslyr, max_blocks
use ice_constants
use ice_blocks , only : nx_block, ny_block, block, get_block
use ice_domain , only : nblocks, distrb_info, blocks_ice
use ice_grid , only : TLAT, TLON, hm, tmask, tarea, grid_type, ocn_gridcell_frac
use ice_calendar , only : idate, sec, calendar_type
use ice_arrays_column, only : hin_max
use ice_blocks , only : nx_block, ny_block, block, get_block
use ice_domain , only : nblocks, distrb_info, blocks_ice
use ice_grid , only : TLAT, TLON, hm, tmask, tarea, grid_type, ocn_gridcell_frac
use ice_calendar , only : idate, sec, calendar_type
use ice_arrays_column , only : hin_max
use ice_read_write
use ice_exit, only: abort_ice
use icepack_intfc, only: icepack_warnings_flush, icepack_warnings_aborted
use icepack_intfc, only: icepack_query_tracer_indices, icepack_query_tracer_sizes
use icepack_intfc, only: icepack_query_parameters
use ice_exit , only: abort_ice
use icepack_intfc , only: icepack_warnings_flush, icepack_warnings_aborted
use icepack_intfc , only: icepack_query_tracer_indices, icepack_query_tracer_sizes
use icepack_intfc , only: icepack_query_parameters

implicit none
private ! except
Expand All @@ -59,59 +64,38 @@ module ice_prescribed_mod
public :: ice_prescribed_phys ! set prescribed ice state and fluxes

! !PUBLIC DATA MEMBERS:
logical(kind=log_kind), public :: prescribed_ice ! true if prescribed ice

logical(kind=log_kind), public :: prescribed_ice ! true if prescribed ice
integer(kind=int_kind),parameter :: nFilesMaximum = 400 ! max number of files
integer(kind=int_kind) :: stream_year_first ! first year in stream to use
integer(kind=int_kind) :: stream_year_last ! last year in stream to use
integer(kind=int_kind) :: model_year_align ! align stream_year_first
! with this model year

character(len=char_len_long) :: stream_fldVarName
character(len=char_len_long) :: stream_fldFileName(nFilesMaximum)
character(len=char_len_long) :: stream_domTvarName
character(len=char_len_long) :: stream_domXvarName
character(len=char_len_long) :: stream_domYvarName
character(len=char_len_long) :: stream_domAreaName
character(len=char_len_long) :: stream_domMaskName
character(len=char_len_long) :: stream_domFileName
character(len=char_len_long) :: stream_mapread
logical(kind=log_kind) :: prescribed_ice_fill ! true if data fill required

type(shr_strdata_type) :: sdat ! prescribed data stream
character(len=char_len_long) :: fldList ! list of fields in data stream
real(kind=dbl_kind),allocatable :: ice_cov(:,:,:) ! ice cover

! real (kind=dbl_kind), parameter :: &
! cp_sno = 0.0_dbl_kind & ! specific heat of snow (J/kg/K)
! , rLfi = Lfresh*rhoi & ! latent heat of fusion ice (J/m^3)
! , rLfs = Lfresh*rhos & ! latent heat of fusion snow (J/m^3)
! , rLvi = Lvap*rhoi & ! latent heat of vapor*rhoice (J/m^3)
! , rLvs = Lvap*rhos & ! latent heat of vapor*rhosno (J/m^3)
! , rcpi = cp_ice*rhoi & ! heat capacity of fresh ice (J/m^3)
! , rcps = cp_sno*rhos & ! heat capacity of snow (J/m^3)
! , rcpidepressT = rcpi*depressT & ! param for finding T(z) from q (J/m^3)
! , rLfidepressT = rLfi*depressT ! param for heat capacity (J deg/m^3)
! ! heat capacity of sea ice, rhoi*C=rcpi+rLfidepressT*salinity/T^2
#endif
integer(kind=int_kind) :: stream_year_first ! first year in stream to use
integer(kind=int_kind) :: stream_year_last ! last year in stream to use
integer(kind=int_kind) :: model_year_align ! align stream_year_first with this model year
character(len=char_len_long) :: stream_fldVarName
character(len=char_len_long) :: stream_fldFileName(nFilesMaximum)
character(len=char_len_long) :: stream_domTvarName
character(len=char_len_long) :: stream_domXvarName
character(len=char_len_long) :: stream_domYvarName
character(len=char_len_long) :: stream_domAreaName
character(len=char_len_long) :: stream_domMaskName
character(len=char_len_long) :: stream_domFileName
character(len=char_len_long) :: stream_mapread
logical(kind=log_kind) :: prescribed_ice_fill ! true if data fill required
type(shr_strdata_type) :: sdat ! prescribed data stream
character(len=char_len_long) :: fldList ! list of fields in data stream
real(kind=dbl_kind),allocatable :: ice_cov(:,:,:) ! ice cover

!=======================================================================
contains
!===============================================================================

#ifdef CESM_COUPLED

subroutine ice_prescribed_init(mpicom, compid, gindex)

use shr_pio_mod, only : shr_pio_getiotype, shr_pio_getiosys, shr_pio_getioformat
! !DESCRIPTION:
! Prescribed ice initialization - needed to
! work with new shr_strdata module derived type

! !INPUT/OUTPUT PARAMETERS:
use shr_pio_mod, only : shr_pio_getiotype, shr_pio_getiosys, shr_pio_getioformat

implicit none
include 'mpif.h'

! !nput/output parameters:
integer(kind=int_kind), intent(in) :: mpicom
integer(kind=int_kind), intent(in) :: compid
integer(kind=int_kind), intent(in) :: gindex(:)
Expand Down Expand Up @@ -263,7 +247,6 @@ subroutine ice_prescribed_init(mpicom, compid, gindex)
end subroutine ice_prescribed_init

!=======================================================================

subroutine ice_prescribed_run(mDateIn, secIn)

! !DESCRIPTION:
Expand Down Expand Up @@ -335,25 +318,12 @@ subroutine ice_prescribed_run(mDateIn, secIn)
end subroutine ice_prescribed_run

!===============================================================================
!BOP ===========================================================================
!
! !IROUTINE: ice_prescribed_phys -- set prescribed ice state and fluxes
!
! !DESCRIPTION:
!
! Set prescribed ice state using input ice concentration;
! set surface ice temperature to atmospheric value; use
! linear temperature gradient in ice to ocean temperature.
!
! !REVISION HISTORY:
! 2005-May-23 - J. Schramm - Updated with data models
! 2004-July - J. Schramm - Modified to allow variable snow cover
! 2001-May - B. P. Briegleb - Original version
!
! !INTERFACE: ------------------------------------------------------------------

subroutine ice_prescribed_phys

! Set prescribed ice state using input ice concentration;
! set surface ice temperature to atmospheric value; use
! linear temperature gradient in ice to ocean temperature.

! !USES:
use ice_flux
use ice_state
Expand Down Expand Up @@ -395,20 +365,6 @@ subroutine ice_prescribed_phys
if (icepack_warnings_aborted()) call abort_ice(error_message=subname, &
file=__FILE__, line=__LINE__)

!-----------------------------------------------------------------
! Initialize ice state
!-----------------------------------------------------------------

! TODO - can we now get rid of the following???

! aicen(:,:,:,:) = c0
! vicen(:,:,:,:) = c0
! eicen(:,:,:,:) = c0

! do nc=1,ncat
! trcrn(:,:,nt_Tsfc,nc,:) = Tf(:,:,:)
! enddo

!-----------------------------------------------------------------
! Set ice cover over land to zero, not sure if this should be
! be done earier, before time/spatial interp??????
Expand Down Expand Up @@ -554,7 +510,6 @@ subroutine ice_prescribed_phys
end subroutine ice_prescribed_phys

!===============================================================================

subroutine ice_prescribed_set_domain( lsize, mpicom, gsmap_i, dom_i )

! Arguments
Expand Down Expand Up @@ -653,14 +608,6 @@ subroutine ice_prescribed_set_domain( lsize, mpicom, gsmap_i, dom_i )

end subroutine ice_prescribed_set_domain

#else
! This is a stub routine for now
subroutine ice_prescribed_init(mpicom, compid, gindex)
integer(kind=int_kind), intent(in) :: mpicom
integer(kind=int_kind), intent(in) :: compid
integer(kind=int_kind), intent(in) :: gindex(:)
! do nothing
end subroutine ice_prescribed_init
#endif

end module ice_prescribed_mod