Index: branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmbkg.F90
===================================================================
--- branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmbkg.F90	(revision 5621)
+++ branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmbkg.F90	(revision 5956)
@@ -18,6 +18,4 @@
 
    !!----------------------------------------------------------------------
-   !!   'key_asminc' : Switch on the assimilation increment interface
-   !!----------------------------------------------------------------------
    !!   asm_bkg_wri  : Write out the background state
    !!   asm_trj_wri  : Write out the model state trajectory (used with 4D-Var)
@@ -27,6 +25,6 @@
    USE zdf_oce            ! Vertical mixing variables
    USE zdfddm             ! Double diffusion mixing parameterization
-   USE ldftra_oce         ! Lateral tracer mixing coefficient defined in memory
-   USE ldfslp             ! Slopes of neutral surfaces
+   USE ldftra             ! Lateral diffusion: eddy diffusivity coefficients
+   USE ldfslp             ! Lateral diffusion: slopes of neutral surfaces
    USE tradmp             ! Tracer damping
 #if defined key_zdftke
@@ -36,12 +34,8 @@
    USE zdfmxl             ! Mixed layer depth
    USE dom_oce, ONLY :   ndastp
-   USE sol_oce, ONLY :   gcx   ! Solver variables defined in memory
    USE in_out_manager     ! I/O manager
    USE iom                ! I/O module
    USE asmpar             ! Parameters for the assmilation interface
    USE zdfmxl             ! mixed layer depth
-#if defined key_traldf_c2d
-   USE ldfeiv             ! eddy induced velocity coef.      (ldf_eiv routine)
-#endif
 #if defined key_lim2
    USE ice_2
@@ -119,5 +113,4 @@
             CALL iom_rstput( kt, nitbkg_r, inum, 'en'     , en                )
 #endif
-            CALL iom_rstput( kt, nitbkg_r, inum, 'gcx'    , gcx               )
             !
             CALL iom_close( inum )
@@ -155,10 +148,10 @@
             CALL iom_rstput( kt, nitdin_r, inum, 'sshn'   , sshn              )
 #if defined key_lim2 || defined key_lim3
-            IF(( nn_ice == 2 ) .OR. ( nn_ice == 3 )) THEN
-	       IF(ALLOCATED(frld)) THEN
-                  CALL iom_rstput( kt, nitdin_r, inum, 'iceconc', 1.0 - frld(:,:)   )
+            IF( nn_ice == 2  .OR.  nn_ice == 3 ) THEN
+	            IF( ALLOCATED(frld) ) THEN
+                  CALL iom_rstput( kt, nitdin_r, inum, 'iceconc', 1._wp - frld(:,:)   )
                ELSE
-		  CALL ctl_warn('Ice concentration not written to background as ice variable frld not allocated on this timestep')
-	       ENDIF
+		            CALL ctl_warn('Ice concentration not written to background as ice variable frld not allocated on this timestep')
+	            ENDIF
             ENDIF
 #endif
Index: branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90
===================================================================
--- branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90	(revision 5621)
+++ branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90	(revision 5956)
@@ -14,6 +14,4 @@
 
    !!----------------------------------------------------------------------
-   !!   'key_asminc'   : Switch on the assimilation increment interface
-   !!----------------------------------------------------------------------
    !!   asm_inc_init   : Initialize the increment arrays and IAU weights
    !!   calc_date      : Compute the calendar date YYYYMMDD on a given step
@@ -28,5 +26,5 @@
    USE domvvl           ! domain: variable volume level
    USE oce              ! Dynamics and active tracers defined in memory
-   USE ldfdyn_oce       ! ocean dynamics: lateral physics
+   USE ldfdyn           ! lateral diffusion: eddy viscosity coefficients
    USE eosbn2           ! Equation of state - in situ and potential density
    USE zpshde           ! Partial step : Horizontal Derivative
@@ -56,14 +54,14 @@
     LOGICAL, PUBLIC, PARAMETER :: lk_asminc = .FALSE.  !: No assimilation increments
 #endif
-   LOGICAL, PUBLIC :: ln_bkgwri = .FALSE.      !: No output of the background state fields
-   LOGICAL, PUBLIC :: ln_asmiau = .FALSE.      !: No applying forcing with an assimilation increment
-   LOGICAL, PUBLIC :: ln_asmdin = .FALSE.      !: No direct initialization
-   LOGICAL, PUBLIC :: ln_trainc = .FALSE.      !: No tracer (T and S) assimilation increments
-   LOGICAL, PUBLIC :: ln_dyninc = .FALSE.      !: No dynamics (u and v) assimilation increments
-   LOGICAL, PUBLIC :: ln_sshinc = .FALSE.      !: No sea surface height assimilation increment
-   LOGICAL, PUBLIC :: ln_seaiceinc             !: No sea ice concentration increment
-   LOGICAL, PUBLIC :: ln_salfix = .FALSE.      !: Apply minimum salinity check
+   LOGICAL, PUBLIC :: ln_bkgwri     !: No output of the background state fields
+   LOGICAL, PUBLIC :: ln_asmiau     !: No applying forcing with an assimilation increment
+   LOGICAL, PUBLIC :: ln_asmdin     !: No direct initialization
+   LOGICAL, PUBLIC :: ln_trainc     !: No tracer (T and S) assimilation increments
+   LOGICAL, PUBLIC :: ln_dyninc     !: No dynamics (u and v) assimilation increments
+   LOGICAL, PUBLIC :: ln_sshinc     !: No sea surface height assimilation increment
+   LOGICAL, PUBLIC :: ln_seaiceinc  !: No sea ice concentration increment
+   LOGICAL, PUBLIC :: ln_salfix     !: Apply minimum salinity check
    LOGICAL, PUBLIC :: ln_temnofreeze = .FALSE. !: Don't allow the temperature to drop below freezing
-   INTEGER, PUBLIC :: nn_divdmp                !: Apply divergence damping filter nn_divdmp times
+   INTEGER, PUBLIC :: nn_divdmp     !: Apply divergence damping filter nn_divdmp times
 
    REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE ::   t_bkg   , s_bkg      !: Background temperature and salinity
@@ -90,5 +88,4 @@
    !! * Substitutions
 #  include "domzgr_substitute.h90"
-#  include "ldfdyn_substitute.h90"
 #  include "vectopt_loop_substitute.h90"
    !!----------------------------------------------------------------------
@@ -139,5 +136,5 @@
       ! Read Namelist nam_asminc : assimilation increment interface
       !-----------------------------------------------------------------------
-      ln_seaiceinc = .FALSE.
+      ln_seaiceinc   = .FALSE.
       ln_temnofreeze = .FALSE.
 
@@ -428,13 +425,11 @@
 
       IF ( ln_dyninc .AND. nn_divdmp > 0 ) THEN
-
-         CALL wrk_alloc(jpi,jpj,hdiv) 
-
-         DO  jt = 1, nn_divdmp
-
+         !
+         CALL wrk_alloc( jpi,jpj,   hdiv ) 
+         !
+         DO jt = 1, nn_divdmp
+            !
             DO jk = 1, jpkm1
-
                hdiv(:,:) = 0._wp
-
                DO jj = 2, jpjm1
                   DO ji = fs_2, fs_jpim1   ! vector opt.
@@ -444,30 +439,26 @@
                          + e1v(ji  ,jj  ) * fse3v(ji  ,jj  ,jk) * v_bkginc(ji  ,jj  ,jk)     &
                          - e1v(ji  ,jj-1) * fse3v(ji  ,jj-1,jk) * v_bkginc(ji  ,jj-1,jk)  )  &
-                         / ( e1t(ji,jj) * e2t(ji,jj) * fse3t(ji,jj,jk) )
+                         / ( e1e2t(ji,jj) * fse3t(ji,jj,jk) )
                   END DO
                END DO
-
                CALL lbc_lnk( hdiv, 'T', 1. )   ! lateral boundary cond. (no sign change)
-
+               !
                DO jj = 2, jpjm1
                   DO ji = fs_2, fs_jpim1   ! vector opt.
-                     u_bkginc(ji,jj,jk) = u_bkginc(ji,jj,jk) + 0.2_wp * ( e1t(ji+1,jj)*e2t(ji+1,jj) * hdiv(ji+1,jj)   &
-                                                                        - e1t(ji  ,jj)*e2t(ji  ,jj) * hdiv(ji  ,jj) ) &
-                                                                      / e1u(ji,jj) * umask(ji,jj,jk) 
-                     v_bkginc(ji,jj,jk) = v_bkginc(ji,jj,jk) + 0.2_wp * ( e1t(ji,jj+1)*e2t(ji,jj+1) * hdiv(ji,jj+1)   &
-                                                                        - e1t(ji,jj  )*e2t(ji,jj  ) * hdiv(ji,jj  ) ) &
-                                                                      / e2v(ji,jj) * vmask(ji,jj,jk) 
+                     u_bkginc(ji,jj,jk) = u_bkginc(ji,jj,jk) + 0.2_wp * ( e1e2t(ji+1,jj) * hdiv(ji+1,jj)   &
+                        &                                               - e1e2t(ji  ,jj) * hdiv(ji  ,jj) ) &
+                        &                                             * r1_e1u(ji,jj) * umask(ji,jj,jk) 
+                     v_bkginc(ji,jj,jk) = v_bkginc(ji,jj,jk) + 0.2_wp * ( e1e2t(ji,jj+1) * hdiv(ji,jj+1)   &
+                        &                                               - e1e2t(ji,jj  ) * hdiv(ji,jj  ) ) &
+                        &                                             * r1_e2v(ji,jj) * vmask(ji,jj,jk) 
                   END DO
                END DO
-
             END DO
-
+            !
          END DO
-
-         CALL wrk_dealloc(jpi,jpj,hdiv) 
-
+         !
+         CALL wrk_dealloc( jpi,jpj,   hdiv ) 
+         !
       ENDIF
-
-
 
       !-----------------------------------------------------------------------
@@ -476,5 +467,5 @@
 
       IF ( ln_asmdin ) THEN
-
+         !
          ALLOCATE( t_bkg(jpi,jpj,jpk) )
          ALLOCATE( s_bkg(jpi,jpj,jpk) )
@@ -482,30 +473,29 @@
          ALLOCATE( v_bkg(jpi,jpj,jpk) )
          ALLOCATE( ssh_bkg(jpi,jpj)   )
-
-         t_bkg(:,:,:) = 0.0
-         s_bkg(:,:,:) = 0.0
-         u_bkg(:,:,:) = 0.0
-         v_bkg(:,:,:) = 0.0
-         ssh_bkg(:,:) = 0.0
-
+         !
+         t_bkg(:,:,:) = 0._wp
+         s_bkg(:,:,:) = 0._wp
+         u_bkg(:,:,:) = 0._wp
+         v_bkg(:,:,:) = 0._wp
+         ssh_bkg(:,:) = 0._wp
+         !
          !--------------------------------------------------------------------
          ! Read from file the background state at analysis time
          !--------------------------------------------------------------------
-
+         !
          CALL iom_open( c_asmdin, inum )
-
+         !
          CALL iom_get( inum, 'rdastp', zdate_bkg ) 
-        
+         !
          IF(lwp) THEN
             WRITE(numout,*) 
-            WRITE(numout,*) 'asm_inc_init : Assimilation background state valid at : ', &
-               &  NINT( zdate_bkg )
+            WRITE(numout,*) 'asm_inc_init : Assimilation background state valid at : ', NINT( zdate_bkg )
             WRITE(numout,*) '~~~~~~~~~~~~'
          ENDIF
-
+         !
          IF ( NINT( zdate_bkg ) /= iitdin_date ) &
             & CALL ctl_warn( ' Validity time of assimilation background state does', &
             &                ' not agree with Direct Initialization time' )
-
+         !
          IF ( ln_trainc ) THEN   
             CALL iom_get( inum, jpdom_autoglo, 'tn', t_bkg )
@@ -514,5 +504,5 @@
             s_bkg(:,:,:) = s_bkg(:,:,:) * tmask(:,:,:)
          ENDIF
-
+         !
          IF ( ln_dyninc ) THEN   
             CALL iom_get( inum, jpdom_autoglo, 'un', u_bkg )
@@ -521,12 +511,12 @@
             v_bkg(:,:,:) = v_bkg(:,:,:) * vmask(:,:,:)
          ENDIF
-        
+         !
          IF ( ln_sshinc ) THEN
             CALL iom_get( inum, jpdom_autoglo, 'sshn', ssh_bkg )
             ssh_bkg(:,:) = ssh_bkg(:,:) * tmask(:,:,1)
          ENDIF
-
+         !
          CALL iom_close( inum )
-
+         !
       ENDIF
       !
@@ -574,8 +564,6 @@
       ! If kt = kit000 - 1 then set the date to the restart date
       IF ( kt == kit000 - 1 ) THEN
-
          kdate = ndastp
          RETURN
-
       ENDIF
 
@@ -646,30 +634,27 @@
       !! ** Action  : 
       !!----------------------------------------------------------------------
-      INTEGER, INTENT(IN) :: kt               ! Current time step
-      !
-      INTEGER :: ji,jj,jk
-      INTEGER :: it
+      INTEGER, INTENT(IN) ::   kt   ! Current time step
+      !
+      INTEGER  :: ji, jj, jk
+      INTEGER  :: it
       REAL(wp) :: zincwgt  ! IAU weight for current time step
       REAL (wp), DIMENSION(jpi,jpj,jpk) :: fzptnz ! 3d freezing point values
       !!----------------------------------------------------------------------
-
+      !
       ! freezing point calculation taken from oc_fz_pt (but calculated for all depths) 
       ! used to prevent the applied increments taking the temperature below the local freezing point 
-
       DO jk = 1, jpkm1
         CALL eos_fzp( tsn(:,:,jk,jp_sal), fzptnz(:,:,jk), fsdept(:,:,jk) )
       END DO
-
-      IF ( ln_asmiau ) THEN
-
-         !--------------------------------------------------------------------
-         ! Incremental Analysis Updating
-         !--------------------------------------------------------------------
-
+         !
+         !                             !--------------------------------------
+      IF ( ln_asmiau ) THEN            ! Incremental Analysis Updating
+         !                             !--------------------------------------
+         !
          IF ( ( kt >= nitiaustr_r ).AND.( kt <= nitiaufin_r ) ) THEN
-
+            !
             it = kt - nit000 + 1
             zincwgt = wgtiau(it) / rdt   ! IAU weight for the current time step
-
+            !
             IF(lwp) THEN
                WRITE(numout,*) 
@@ -677,5 +662,5 @@
                WRITE(numout,*) '~~~~~~~~~~~~'
             ENDIF
-
+            !
             ! Update the tracer tendencies
             DO jk = 1, jpkm1
@@ -700,23 +685,19 @@
                ENDIF
             END DO
-
-         ENDIF
-
+            !
+         ENDIF
+         !
          IF ( kt == nitiaufin_r + 1  ) THEN   ! For bias crcn to work
             DEALLOCATE( t_bkginc )
             DEALLOCATE( s_bkginc )
          ENDIF
-
-
-      ELSEIF ( ln_asmdin ) THEN
-
-         !--------------------------------------------------------------------
-         ! Direct Initialization
-         !--------------------------------------------------------------------
-            
+         !                             !--------------------------------------
+      ELSEIF ( ln_asmdin ) THEN        ! Direct Initialization
+         !                             !--------------------------------------
+         !            
          IF ( kt == nitdin_r ) THEN
-
+            !
             neuler = 0  ! Force Euler forward step
-
+            !
             ! Initialize the now fields with the background + increment
             IF (ln_temnofreeze) THEN
@@ -745,5 +726,4 @@
 !!gm
 
-
             IF( ln_zps .AND. .NOT. lk_c1d .AND. .NOT. ln_isfcav)      &
                &  CALL zps_hde    ( kt, jpts, tsb, gtsu, gtsv,        &  ! Partial steps: before horizontal gradient
@@ -766,5 +746,5 @@
       ENDIF
       ! Perhaps the following call should be in step
-      IF   ( ln_seaiceinc  )   CALL seaice_asm_inc ( kt )   ! apply sea ice concentration increment
+      IF ( ln_seaiceinc  )   CALL seaice_asm_inc ( kt )   ! apply sea ice concentration increment
       !
    END SUBROUTINE tra_asm_inc
@@ -787,23 +767,20 @@
       REAL(wp) :: zincwgt  ! IAU weight for current time step
       !!----------------------------------------------------------------------
-
-      IF ( ln_asmiau ) THEN
-
-         !--------------------------------------------------------------------
-         ! Incremental Analysis Updating
-         !--------------------------------------------------------------------
-
+      !
+      !                          !--------------------------------------------
+      IF ( ln_asmiau ) THEN      ! Incremental Analysis Updating
+         !                       !--------------------------------------------
+         !
          IF ( ( kt >= nitiaustr_r ).AND.( kt <= nitiaufin_r ) ) THEN
-
+            !
             it = kt - nit000 + 1
             zincwgt = wgtiau(it) / rdt   ! IAU weight for the current time step
-
+            !
             IF(lwp) THEN
                WRITE(numout,*) 
-               WRITE(numout,*) 'dyn_asm_inc : Dynamics IAU at time step = ', &
-                  &  kt,' with IAU weight = ', wgtiau(it)
+               WRITE(numout,*) 'dyn_asm_inc : Dynamics IAU at time step = ', kt,' with IAU weight = ', wgtiau(it)
                WRITE(numout,*) '~~~~~~~~~~~~'
             ENDIF
-
+            !
             ! Update the dynamic tendencies
             DO jk = 1, jpkm1
@@ -811,29 +788,26 @@
                va(:,:,jk) = va(:,:,jk) + v_bkginc(:,:,jk) * zincwgt
             END DO
-           
+            !
             IF ( kt == nitiaufin_r ) THEN
                DEALLOCATE( u_bkginc )
                DEALLOCATE( v_bkginc )
             ENDIF
-
-         ENDIF
-
-      ELSEIF ( ln_asmdin ) THEN 
-
-         !--------------------------------------------------------------------
-         ! Direct Initialization
-         !--------------------------------------------------------------------
-         
+            !
+         ENDIF
+         !                          !-----------------------------------------
+      ELSEIF ( ln_asmdin ) THEN     ! Direct Initialization
+         !                          !-----------------------------------------
+         !         
          IF ( kt == nitdin_r ) THEN
-
+            !
             neuler = 0                    ! Force Euler forward step
-
+            !
             ! Initialize the now fields with the background + increment
             un(:,:,:) = u_bkg(:,:,:) + u_bkginc(:,:,:)
             vn(:,:,:) = v_bkg(:,:,:) + v_bkginc(:,:,:)  
-
+            !
             ub(:,:,:) = un(:,:,:)         ! Update before fields
             vb(:,:,:) = vn(:,:,:)
- 
+            !
             DEALLOCATE( u_bkg    )
             DEALLOCATE( v_bkg    )
@@ -863,16 +837,14 @@
       REAL(wp) :: zincwgt  ! IAU weight for current time step
       !!----------------------------------------------------------------------
-
-      IF ( ln_asmiau ) THEN
-
-         !--------------------------------------------------------------------
-         ! Incremental Analysis Updating
-         !--------------------------------------------------------------------
-
+      !
+      !                             !-----------------------------------------
+      IF ( ln_asmiau ) THEN         ! Incremental Analysis Updating
+         !                          !-----------------------------------------
+         !
          IF ( ( kt >= nitiaustr_r ).AND.( kt <= nitiaufin_r ) ) THEN
-
+            !
             it = kt - nit000 + 1
             zincwgt = wgtiau(it) / rdt   ! IAU weight for the current time step
-
+            !
             IF(lwp) THEN
                WRITE(numout,*) 
@@ -881,5 +853,5 @@
                WRITE(numout,*) '~~~~~~~~~~~~'
             ENDIF
-
+            !
             ! Save the tendency associated with the IAU weighted SSH increment
             ! (applied in dynspg.*)
@@ -890,23 +862,18 @@
                DEALLOCATE( ssh_bkginc )
             ENDIF
-
-         ENDIF
-
-      ELSEIF ( ln_asmdin ) THEN
-
-         !--------------------------------------------------------------------
-         ! Direct Initialization
-         !--------------------------------------------------------------------
-
+            !
+         ENDIF
+         !                          !-----------------------------------------
+      ELSEIF ( ln_asmdin ) THEN     ! Direct Initialization
+         !                          !-----------------------------------------
+         !
          IF ( kt == nitdin_r ) THEN
-
-            neuler = 0                    ! Force Euler forward step
-
-            ! Initialize the now fields the background + increment
-            sshn(:,:) = ssh_bkg(:,:) + ssh_bkginc(:,:)  
-
-            ! Update before fields
-            sshb(:,:) = sshn(:,:)         
-
+            !
+            neuler = 0                                   ! Force Euler forward step
+            !
+            sshn(:,:) = ssh_bkg(:,:) + ssh_bkginc(:,:)   ! Initialize the now fields the background + increment
+            !
+            sshb(:,:) = sshn(:,:)                        ! Update before fields
+            !
             IF( lk_vvl ) THEN
                DO jk = 1, jpk
@@ -914,8 +881,8 @@
                END DO
             ENDIF
-
+            !
             DEALLOCATE( ssh_bkg    )
             DEALLOCATE( ssh_bkginc )
-
+            !
          ENDIF
          !
@@ -936,7 +903,5 @@
       !!
       !!----------------------------------------------------------------------
-      IMPLICIT NONE
-      !
-      INTEGER, INTENT(in)           ::   kt   ! Current time step
+      INTEGER, INTENT(in)           ::   kt       ! Current time step
       INTEGER, INTENT(in), OPTIONAL ::   kindic   ! flag for disabling the deallocation
       !
@@ -948,26 +913,23 @@
 #endif
       !!----------------------------------------------------------------------
-
-      IF ( ln_asmiau ) THEN
-
-         !--------------------------------------------------------------------
-         ! Incremental Analysis Updating
-         !--------------------------------------------------------------------
-
+      !
+      !                             !-----------------------------------------
+      IF ( ln_asmiau ) THEN         ! Incremental Analysis Updating
+         !                          !-----------------------------------------
+         !
          IF ( ( kt >= nitiaustr_r ).AND.( kt <= nitiaufin_r ) ) THEN
-
+            !
             it = kt - nit000 + 1
             zincwgt = wgtiau(it)      ! IAU weight for the current time step 
             ! note this is not a tendency so should not be divided by rdt (as with the tracer and other increments)
-
+            !
             IF(lwp) THEN
                WRITE(numout,*) 
-               WRITE(numout,*) 'seaice_asm_inc : sea ice conc IAU at time step = ', &
-                  &  kt,' with IAU weight = ', wgtiau(it)
+               WRITE(numout,*) 'seaice_asm_inc : sea ice conc IAU at time step = ', kt,' with IAU weight = ', wgtiau(it)
                WRITE(numout,*) '~~~~~~~~~~~~'
             ENDIF
-
+            !
             ! Sea-ice : LIM-3 case (to add)
-
+            !
 #if defined key_lim2
             ! Sea-ice : LIM-2 case
@@ -1007,22 +969,18 @@
 
 #if defined key_cice && defined key_asminc
-            ! Sea-ice : CICE case. Zero ice increment tendency into CICE
-            ndaice_da(:,:) = 0.0_wp
-#endif
-
-         ENDIF
-
-      ELSEIF ( ln_asmdin ) THEN
-
-         !--------------------------------------------------------------------
-         ! Direct Initialization
-         !--------------------------------------------------------------------
-
+            ndaice_da(:,:) = 0._wp        ! Sea-ice : CICE case. Zero ice increment tendency into CICE
+#endif
+
+         ENDIF
+         !                          !-----------------------------------------
+      ELSEIF ( ln_asmdin ) THEN     ! Direct Initialization
+         !                          !-----------------------------------------
+         !
          IF ( kt == nitdin_r ) THEN
-
+            !
             neuler = 0                    ! Force Euler forward step
-
+            !
             ! Sea-ice : LIM-3 case (to add)
-
+            !
 #if defined key_lim2
             ! Sea-ice : LIM-2 case.
@@ -1040,5 +998,5 @@
                zhicifinc(:,:) = (zhicifmin - hicif(:,:)) * zincwgt    
             ELSEWHERE
-               zhicifinc(:,:) = 0.0_wp
+               zhicifinc(:,:) = 0._wp
             END WHERE
             !
@@ -1049,20 +1007,20 @@
             ! seaice salinity balancing (to add)
 #endif
- 
+            !
 #if defined key_cice && defined key_asminc
             ! Sea-ice : CICE case. Pass ice increment tendency into CICE
            ndaice_da(:,:) = seaice_bkginc(:,:) / rdt
 #endif
-           IF ( .NOT. PRESENT(kindic) ) THEN
-              DEALLOCATE( seaice_bkginc )
-           END IF
-
+            IF ( .NOT. PRESENT(kindic) ) THEN
+               DEALLOCATE( seaice_bkginc )
+            END IF
+            !
          ELSE
-
+            !
 #if defined key_cice && defined key_asminc
-            ! Sea-ice : CICE case. Zero ice increment tendency into CICE 
-            ndaice_da(:,:) = 0.0_wp
-#endif
-         
+            ndaice_da(:,:) = 0._wp     ! Sea-ice : CICE case. Zero ice increment tendency into CICE
+
+#endif
+            !
          ENDIF
 
@@ -1141,7 +1099,7 @@
 !
 !#endif
-
+         !
       ENDIF
-
+      !
    END SUBROUTINE seaice_asm_inc
    
Index: branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmpar.F90
===================================================================
--- branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmpar.F90	(revision 5621)
+++ branches/2015/dev_r5151_UKMO_ISF/NEMOGCM/NEMO/OPA_SRC/ASM/asmpar.F90	(revision 5956)
@@ -6,27 +6,19 @@
 
    IMPLICIT NONE
-
-   !! * Routine accessibility
    PRIVATE
 
-   !! * Shared Modules variables
-   CHARACTER (LEN=40), PUBLIC, PARAMETER :: &
-      & c_asmbkg = 'assim_background_state_Jb',  & !: Filename for storing the 
-                                                   !: background state for use 
-                                                   !: in the Jb term
-      & c_asmdin = 'assim_background_state_DI',  & !: Filename for storing the 
-                                                   !: background state for direct 
-                                                   !: initialization
-      & c_asmtrj = 'assim_trj',                  & !: Filename for storing the 
-                                                   !: reference trajectory
-      & c_asminc = 'assim_background_increments'   !: Filename for storing the 
-                                                   !: increments to the background
-                                                   !: state
+   CHARACTER(LEN=40), PUBLIC, PARAMETER ::   c_asmbkg = 'assim_background_state_Jb'   !: Filename for storing the background state
+   !                                                                                  !  for use in the Jb term
+   CHARACTER(LEN=40), PUBLIC, PARAMETER ::   c_asmdin = 'assim_background_state_DI'   !: Filename for storing the background state
+   !                                                                                  !  for direct initialization
+   CHARACTER(LEN=40), PUBLIC, PARAMETER ::   c_asmtrj = 'assim_trj'                   !: Filename for storing the reference trajectory
+   CHARACTER(LEN=40), PUBLIC, PARAMETER ::   c_asminc = 'assim_background_increments' !: Filename for storing the increments 
+   !                                                                                  !  to the background state
 
-   INTEGER, PUBLIC :: nitbkg_r      !: Background time step referenced to nit000
-   INTEGER, PUBLIC :: nitdin_r      !: Direct Initialization time step referenced to nit000
-   INTEGER, PUBLIC :: nitiaustr_r   !: IAU starting time step referenced to nit000
-   INTEGER, PUBLIC :: nitiaufin_r   !: IAU final time step referenced to nit000
-   INTEGER, PUBLIC :: nittrjfrq     !: Frequency of trajectory output for 4D-VAR
+   INTEGER, PUBLIC ::   nitbkg_r      !: Background time step referenced to nit000
+   INTEGER, PUBLIC ::   nitdin_r      !: Direct Initialization time step referenced to nit000
+   INTEGER, PUBLIC ::   nitiaustr_r   !: IAU starting time step referenced to nit000
+   INTEGER, PUBLIC ::   nitiaufin_r   !: IAU final time step referenced to nit000
+   INTEGER, PUBLIC ::   nittrjfrq     !: Frequency of trajectory output for 4D-VAR
 
    !!----------------------------------------------------------------------
@@ -34,5 +26,4 @@
    !! $Id$
    !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt)
-   !!----------------------------------------------------------------------
-
+   !!======================================================================
 END MODULE asmpar
