Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/axis_def_nemo.xml
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/axis_def_nemo.xml	(revision 12928)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/axis_def_nemo.xml	(revision 12928)
@@ -0,0 +1,1 @@
+link ../../../cfgs/SHARED/axis_def_nemo.xml
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/context_nemo.xml
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/context_nemo.xml	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/context_nemo.xml	(revision 12928)
@@ -5,15 +5,18 @@
 -->
 <context id="nemo">
-<!-- $id$ -->
+    <!-- $id$ -->
     <variable_definition>
-    <!-- Year of time origin for NetCDF files; defaults to 1800 -->
-       <variable id="ref_year" type="int"   > 1800 </variable>
-       <variable id="rau0"     type="float" > 1026.0 </variable>
-       <variable id="cpocean"  type="float" > 3991.86795711963 </variable>
-       <variable id="convSpsu" type="float" > 0.99530670233846  </variable>
-       <variable id="rhoic"    type="float" > 917.0 </variable>
-       <variable id="rhosn"    type="float" > 330.0 </variable>
-       <variable id="missval"  type="float" > 1.e20 </variable>
+       <!-- Year/Month/Day of time origin for NetCDF files; defaults to 1800-01-01 -->
+       <variable id="ref_year"  type="int"> 1900 </variable>
+       <variable id="ref_month" type="int"> 01 </variable>
+       <variable id="ref_day"   type="int"> 01 </variable>
+       <variable id="rau0"      type="float" > 1026.0 </variable>
+       <variable id="cpocean"   type="float" > 3991.86795711963 </variable>
+       <variable id="convSpsu"  type="float" > 0.99530670233846  </variable>
+       <variable id="rhoic"     type="float" > 917.0 </variable>
+       <variable id="rhosn"     type="float" > 330.0 </variable>
+       <variable id="missval"  type="float" > 1.e20 </variable>	       
     </variable_definition>
+
 <!-- Fields definition -->
     <field_definition src="./field_def_nemo-oce.xml"/>   <!--  NEMO ocean dynamics                     -->
@@ -21,25 +24,14 @@
 <!-- Files definition -->
     <file_definition src="./file_def_nemo-oce.xml"/>     <!--  NEMO ocean dynamics                     -->
-    <!-- 
-============================================================================================================
-= grid definition = = DO NOT CHANGE =
-============================================================================================================
-    -->
-    
-    <axis_definition>
-      <axis id="deptht"  long_name="Vertical T levels" unit="m" positive="down" />
-      <axis id="depthu"  long_name="Vertical U levels" unit="m" positive="down" />
-      <axis id="depthv"  long_name="Vertical V levels" unit="m" positive="down" />
-      <axis id="depthw"  long_name="Vertical W levels" unit="m" positive="down" />
-      <axis id="nfloat"  long_name="Float number"      unit="-"                 />
-      <axis id="icbcla"  long_name="Iceberg class"     unit="1"                 />
-      <axis id="ncatice" long_name="Ice category"      unit="1"                 />
-      <axis id="iax_20C" long_name="20 degC isotherm"  unit="degC"              />
-      <axis id="iax_28C" long_name="28 degC isotherm"  unit="degC"              />
-    </axis_definition>
+
+<!-- Axis definition -->
+    <axis_definition src="./axis_def_nemo.xml"/>
  
+<!-- Domain definition -->
     <domain_definition src="./domain_def_nemo.xml"/>
+
+<!-- Grids definition -->
+    <grid_definition   src="./grid_def_nemo.xml"/>
   
-    <grid_definition src="./grid_def_nemo.xml"/>
 
 </context>
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_cen-ahm1000_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_cen-ahm1000_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_cen-ahm1000_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -210,5 +210,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_ubs_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_ubs_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT2_flux_ubs_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -210,5 +210,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_cen-ahm1000_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_cen-ahm1000_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_cen-ahm1000_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_ubs_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_ubs_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_sco_FCT4_flux_ubs_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -210,5 +210,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT2_flux_ubs_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT2_flux_ubs_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT2_flux_ubs_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -211,5 +211,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_flux_ubs_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_flux_ubs_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_flux_ubs_cfg	(revision 12928)
@@ -34,9 +34,8 @@
    cn_exp      =   "OVF_zps_FCT4_flux_ubs"  !  experience name
    nn_it000    =       1   !  first time step
-   !nn_itend    =    6120  ! here 17h of simulation  (=6120 time-step) 
-   nn_itend    =    5760   ! here 16h of simulation  (=5760 time-step) abort after 5802 for zps: pb of physics conditions
+   nn_itend    =    6120   ! here 17h of simulation  (=6120 time-step) 
    nn_istate   =       0   !  output the initial state (1) or not (0)
-   nn_stock    =    1080   !  frequency of creation of a restart file (modulo referenced to 1)
-   nn_write    =    1080   !  frequency of write in the output file   (modulo referenced to nn_it000)
+   nn_stock    =    6120   !  frequency of creation of a restart file (modulo referenced to 1)
+   nn_write    =    6120   !  frequency of write in the output file   (modulo referenced to nn_it000)
 /
 !-----------------------------------------------------------------------
@@ -47,5 +46,5 @@
 &namdom        !   time and space domain
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -217,8 +216,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -255,4 +254,7 @@
 &namzdf        !   vertical physics manager                             (default: NO selection)
 !-----------------------------------------------------------------------
+   !                       ! adaptive-implicit vertical advection
+   ln_zad_Aimp = .true.       !  Courant number dependent scheme (Shchepetkin 2015)
+   !
    !                       ! type of vertical closure (required)
    ln_zdfcst   = .true.      !  constant mixing
@@ -279,5 +281,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
@@ -292,7 +294,5 @@
 !!   namdiu       Cool skin and warm layer models                       (default: OFF)
 !!   namflo       float parameters                                      (default: OFF)
-!!   nam_diaharm  Harmonic analysis of tidal constituents               (default: OFF)
 !!   nam_diadct   transports through some sections                      (default: OFF)
-!!   nam_diatmb   Top Middle Bottom Output                              (default: OFF)
 !!   nam_dia25h   25h Mean Output                                       (default: OFF)
 !!   namnc4       netcdf4 chunking and compression settings             ("key_netcdf4")
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_vect_een_cfg
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_vect_een_cfg	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/EXPREF/namelist_zps_FCT4_vect_een_cfg	(revision 12928)
@@ -33,5 +33,5 @@
 &namdom        !   space and time domain (bathymetry, mesh, timestep)
 !-----------------------------------------------------------------------
-   rn_rdt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
+   rn_Dt      =   10.     !  time step for the dynamics (and tracer if nn_acc=0)
    rn_atfp     =    0.1    !  asselin time filter parameter
 /
@@ -155,8 +155,8 @@
       ln_bt_av      = .true.     ! Time filtering of barotropic variables
          nn_bt_flt     = 1          ! Time filter choice  = 0 None
-         !                          !                     = 1 Boxcar over   nn_baro sub-steps
-         !                          !                     = 2 Boxcar over 2*nn_baro  "    "
+         !                          !                     = 1 Boxcar over   nn_e sub-steps
+         !                          !                     = 2 Boxcar over 2*nn_e  "    "
       ln_bt_auto    = .true.     ! Number of sub-step defined from:
-         nn_baro      =  1         ! =F : the number of sub-step in rn_rdt seconds
+         nn_e      =  1         ! =F : the number of sub-step in rn_Dt seconds
 /
 !-----------------------------------------------------------------------
@@ -210,5 +210,5 @@
    !                       ! coefficients
    rn_avm0     =   1.e-4     !  vertical eddy viscosity   [m2/s]       (background Kz if ln_zdfcst=F)
-   rn_avt0     =   0.0e      !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
+   rn_avt0     =   0.0       !  vertical eddy diffusivity [m2/s]       (background Kz if ln_zdfcst=F)
    nn_avb      =    0        !  profile for background avt & avm (=1) or not (=0)
    nn_havtb    =    0        !  horizontal shape for avtb (=1) or not (=0)
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_hgr.F90
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_hgr.F90	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_hgr.F90	(revision 12928)
@@ -26,4 +26,6 @@
    PUBLIC   usr_def_hgr   ! called by domhgr.F90
 
+   !! * Substitutions
+#  include "do_loop_substitute.h90"
    !!----------------------------------------------------------------------
    !! NEMO/OCE 4.0 , NEMO Consortium (2018)
@@ -72,17 +74,16 @@
       !                       !==  grid point position  ==!   (in kilometers)
       zfact = rn_dx * 1.e-3         ! conversion in km
-      DO jj = 1, jpj
-         DO ji = 1, jpi             ! longitude
-            plamt(ji,jj) = zfact * (  - 0.5 + REAL( ji-1 + nimpp-1 , wp )  )  
-            plamu(ji,jj) = zfact * (          REAL( ji-1 + nimpp-1 , wp )  )
-            plamv(ji,jj) = plamt(ji,jj)
-            plamf(ji,jj) = plamu(ji,jj)
-            !                       ! latitude
-            pphit(ji,jj) = zfact * (  - 0.5 + REAL( jj-1 + njmpp-1 , wp )  )
-            pphiu(ji,jj) = pphit(ji,jj)
-            pphiv(ji,jj) = zfact * (          REAL( jj-1 + njmpp-1 , wp )  )
-            pphif(ji,jj) = pphiv(ji,jj)
-         END DO
-      END DO
+      DO_2D_11_11
+         !                       ! longitude
+         plamt(ji,jj) = zfact * (  - 0.5 + REAL( ji-1 + nimpp-1 , wp )  )  
+         plamu(ji,jj) = zfact * (          REAL( ji-1 + nimpp-1 , wp )  )
+         plamv(ji,jj) = plamt(ji,jj)
+         plamf(ji,jj) = plamu(ji,jj)
+         !                       ! latitude
+         pphit(ji,jj) = zfact * (  - 0.5 + REAL( jj-1 + njmpp-1 , wp )  )
+         pphiu(ji,jj) = pphit(ji,jj)
+         pphiv(ji,jj) = zfact * (          REAL( jj-1 + njmpp-1 , wp )  )
+         pphif(ji,jj) = pphiv(ji,jj)
+      END_2D
       !
       !                       !==  Horizontal scale factors  ==!   (in meters) 
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_istate.F90
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_istate.F90	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_istate.F90	(revision 12928)
@@ -60,5 +60,5 @@
       !
       !  rn_a0 =  0.2   !  thermal expension coefficient (nn_eos= 1)
-      !  rho = rau0 - rn_a0 * (T-10) 
+      !  rho = rho0 - rn_a0 * (T-10) 
       !  delta_T = 10 degrees  ==>>  delta_rho = 10 * rn_a0 = 2 kg/m3
       !
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_nam.F90
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_nam.F90	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_nam.F90	(revision 12928)
@@ -61,5 +61,4 @@
       !!----------------------------------------------------------------------
       !
-      REWIND( numnam_cfg )          ! Namelist namusr_def (exist in namelist_cfg only)
       READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 )
 902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist' )
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_sbc.F90
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_sbc.F90	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_sbc.F90	(revision 12928)
@@ -31,6 +31,4 @@
    PUBLIC   usrdef_sbc_ice_flx  ! routine called by icestp.F90 for ice thermo
 
-   !! * Substitutions
-#  include "vectopt_loop_substitute.h90"
    !!----------------------------------------------------------------------
    !! NEMO/OCE 4.0 , NEMO Consortium (2018)
@@ -40,5 +38,5 @@
 CONTAINS
 
-   SUBROUTINE usrdef_sbc_oce( kt )
+   SUBROUTINE usrdef_sbc_oce( kt, Kbb )
       !!---------------------------------------------------------------------
       !!                    ***  ROUTINE usr_def_sbc  ***
@@ -55,4 +53,5 @@
       !!----------------------------------------------------------------------
       INTEGER, INTENT(in) ::   kt   ! ocean time step
+      INTEGER, INTENT(in) ::   Kbb  ! ocean time index
       !!---------------------------------------------------------------------
       !
@@ -80,6 +79,9 @@
    END SUBROUTINE usrdef_sbc_ice_tau
 
-   SUBROUTINE usrdef_sbc_ice_flx( kt )
+
+   SUBROUTINE usrdef_sbc_ice_flx( kt, phs, phi )
       INTEGER, INTENT(in) ::   kt   ! ocean time step
+      REAL(wp), DIMENSION(:,:,:), INTENT(in)  ::   phs    ! snow thickness
+      REAL(wp), DIMENSION(:,:,:), INTENT(in)  ::   phi    ! ice thickness
    END SUBROUTINE usrdef_sbc_ice_flx
 
Index: NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_zgr.F90
===================================================================
--- NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_zgr.F90	(revision 12178)
+++ NEMO/branches/2019/dev_r11078_OSMOSIS_IMMERSE_Nurser/tests/OVERFLOW/MY_SRC/usrdef_zgr.F90	(revision 12928)
@@ -29,6 +29,6 @@
    PUBLIC   usr_def_zgr   ! called by domzgr.F90
 
-  !! * Substitutions
-#  include "vectopt_loop_substitute.h90"
+   !! * Substitutions
+#  include "do_loop_substitute.h90"
    !!----------------------------------------------------------------------
    !! NEMO/OCE 4.0 , NEMO Consortium (2018)
@@ -184,16 +184,14 @@
             pe3vw(:,:,jk) = pe3w_1d (jk)
          END DO
-         DO jj = 1, jpj                      ! bottom scale factors and depth at T- and W-points
-            DO ji = 1, jpi
-               ik = k_bot(ji,jj)
-                  pdepw(ji,jj,ik+1) = MIN( zht(ji,jj) , pdepw_1d(ik+1) )
-                  pe3t (ji,jj,ik  ) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik)
-                  pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik  ) 
-                  !
-                  pdept(ji,jj,ik  ) = pdepw(ji,jj,ik  ) + pe3t (ji,jj,ik  ) * 0.5_wp
-                  pdept(ji,jj,ik+1) = pdepw(ji,jj,ik+1) + pe3t (ji,jj,ik+1) * 0.5_wp
-                  pe3w (ji,jj,ik+1) = pdept(ji,jj,ik+1) - pdept(ji,jj,ik)              ! = pe3t (ji,jj,ik  )
-            END DO
-         END DO         
+         DO_2D_11_11
+            ik = k_bot(ji,jj)
+            pdepw(ji,jj,ik+1) = MIN( zht(ji,jj) , pdepw_1d(ik+1) )
+            pe3t (ji,jj,ik  ) = pdepw(ji,jj,ik+1) - pdepw(ji,jj,ik)
+            pe3t (ji,jj,ik+1) = pe3t (ji,jj,ik  ) 
+            !
+            pdept(ji,jj,ik  ) = pdepw(ji,jj,ik  ) + pe3t (ji,jj,ik  ) * 0.5_wp
+            pdept(ji,jj,ik+1) = pdepw(ji,jj,ik+1) + pe3t (ji,jj,ik+1) * 0.5_wp
+            pe3w (ji,jj,ik+1) = pdept(ji,jj,ik+1) - pdept(ji,jj,ik)              ! = pe3t (ji,jj,ik  )
+         END_2D         
          !                                   ! bottom scale factors and depth at  U-, V-, UW and VW-points
          !                                   ! usually Computed as the minimum of neighbooring scale factors
