wiki:forced_nemo

preparing a forced NEMO ORCA2 LIM3 configuration

The preparation is very similar to setting the coupled configuration with ORCA2 LIM3 and LMDZ6.

Get the latest IPSLCM6

Make a directory and dowload modipsl:

mkdir SWZ_COCOA_ORCA2LIM3FR
cd SWZ_COCOA_ORCA2LIM3FR
svn_ano

If you set your environment as indicated in the IGCMG documentation you should have the svn_ano alias.

Install the latest IPSLCM6 model:

cd modipsl/util
./model -h

to see the list of available IPSLCM6-LR configurations.

Suppose the latest is 6.1.9, run:

./model IPSLCM6.1.9-LR

to download it.

Prepare the Makefile to compile NEMO in ORCA2_LIM3 without PISCES

As for IPSLCM6 you need to prepare a new configuration directory in modeles/NEMOGCM/CONFIG.

We will use ORCA1_LIM3_PISCES as the reference configuration.

Execute these lines:

./makenemo -n ORCA2_LIM3_PISCES -r ORCA1_LIM3_PISCES -m X64_IRENE -j0
./makenemo -n ORCA2_LIM3_PISCES -m X64_IRENE clean

Your ORCA2_LIM3 configuration is ready. Removing PISCES will be taken care of in the Makefile.

Go back to config/IPSLCM6 and edit Makefile. Be careful that the spacing for sections must be with a TAB character.

Modify the all : section like this to make ORCA2LIM3COCOA the default configuration:

all : 
    if [ -s ./.resol ] ; then $(M_K) `head -1 .resol` ; else $(M_K) ORCA2LIM3COCOA ; fi

Add a new ORCA2LIM3COCOA configuration:

ORCA2LIM3COCOA :
    $(M_K) ORCA2LIM3NOPISC

Add a new ORCA2LIM3NOPISC section:

ORCA2LIM3NOPISC : xios orca2lim3nopisc  verif
    echo "ORCA2LIM3" >.resol
    echo "$(LIB_MPI)" >.libmpi

Add the orac2lim3nopisc rules to compile NEMO:

orca2lim3nopisc:  ../../modeles/NEMOGCM/CONFIG
    (cd ../../modeles/NEMOGCM/CONFIG; cp ../../../config/IPSLCM6/SOURCES/NEMO/arch-${FCM_ARCH}.fcm ../ARCH/. ; cp ../../../config/IPSLCM6/SOURCES/NEMO/*.cfg ../TOOLS/COMPILE/. ; ./makenemo -m ${FCM_ARCH} -n ORCA2_LIM3_PISCES -d "OPA_SRC LIM_SRC_3 NST_SRC" -e "$(MYSRC_DIR)/SOURCES/NEMO" -j16 add_key "key_lim3 key_xios2 key_diahth key_diaar5 key_mpp_rep" del_key "key_diaobs key_asminc key_lim2 key_nosignedzero" ; cp ORCA2_LIM3_PISCES/BLD/bin/nemo.exe ../../../bin/opa ; )

Your makefile is ready to compile NEMO in the ORCA2_LIM3 configuration. You may remove or keep key_mpp_rep depending what you intend to do.

Modify your sources for Schwarz

Follow the instructions in this link to update your sources for Schwarz looping.

Set an experiment

You can install a piControl_TEST experiment.

In your config/IPSLCM6 directory do:

cp EXPERIMENTS/IPSLCM/piControl_TEST/config.card .

Modify config.card

Set the experiment Name:

JobName= My-piControl-TEST-XP

Install the new experiment directory:

../../libIGCM/ins_job

Go to My-piControl-TEST-XP and modify config.card.

Set the Ocean resolution to ORCA2:

#============================
ORCA_version=ORCA2
#============================

Keep only the components OCE, ICE and IOS, remove the rest:

#========================================================================
#D-- Restarts -
[Restarts]
#D- by default: config.card describes no restart for all components 
#D-             ie start from Levitus or limit files
#D- If you want to restart all components from the same simulation,
#D-      put OveRule flag to 'y' and set the next 3 parameters
OverRule=y
#D- Last day of the experience used as restart for all components
RestartDate=1850-12-31
#D- Define restart simulation name for all components
RestartJobName=ORCA2LIM3INIT
#D- Path Server Group Login
RestartPath=/ccc/scratch/cont003/gen0239/nguyens/IGCM_OUT/IPSLCM6/TEST/piControl

#========================================================================
#D-- OCE -
[OCE]
WriteFrequency="HF 1D 5D 1M"
# If config_Restarts_OverRule == 'n' next 4 params are read
Restart= n
#-- Last day of the experience used as restart for this component if Restart=y
RestartDate=1849-12-31
#D- Define restart simulation name for this component
RestartJobName=CM61-pre-pi-01
#D- Path Server Group Login
RestartPath=${R_IN}/RESTART/IPSLCM6/PROD/piControl-spinup

#========================================================================
#D-- ICE -
[ICE]
WriteFrequency="HF 1D 1M"
# If config_Restarts_OverRule == 'n' next 4 params are read
Restart= n
##-- Last day of the experience used as restart for this component if Restart=y
RestartDate=1849-12-31
#D- Define restart simulation name for this component
RestartJobName=CM61-pre-pi-01
#D- Path Server Group Login
RestartPath=${R_IN}/RESTART/IPSLCM6/PROD/piControl-spinup

#========================================================================
#D-- IOS -
[IOS]
WriteFrequency=""
# If config_Restarts_OverRule == 'n' next 4 params are read
Restart= n
##-- Last day of the experience used as restart for this component if Restart=y
RestartDate=
# Define restart simulation name for this component
RestartJobName=
RestartPath=
#========================================================================
#D-- ListOfComponents -
[ListOfComponents]
#D- For each component, Name of component, Tag of component
OCE= (opa9, nemo_v3_6_STABLE-r9455)
ICE= (lim3, nemo_v3_6_STABLE-r9455)
IOS= (xios, dev-cmip6-r1475)

#========================================================================
#D-- Executable -
[Executable]
#D- For each component, Real name of executable, Name of executable for oasis
OCE= (opa, opa.xx, 32MPI)
ICE= ("" ,"" )
IOS= (xios_server.exe, xios.x, 1MPI)

Modify lim3.card

Change directory to COMP.

Edit lim3.card to adjust to ORCA2.

Remove maskMFO_lim.nc

[BoundaryFiles]
List=   ()
ListNonDel= ()

Change the lim3 cfg namelist name:

[ParametersFiles]
List=   (${MODIPSL}/modeles/NEMOGCM/CONFIG/SHARED/namelist_ice_lim3_ref                  , namelist_ice_ref       ), \
        (${MODIPSL}/modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/field_def_nemo-lim.xml, field_def_nemo-lim.xml ), \
        (${SUBMIT_DIR}/PARAM/namelist_lim3_${RESOL_OCE}_cfg                              , namelist_ice_cfg       ), \
        (${SUBMIT_DIR}/PARAM/file_def_nemo-lim3.xml                                      , file_def_nemo-lim.xml  )

Modify opa9.card

Edit opa9.card.

Change default ORCA config and add ORCA2.4:

[UserChoices]
ORCA_version=${config_UserChoices_ORCA_version:-ORCA2.3}
ORCA_forcing=ORCA2.4

Set the boundary files for forcing:

[BoundaryFiles]
List=   (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/u_10.15JUNE2009_fill.nc            , u_10.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/v_10.15JUNE2009_fill.nc            , v_10.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/t_10.15JUNE2009_fill.nc            , t_10.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/q_10.15JUNE2009_fill.nc            , q_10.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/ncar_rad.15JUNE2009_fill.nc        , radsw.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/ncar_rad.15JUNE2009_fill.nc        , radlw.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/ncar_precip.15JUNE2009_fill.nc     , precip.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/ncar_precip.15JUNE2009_fill.nc     , snow.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/weights_core_orca2_bilinear_noc.nc , weights_bilinear.nc), \
        (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_forcing}/weights_core_orca2_bicubic_noc.nc  , weights_bicubic.nc)

Still in [BondaryFiles]section, set the non deletable forcing files (such as levithus for starting from scratch):

ListNonDel= (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/coordinates.nc                          , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/bathy_meter.nc                          , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/ahmcoef.nc                              , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/runoff_core_monthly.nc                  , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/data_1m_potential_temperature_nomask.nc , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/geothermal_heating.nc                   , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/data_1m_salinity_nomask.nc              , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/sss_data.nc                             , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/sst_data.nc                             , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/chlorophyll_surface.nc                  , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/K1rowdrg.nc                             , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/M2rowdrg.nc                             , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/mask_itf.nc                             , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/sali_ref_clim_monthly.nc                , .), \
            (${R_IN}/OCE/IPSLCM6/${opa9_UserChoices_ORCA_version}/subbasins.nc                            , .)

Add iodef.xml and set context_nemo.xml in [ParametersFiles]:

[ParametersFiles]
List=   (${MODIPSL}/modeles/NEMOGCM/CONFIG/SHARED/namelist_ref                            , namelist_ref        ), \
        (${SUBMIT_DIR}/PARAM/ping_nemo.xml, . )                                                                  , \
        (${SUBMIT_DIR}/PARAM/iodef.xml, . )                                                                  , \
        (${SUBMIT_DIR}/PARAM/context_nemo.xml                                             , context_nemo.xml    ), \
        (${MODIPSL}/modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/domain_def_nemo.xml    , domain_def_nemo.xml ), \
        (${MODIPSL}/modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/axis_def_nemo.xml      , axis_def_nemo.xml   ), \
        (${MODIPSL}/modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/grids_def_nemo.xml     , grids_def_nemo.xml  ), \
        (${MODIPSL}/modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/field_def_nemo-opa.xml , field_def_nemo-opa.xml  ), \
        (${SUBMIT_DIR}/PARAM/namelist_${RESOL_OCE}_cfg                                    , namelist_cfg        ), \
        (${SUBMIT_DIR}/PARAM/file_def_nemo-opa.xml                                        , file_def_nemo-opa.xml   )

We will need to modify context_nemo.xml to remove PISCES sections.

Parameters Files

Go to PARAM directory.

context_nemo.xml

Copy context_nemo.xml:

cp ../../../../modeles/NEMOGCM/CONFIG/ORCA1_LIM3_PISCES/EXP00/context_nemo.xml .

Edit it to remove PISCES:

<!-- Fields definition -->
    <field_definition src="./field_def_nemo-opa.xml"/>   <!--  NEMO ocean dynamics                     -->
    <field_definition src="./field_def_nemo-lim.xml"/>   <!--  NEMO ocean sea ice                      -->
<!--    <field_definition src="./field_def_nemo-pisces.xml"/>   <!--  NEMO ocean biogeochemistry with PISCES  -->
    <field_definition src="./field_def_nemo-inerttrc.xml"/>   <!--  NEMO ocean biogeochemistry with PISCES  -->
<!-- Files definition -->
    <file_definition src="./file_def_nemo-opa.xml"/>     <!--  NEMO ocean dynamics                     -->
    <file_definition src="./file_def_nemo-lim.xml"/>     <!--  NEMO ocean sea ice                      -->
<!--    <file_definition src="./file_def_nemo-pisces.xml"/>     <!--  NEMO ocean biogeochemistry with PISCES  -->

namelist_lim3_ORCA2_cfg

Edit the file namelist_lim3_ORCA2_cfg:

!-----------------------------------------------------------------------
&namicerun     !   Share parameters for dynamics/advection/thermo
!-----------------------------------------------------------------------
   jpl            =    1           !  number of ice  categories
   cn_icerst_in  = "restart_ice_in"   !  suffix of ice restart name (input)
/

!------------------------------------------------------------------------------
&namiceitd     !   Ice discretization
!------------------------------------------------------------------------------
   rn_himax_bot = 99.             !  max ice thickness in the last category jpl
/

namelist_ORCA2_cfg

Add the Schwarz parameters to namelist_ORCA2_cfg:

!-----------------------------------------------------------------------
&namrun        !   parameters of the run
!-----------------------------------------------------------------------
   cn_exp      = _AUTOBLOCKER_    !  Experience name
   nn_it000    = _AUTOBLOCKER_    !  First time step
   nn_itend    = _AUTOBLOCKER_    !  Last  time step
   nn_date0    = _AUTOBLOCKER_    !  Date at nit_0000 (format yyyymmdd) used if ln_rstart=F or (ln_rstart=T and nn_rstctl=0 or 1)
   nn_leapy    = _AUTOBLOCKER_    !  Leap year calendar (1) or not (0)
   ln_rstart   = _AUTOBLOCKER_    !  start from rest (F) or from a restart file (T)
   ln_rstart_ts = _AUTOBLOCKER_   !  start from rest for current only (F) or from a restart file (T)
   nn_rstctl   = _AUTOBLOCKER_    !  Restart control => activated only if ln_rstart = T
                           !    = 0 nn_date0 read in namelist ; nn_it000 : read in namelist
                           !    = 1 nn_date0 read in namelist ; nn_it000 : check consistancy between namelist and restart
                           !    = 2 nn_date0 read in restart  ; nn_it000 : check consistancy between namelist and restart
   cn_ocerst_in  = "restartopa"   !  Suffix of ocean restart name (input)
   cn_ocerst_indir = "."       !  directory from which to read input ocean restarts
   cn_ocerst_out = "restart"      !  Suffix of ocean restart name (output)
   cn_ocerst_outdir = "."      !  directory in which to write output ocean restarts
   nn_istate   =       0   !  Output the initial state (1) or not (0)
   nn_stock    =  _AUTOBLOCKER_   !  Frequency of creation of a restart file (modulo referenced to 1)
   nn_write    =    5475   !  Requency of write in the output file   (modulo referenced to nn_it000)
   ln_mskland  = .true.    !  Masks land points in NetCDF outputs
   ln_mskutil  = .false.    !  Outputs without halos
   ln_dimgnnn  = .false.   !  DIMG file format: 1 file for all processors (F) or by processor (T)
   ln_cfmeta   = .false.   !  output additional data to netCDF files required for compliance with the CF metadata standard
   ln_clobber  = .true.    !  clobber (overwrite) an existing file
   nn_chunksz  =       0   !  chunksize (bytes) for NetCDF file (works only with iom_nf90 routines)
   mswr        =  10   !  number of scwharz iterations
   ksout       =  10   !  Schwarz iteration for output
   kall        =  1    !  first iteration with all physics
   ncplfrq     =  1    !  coupling frequency in seconds

You are ready to run NEMO.

Last modified 2 years ago Last modified on 07/30/19 15:39:37