Index: NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_all_update.F90
===================================================================
--- NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_all_update.F90	(revision 10009)
+++ NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_all_update.F90	(revision 10010)
@@ -48,5 +48,5 @@
       CALL Agrif_Update_ssh()                      ! Update sea level
       !
-      IF (.NOT.ln_linssh) CALL Agrif_Update_vvl()  ! Update scale factors
+      IF (.NOT.ln_linssh) CALL Agrif_Update_vvl()  ! Update vertical mesh from ssh
       !
       CALL Agrif_Update_tra()                      ! Update temperature/salinity
Index: NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_oce_update.F90
===================================================================
--- NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_oce_update.F90	(revision 10009)
+++ NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/NST/agrif_oce_update.F90	(revision 10010)
@@ -249,8 +249,8 @@
       INTEGER ::   jk      ! dummy loop index
       REAL(wp)::   zcoef   ! local scalar
-      !!----------------------------------------------------------------------
-      !
-      IF (lwp.AND.lk_agrif_debug)   Write(*,*) 'Finalize e3 on grid Number', &
-         &                                      Agrif_Fixed(), 'Step', Agrif_Nb_Step()
+      REAL(wp), DIMENSION(jpi,jpj) ::   zssht_h, zsshu_h, zsshv_h, zsshf_h
+      !!----------------------------------------------------------------------
+      !
+      IF (lwp.AND.lk_agrif_debug)   Write(*,*) 'Finalize e3 on grid Number', Agrif_Fixed(), 'Step', Agrif_Nb_Step()
 
       ! Save "old" scale factor (prior update) for subsequent asselin correction of prognostic variables
@@ -263,45 +263,15 @@
       hv_a(:,:) = hv_n(:,:)
 
-      ! 1) NOW fields
-      !--------------
-      !                       ! Vertical scale factor interpolations
-      CALL dom_vvl_interpol( e3t_n(:,:,:), e3u_n (:,:,:) , 'U' )
-      CALL dom_vvl_interpol( e3t_n(:,:,:), e3v_n (:,:,:) , 'V' )
-      CALL dom_vvl_interpol( e3u_n(:,:,:), e3f_n (:,:,:) , 'F' )
-      CALL dom_vvl_interpol( e3u_n(:,:,:), e3uw_n(:,:,:), 'UW' )
-      CALL dom_vvl_interpol( e3v_n(:,:,:), e3vw_n(:,:,:), 'VW' )
-      !
-      !                       ! Update total depths
-      hu_n(:,:) = 0._wp                        ! Ocean depth at U-points
-      hv_n(:,:) = 0._wp                        ! Ocean depth at V-points
-      DO jk = 1, jpkm1
-         hu_n(:,:) = hu_n(:,:) + e3u_n(:,:,jk) * umask(:,:,jk)
-         hv_n(:,:) = hv_n(:,:) + e3v_n(:,:,jk) * vmask(:,:,jk)
-      END DO
-      !                                        ! Inverse of the local depth
-      r1_hu_n(:,:) = ssumask(:,:) / ( hu_n(:,:) + 1._wp - ssumask(:,:) )
-      r1_hv_n(:,:) = ssvmask(:,:) / ( hv_n(:,:) + 1._wp - ssvmask(:,:) )
-
-
-      ! 2) BEFORE fields:
-      !------------------
+      !                          !* NOW fields : 
+      CALL ssh2e3_now                  ! set: ht , hu , hv , r1_hu, r1_hv
+      !                                !      e3t, e3w, e3u, e3uw, e3v, e3vw, e3f   (from 1 to jpkm1)
+      !                                !      gdept_n, gdepw_n, gde3w_n
+
+      !                          !* BEFORE fields : 
       IF (.NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN
-!!gm      IF (.NOT.(lk_agrif_fstep.AND.(neuler==0) )) THEN
-         !                    ! Vertical scale factor interpolations
-         CALL dom_vvl_interpol( e3t_b(:,:,:), e3u_b (:,:,:), 'U'  )
-         CALL dom_vvl_interpol( e3t_b(:,:,:), e3v_b (:,:,:), 'V'  )
-         CALL dom_vvl_interpol( e3u_b(:,:,:), e3uw_b(:,:,:), 'UW' )
-         CALL dom_vvl_interpol( e3v_b(:,:,:), e3vw_b(:,:,:), 'VW' )
-         !
-         !                    ! Update total depths:
-         hu_b(:,:) = 0._wp                     ! Ocean depth at U-points
-         hv_b(:,:) = 0._wp                     ! Ocean depth at V-points
-         DO jk = 1, jpkm1
-            hu_b(:,:) = hu_b(:,:) + e3u_b(:,:,jk) * umask(:,:,jk)
-            hv_b(:,:) = hv_b(:,:) + e3v_b(:,:,jk) * vmask(:,:,jk)
-         END DO
-         !                                     ! Inverse of the local depth
-         r1_hu_b(:,:) = ssumask(:,:) / ( hu_b(:,:) + 1._wp - ssumask(:,:) )
-         r1_hv_b(:,:) = ssvmask(:,:) / ( hv_b(:,:) + 1._wp - ssvmask(:,:) )
+         !
+         CALL ssh2e3_before               ! set:      hu , hv , r1_hu, r1_hv 
+         !                                !      e3t, e3w, e3u, e3uw, e3v, e3vw        (from 1 to jpkm1)
+         !
       ENDIF
       !
@@ -457,5 +427,5 @@
                            ztnu = tabres(ji,jj,jk,jn)
                            ztno = tsn(ji,jj,jk,jn) * e3t_a(ji,jj,jk)
-                           tsb(ji,jj,jk,jn) = ( ztb + rn_rn_atfp * ( ztnu - ztno) ) / e3t_b(ji,jj,jk) * tmask(ji,jj,jk)
+                           tsb(ji,jj,jk,jn) = ( ztb + rn_atfp * ( ztnu - ztno) ) / e3t_b(ji,jj,jk) * tmask(ji,jj,jk)
                         ENDIF
                      END DO
@@ -971,5 +941,5 @@
                ! Update barotropic velocities:
                IF ( .NOT.ln_dynspg_ts .OR. ( ln_dynspg_ts .AND. .NOT.ln_bt_fw ) ) THEN
-                  IF ( .NOT.( lk_agrif_fstep. AND. l_1st_euler ) ) THEN    ! Add asselin part
+                  IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN    ! Add asselin part
 !!gm                  IF (.NOT.(lk_agrif_fstep.AND.(neuler==0))) THEN ! Add asselin part
                      zcorr = (tabres(ji,jj) - vn_b(ji,jj) * hv_a(ji,jj)) * r1_hv_b(ji,jj)
@@ -1212,5 +1182,5 @@
                zcor = rn_Dt * r1_e1e2t(ji,j1  ) * e1v(ji,j1  ) * ( vb2_b(ji,j1)-tabres(ji,j1) )
                ssh(ji,j1  ,Nnn) = ssh(ji,j1  ,Nnn) + zcor
-               IF ( .NOT.( lk_agrif_fstep .AND. l_euler ) )   ssh(ji,j1  ,Nbb) = ssh(ji,j1,Nbb) + rn_atfp * zcor
+               IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) )   ssh(ji,j1  ,Nbb) = ssh(ji,j1,Nbb) + rn_atfp * zcor
 !!gm               IF (.NOT.(lk_agrif_fstep.AND.(neuler==0))) sshb(ji,j1  ) = sshb(ji,j1) + rn_atfp * zcor
             END DO
@@ -1367,5 +1337,5 @@
 !         hdivn(i1:i2,j1:j2,1:jpkm1)   = e3t_b(i1:i2,j1:j2,1:jpkm1)
 
-         IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler==0 ) ) THEN
+         IF ( .NOT.( lk_agrif_fstep .AND. l_1st_euler ) ) THEN
 !!gm         IF (.NOT.(lk_agrif_fstep.AND.(neuler==0) )) THEN
             DO jk = 1, jpkm1
Index: NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/OCE/stpRK3.F90
===================================================================
--- NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/OCE/stpRK3.F90	(revision 10009)
+++ NEMO/branches/2018/dev_r9838_ENHANCE04_RK3/src/OCE/stpRK3.F90	(revision 10010)
@@ -314,5 +314,5 @@
       ! AGRIF
       !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<      
-                         CALL Agrif_Integrate_ChildGrids( stp )  ! allows to finish all the Child Grids before updating
+                         CALL Agrif_Integrate_ChildGrids( stp_RK3 )  ! allows to finish all the Child Grids before updating
 
                          IF( Agrif_NbStepint() == 0 ) CALL Agrif_update_all( ) ! Update all components
