User Tools

Site Tools


tools:ocean_nudging2

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
tools:ocean_nudging2 [2018/06/21 08:29]
vsicardi
tools:ocean_nudging2 [2019/08/12 12:53] (current)
vlapin [How to run a nudging experiment with EC-Earth 3.2.3]
Line 1: Line 1:
 ======PAGE UNDER CONSTRUCTION. PLEASE BE PATIENT================= ======PAGE UNDER CONSTRUCTION. PLEASE BE PATIENT=================
  
-==== How to run a nudging experiment with EC-Earth 3.2====+==== How to run a nudging experiment with EC-Earth 3.2.3 ====
  
-You can run experiments activating surface restoring or Newtonian Dumping (3D nudging). 
-Both feature are already part of NEMO code, nevertheless with auto-ecearth there are some parameters to activate in the configuration files and some variables to take care of in the namelist. 
  
-First of all, in both  casesplease check that the reference files for your nudged experiments are available on the platform you would like to run. +You can run experiments activating surface restoring or Newtonian Damping (3D nudging). 
-For surface restoring the location is: +Both features are already part of NEMO codenevertheless with auto-ecearth there are some parameters to activate in the configuration files and some variables to take care of in the namelist. This guide is mostly thought for AUTO-ECEARTH users. 
-If you would like to prepare new reference files, their naming should follow the convention : + 
 +First of all, check that the nudging files you want to use are available on the platform you would like to run. 
 + 
 +In MN4, data for surface restoring are located here: /gpfs/projects/bsc32/repository/surface_restoring. 
 + 
 +Any new surface restoring files should be located in the above path following this structure: ocean/REFERENCE/RESOLUTION/MEMB,( where REFERENCE is the name of the ocean reanalysis you would like use and MEMB is the member). For example for oras4 surface restore data: /gpfs/projects/bsc32/repository/surface_restoring/ocean/s4/ORCA1L75/fc0.  The data should be files with 12 month  starting in January with this name convention: sss_restore_data_yXXXX.nc  and sst_restore_data_yXXXX.nc where XXXX is the year, ( this is how nemo wants the files, see routine //fldread.F90// for more details). 
 + 
 +For 3d nudging, the location in MN4 is /gpfs/projects/bsc32/repository/nudging  and the convention, if the user want to add other nudging files is: /gpfs/projects/bsc32/repository/nudging/REFERENCE/CONFIG/fcMEMB/ where REFERENCE is the name of the ocean reanalysis you would like to nudge to ( s4 / glorys2v1 ), CONFIG is the ocean model resolution ( ORCA1L75 / ORCA025L75 ) and MEMB is the member. 
 + 
 + 
 +If you would like to prepare new reference files, their naming should follow the convention : REFERENCE_fcMEMB_YYYYMM_grid_T.nc.gz = one file containing 3-dimensional monthly mean temperature and salinity. For a given year the previous year and the following year are linked. So be sure you have all the files before you start. 
 + 
 +In theory the user should only specify the name of the file to be used, then auto-ecearth via templates (ecearth3.ini and nemo3.ini) will take care of creating the right link and put them in the right places. If not, then there is a bug to be fixed. No panic. We do it. 
 + 
  
-For 3d nudging, the location is : HSM_DIR/nudging/REFERENCE/CONFIG/fcMEMB/ where REFERENCE is the name of the ocean reanalysis you would like to nudge to ( s4 / glorys2v1 = 2 options available currently ), CONFIG is the ocean model resolution ( ORCA1L75 / ORCA025L75 ) and MEMB is the member.  
-If you would like to prepare new reference files, their naming should follow the convention : REFERENCE_fcMEMB_YYYYMM_grid_T.nc.gz = one file containing 3-dimensional monthly mean temperature and salinity. 
  
 ========Surface Restoring======== ========Surface Restoring========
Line 24: Line 33:
  
  
-**Proj.conf settings:**  +STEPS to activate surface restoring:
  
 +**1. Proj.conf settings:**  
  
-Namelist settings+  - Ordered List Item Activate the surface restoring  SURF_RESTO = TRUE 
 +  - Define the data restoring to be used: RESTO_DATA = s4/your_exp_ID 
 + 
 + 
 +So far you can use oras4,  by specifying s4, or a climatology of an experiment you created, by specifying the ID of the experiment. 
 + 
 +Please note that is responsibility of the user to be sure that the surface restoring data to be used are in the right format and in the right place. In case of doubts speak with Valentina or Yohan. 
 + 
 +**2.Namelist settings** 
 + 
 +Note that, depending on the branch the user wants to use this part is already set-up. See section about available branches for available branches. The following namelist refers to the branch: r5671-bsc_ocean_DA. some difference can be found when using a different branch.  
 + 
 +You can use nemo-only or coupled version for your nudged experiments. Depending on this option,  the namelist will be standalone or coupled (obvious, but important to remember) 
 + 
 + 
 +Here is an example to activate SST restoring in **namelist_nemo-ORCA1L75-standalone.cfg.sh**. 
 + 
 +in section nambsrc you will find: 
 + 
 +       ln_ssr      = ${ln_ssr}    Sea Surface Restoring on T and/or S       (T => fill namsbc_ssr) 
 +        
 +This is switched on from configuration file. So do not worry about it. If SURF_RESTO = TRUE in proj.conf,  then the surface restoring is activated       
 + 
 + 
 +Here there are some parameters that the user should check: 
 + 
 +     
 +      &namsbc_ssr    !   surface boundary condition : sea surface restoring 
 +     !----------------------------------------------------------------------- 
 +     ! filename          ! freq  ! variable name  ! time     ! clim     ! year or   ! weights   ! rot     ! mask 
 +                                                        ! interp            ! monthly   ! filename  ! pair    ! filename 
 +       
 +     sn_sss      = 'sss_restore_data'  , -1.   , 'so'           , .true.   , .true.  , 'yearly'   , ''        , ''      , '' 
 +     sn_sst      = 'sst_restore_data'  , -1.   , 'thetao'       , .true.   , .true.  , 'yearly'   , ''        , ''      , '' 
 +     sn_msk      = 'mask_restore'      , -12.  , 'mask_ssr'     , .false.  , .true.  , 'yearly'   , ''        , ''      , '' 
 +     ! 
 +     cn_dir      = './'    !  root directory for the location of the runoff files   
 +     nn_sstr     = 1        add a retroaction term in the surface heat flux (=1) or not (=0) 
 +     nn_sssr     = 2        add a damping term in the surface freshwater flux (=2) or to SSS only (=1) or no damping term (=0) 
 +     nn_icer     = 0        perform sea surface restoring (=1) or not (=0) where there is sea-ice 
 +     nn_msk      = 1        add a sub-regional masking to the surface restoring (=1) or not (=0) 
 +                          sn_msk can be empty if nn_msk = 0 
 +     rn_dqdt     = -40.    !  magnitude of the retroaction on temperature   [W/m2/K] 
 +     rn_deds     = -166.67 !  magnitude of the damping on salinity   [kg/m2/s/psu] 
 +     ln_sssr_bnd = .false.  ! .true. !  flag to bound erp term (associated with nn_sssr=2) 
 +     rn_sssr_bnd = 4.e0    !  ABS(Max/Min) value of the damping erp term [mm/day] 
 +     / 
 +     !-----------------------------------------------------------------------
  
-Here is an example to activate SST restoring : 
  
-ln_ssr = .true. ! Sea Surface Restoring on T and/or S (T => fill namsbc_ssr) 
-!----------------------------------------------------------------------- 
-&namsbc_ssr ! surface boundary condition : sea surface restoring 
-!----------------------------------------------------------------------- 
-! ! file name ! frequency (hours) ! variable ! time interpol. ! clim ! 'yearly'/ ! weights ! rotation ! 
-! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! filename ! pairing ! 
-sn_sst = 'sst_data' , -1 , 'sst' , .true. , .false. , 'yearly' , '' , '' 
-sn_sss = 'sss_data' , -1 , 'sss' , .true. , .true. , 'yearly' , '' , '' 
-cn_dir = './' ! root directory for the location of the runoff files 
-nn_sstr = 1 ! add a retroaction term in the surface heat flux (=1) or not (=0) 
-nn_sssr = 0 !lolo only for ocean standalone! add a damping term in the surface freshwater flux (=2) 
-! or to SSS only (=1) or no damping term (=0) 
-rn_dqdt = -40. ! magnitude of the retroaction on temperature [W/m2/K] 
-rn_deds = -864. !lolo magnitude of the damping on salinity [mm/day] 
-ln_sssr_bnd = .true. ! flag to bound erp term (associated with nn_sssr=2) 
-rn_sssr_bnd = 5.e0 !lolo ABS(Max/Min) value of the damping erp term [mm/day] 
-/ 
  
 Reference data Reference data
-Nudging files, as defined in fldread.F90. They can be one file per year (even if there are one record per month in it), or one separate file for each and every month. In the following example it's one file with 12 months, for each variable. 
  
 Note that the name of the file contains "_yXXXX" where XXXX are the 4 digit of the year. Note that the name of the file contains "_yXXXX" where XXXX are the 4 digit of the year.
  
-sst_data_yXXXX.nc 
-sss_data_yXXXX.nc 
  
-SST parameters :+SST parameters to be set :
  
 nn_sstr nn_sstr
  
-sn_sst +sn_sst file name = name of the file, in the formatsst_restore_data. if you use s4 or one of your exp, do not modify it. auto-ecearth will do the job. The name of the nudging file, is defined in fldread.F90, without the year suffix and the .nc
- +
-file name : Name of the nudging file, as defined in fldread.F90, without the year suffix and the .nc+
  
 frequency : the frequency of the data, usually 1 month, i.e. -1 frequency : the frequency of the data, usually 1 month, i.e. -1
Line 87: Line 121:
 rn_deds (-864 mm/day/psu is the standard value consistent with rn_dqdt = -40) rn_deds (-864 mm/day/psu is the standard value consistent with rn_dqdt = -40)
  
-The user must create the nudging files, according to experiment needs. These files can be created either all the once at the beginning of the simulation or after each leg during the simulation. +The user must create the nudging files, according to experiment needs. 
-The script to create such files will be uploaded here soon.+
  
 The user can activate SST restoring and SSS restoring independently with nn_sstr and nn_sssr The user can activate SST restoring and SSS restoring independently with nn_sstr and nn_sssr
  
-To switch it on, just add nemo:oceanudg2d to your config variable at the top of the template script in the runtime/classic directoryYou will need to add/link the nudging files to your run directory, as described below.+=========== 3D Nudging ========== 
 + 
 +3D nudging in the ocean is done by using the tracer damping functionality of NEMO (tradmp.F90). The nudging can be don only under the mixed layer or in the entire water column. The user has to nudge both the temperature and salinity, while activating at the same time the restoring of SST and SSS is optional. 
 + 
 +In order to activate the 3D nudging in the proj.conf OCE_NUDG must be set to true. This corresponds to the activation in the namelist of: 
 +   
 + 
 +   !----------------------------------------------------------------------- 
 +   &namtra_dmp    !   tracer: T & S newtonian damping 
 +   !----------------------------------------------------------------------- 
 +   ln_tradmp    .true.  !  add a damping termn (T) or not (F) 
 +   nn_zdmp        2      !  vertical   shape =0    damping throughout the water column 
 +                                             =1 no damping in the mixing layer (kz  criteria) 
 +                                             =2 no damping in the mixed  layer (rho crieria) 
 +   cn_resto    = 'resto.nc' ! Name of file containing restoration coefficient field (use dmp_tools to create this) 
 + 
 +   / 
 +Th 
 +The namelist parameter nn_zdmp sets whether the damping should be applied in the whole water column or only below the mixed layer (defined either on a density 
 +or So criterion). The user should modify it the namelist according to the experiment necessity. 
 + 
 +**resto.nc** files contains the restoration coefficient. A default one is located in: /esnas/releases/nudging/RESTO and in MN4 in:/gpfs/projects/bsc32/repository/nudging/ocean/RESTO/,  in case of different needs, the user can create a new one, put it in the same location and specify the name in the namelist. 
 + 
 +In proj.conf the use should specify the nudging files to be used: s4,p5,glorys. The nudging files are located in: /esnas/releases/nudging/ocean and in MN4 in:/gpfs/projects/bsc32/repository/nudging/ocean/  It's user's responsibility to check that the interested period is present. 
 + 
 +Example of proj.conf session: 
 +OCE_NUDG = TRUE 
 + 
 +# Toward which target ocean is nuged to; essential if "OCE_NUDG" is TRUE. STRING = fa9p, s4, glorys2v1 
 +# A directory ${DATA_OCE_NUDG} must exist in /gpfs/projects/bsc32/repository/nudging/ocean/${DATA_OCE_NUDG}/${nem_grid}/${DATA_OCE_NUDG_member} containing the restoring files 
 +DATA_OCE_NUDG = s4 
 +# A different DATA_OCE_NUDG member per EXPID member ["PERT"] or which common DATA_SURF_RESTO member for all EXPID members ["fc0" / "fc1"]. String = PERT/fc0/fc1.. 
 +DATA_OCE_NUDG_member = fc0 
 + 
 +  
 +At this point the user must manually edit the corresponding namelist coupled or standalonein the following session: 
 + 
 + 
 +   !----------------------------------------------------------------------- 
 +   &namtsd    !   data : Temperature  & Salinity 
 +   !----------------------------------------------------------------------- 
 +            !  file name                          ! frequency (hours) ! variable  ! time interp. !  clim  !'yearly'/ ! weights     ! rotation ! land/sea mask ! 
 +                                               ! (if <0  months)    name     ! (logical)    !  (T/F) ! 'monthly' ! filename    ! pairing  ! filename       
 +   sn_tem  = 'temperature', -1 ,'votemper' , .true. , .false. , 'yearly' , '' , '' , '' 
 +   sn_sal  = 'salinity'       , -1 ,'vosaline' , .true. , .false. , 'yearly' , '' , '' , '' 
 +   cn_dir        = './'      root directory for the location of the runoff files 
 +   ln_tsd_init   = .true.    Initialisation of ocean T & S with T &S input data (T) or not (F) 
 +   ln_tsd_tradmp = .true.  !  damping of ocean T & S toward T &S input data (T) or not (F) 
 +
 +  
 + 
 +The 3D nudging files are genrically renamed to salinity_yXXXX and temperature_yXXXX. The user must be sure that the correct links are created in the inidata folder via eceart3.ini and nemo3.ini templates 
  
-Please note that this is an ongoing work. +For any information contact valentina.sicardi@bsc.es and yohan.ruprich@bsc.es
-At BSC we work on this development with the branch bsc_nemo_nudging. No changes have been so far in classic. +
-For further informations contact valentina.sicardi@bsc.es+
tools/ocean_nudging2.1529569771.txt.gz · Last modified: 2018/06/21 08:29 by vsicardi