Index: NEMO/trunk/tests/ISOMIP+/MY_SRC/isfstp.F90
===================================================================
--- NEMO/trunk/tests/ISOMIP+/MY_SRC/isfstp.F90	(revision 13583)
+++ NEMO/trunk/tests/ISOMIP+/MY_SRC/isfstp.F90	(revision 14995)
@@ -2,5 +2,5 @@
    !!======================================================================
    !!                       ***  MODULE  isfstp  ***
-   !! Surface module :  compute iceshelf load, melt and heat flux
+   !! Ice Shelves :  compute iceshelf load, melt and heat flux
    !!======================================================================
    !! History :  3.2  !  2011-02  (C.Harris  ) Original code isf cav
@@ -42,8 +42,7 @@
    !! Software governed by the CeCILL license (see ./LICENSE)
    !!----------------------------------------------------------------------
-
 CONTAINS
  
-  SUBROUTINE isf_stp( kt, Kmm )
+   SUBROUTINE isf_stp( kt, Kmm )
       !!---------------------------------------------------------------------
       !!                  ***  ROUTINE isf_stp  ***
@@ -58,11 +57,12 @@
       !!              - compute fluxes
       !!              - write restart variables
-      !!
-      !!----------------------------------------------------------------------
-      INTEGER, INTENT(in) ::   kt   ! ocean time step
-      INTEGER, INTENT(in) ::   Kmm  ! ocean time level index
-      !!----------------------------------------------------------------------
-      INTEGER :: jk                               ! loop index
-      REAL(wp), DIMENSION(jpi,jpj,jpk) :: ze3t    ! e3t 
+      !!----------------------------------------------------------------------
+      INTEGER, INTENT(in) ::   kt    ! ocean time step
+      INTEGER, INTENT(in) ::   Kmm   ! ocean time level index
+      !
+      INTEGER :: jk                              ! loop index
+#if defined key_qco
+      REAL(wp), DIMENSION(jpi,jpj,jpk) :: ze3t   ! 3D workspace
+#endif
       !!---------------------------------------------------------------------
       !
@@ -83,11 +83,15 @@
          ! 1.2: compute misfkb, rhisf_tbl, rfrac (deepest level, thickness, fraction of deepest cell affected by tbl)
          rhisf_tbl_cav(:,:) = rn_htbl * mskisf_cav(:,:)
+#if defined key_qco
          DO jk = 1, jpk
             ze3t(:,:,jk) = e3t(:,:,jk,Kmm)
          END DO 
-         CALL isf_tbl_lvl(ht(:,:), ze3t, misfkt_cav, misfkb_cav, rhisf_tbl_cav, rfrac_tbl_cav)
+         CALL isf_tbl_lvl( ht(:,:), ze3t           , misfkt_cav, misfkb_cav, rhisf_tbl_cav, rfrac_tbl_cav )
+#else
+         CALL isf_tbl_lvl( ht(:,:),  e3t(:,:,:,Kmm), misfkt_cav, misfkb_cav, rhisf_tbl_cav, rfrac_tbl_cav )
+#endif
          !
          ! 1.3: compute ice shelf melt
-         CALL isf_cav( kt, Kmm, risf_cav_tsc, fwfisf_cav)
+         CALL isf_cav( kt, Kmm, risf_cav_tsc, fwfisf_cav )
          !
       END IF
@@ -108,11 +112,15 @@
          ! by simplicity, we assume the top level where param applied do not change with time (done in init part)
          rhisf_tbl_par(:,:) = rhisf0_tbl_par(:,:)
+#if defined key_qco
          DO jk = 1, jpk
             ze3t(:,:,jk) = e3t(:,:,jk,Kmm)
          END DO
-         CALL isf_tbl_lvl(ht(:,:), ze3t, misfkt_par, misfkb_par, rhisf_tbl_par, rfrac_tbl_par)
+         CALL isf_tbl_lvl( ht(:,:), ze3t           , misfkt_par, misfkb_par, rhisf_tbl_par, rfrac_tbl_par )
+#else
+         CALL isf_tbl_lvl( ht(:,:),  e3t(:,:,:,Kmm), misfkt_par, misfkb_par, rhisf_tbl_par, rfrac_tbl_par )
+#endif
          !
          ! 2.3: compute ice shelf melt
-         CALL isf_par( kt, Kmm, risf_par_tsc, fwfisf_par)
+         CALL isf_par( kt, Kmm, risf_par_tsc, fwfisf_par )
          !
       END IF
@@ -128,5 +136,6 @@
    END SUBROUTINE isf_stp
 
-   SUBROUTINE isf_init(Kbb, Kmm, Kaa)
+   
+   SUBROUTINE isf_init( Kbb, Kmm, Kaa )
       !!---------------------------------------------------------------------
       !!                  ***  ROUTINE isfstp_init  ***
@@ -142,34 +151,25 @@
       !!              - call cav/param/isfcpl init routine
       !!----------------------------------------------------------------------
-      INTEGER, INTENT(in) :: Kbb, Kmm, Kaa      ! ocean time level indices
+      INTEGER, INTENT(in) ::   Kbb, Kmm, Kaa   ! ocean time level indices
+      !!----------------------------------------------------------------------
       !
       ! constrain: l_isfoasis need to be known
       !
-      ! Read namelist
-      CALL isf_nam()
-      !
-      ! Allocate public array
-      CALL isf_alloc()
-      !
-      ! check option compatibility
-      CALL isf_ctl()
-      !
-      ! compute ice shelf load
-      IF ( ln_isfcav ) CALL isf_load( Kmm, risfload )
+      CALL isf_nam()                                              ! Read namelist
+      !
+      CALL isf_alloc()                                            ! Allocate public array
+      !
+      CALL isf_ctl()                                              ! check option compatibility
+      !
+      IF( ln_isfcav ) CALL isf_load( Kmm, risfload )              ! compute ice shelf load
       !
       ! terminate routine now if no ice shelf melt formulation specify
-      IF ( ln_isf ) THEN
-         !
-         !---------------------------------------------------------------------------------------------------------------------
-         ! initialisation melt in the cavity
-         IF ( ln_isfcav_mlt ) CALL isf_cav_init()
-         !
-         !---------------------------------------------------------------------------------------------------------------------
-         ! initialisation parametrised melt
-         IF ( ln_isfpar_mlt ) CALL isf_par_init()
-         !
-         !---------------------------------------------------------------------------------------------------------------------
-         ! initialisation ice sheet coupling
-         IF( ln_isfcpl ) CALL isfcpl_init(Kbb, Kmm, Kaa)
+      IF( ln_isf ) THEN
+         !
+         IF( ln_isfcav_mlt )   CALL isf_cav_init()                ! initialisation melt in the cavity
+         !
+         IF( ln_isfpar_mlt )   CALL isf_par_init()                ! initialisation parametrised melt
+         !
+         IF( ln_isfcpl     )   CALL isfcpl_init( Kbb, Kmm, Kaa )  ! initialisation ice sheet coupling
          !
       END IF
@@ -177,4 +177,5 @@
   END SUBROUTINE isf_init
 
+  
   SUBROUTINE isf_ctl()
       !!---------------------------------------------------------------------
@@ -283,5 +284,6 @@
       END IF
    END SUBROUTINE isf_ctl
-   !
+
+   
    SUBROUTINE isf_nam
       !!---------------------------------------------------------------------
@@ -299,5 +301,6 @@
          &             sn_isfpar_zmin, sn_isfpar_zmax, sn_isfpar_Leff,                           &
          &             ln_isfcpl     , nn_drown      , ln_isfcpl_cons, ln_isfdebug, rn_vtide,    &
-         &             cn_isfload    , rn_isfload_T  , rn_isfload_S  , cn_isfdir
+         &             cn_isfload    , rn_isfload_T  , rn_isfload_S  , cn_isfdir  ,              &
+         &             rn_isfpar_bg03_gt0
       !!----------------------------------------------------------------------
       !
