Index: branches/2015/dev_r5171_CNRS_LIM3_seaicebgc/NEMOGCM/NEMO/TOP_SRC/TRP/trcsbc.F90
===================================================================
--- branches/2015/dev_r5171_CNRS_LIM3_seaicebgc/NEMOGCM/NEMO/TOP_SRC/TRP/trcsbc.F90	(revision 5184)
+++ branches/2015/dev_r5171_CNRS_LIM3_seaicebgc/NEMOGCM/NEMO/TOP_SRC/TRP/trcsbc.F90	(revision 5193)
@@ -63,6 +63,6 @@
       !
       INTEGER  ::   ji, jj, jn                                     ! dummy loop indices
-      REAL(wp) ::   zsrau, zse3t                                   ! temporary scalars
-      REAL(wp) ::   zswitch, zftra, zcd, zdtra, ztfx, ztra, zeuler ! temporary scalars
+      REAL(wp) ::   zse3t                                          ! temporary scalars
+      REAL(wp) ::   zswitch, zftra, zcd, zdtra, ztfx, ztra         ! temporary scalars
       CHARACTER (len=22) :: charout
       REAL(wp), POINTER, DIMENSION(:,:  ) :: zsfx
@@ -99,9 +99,7 @@
       ENDIF
 
+      WRITE(numout,*) ' trc_sbc initial values', trn(3,2,1,2), trb(3,2,1,2), tra(3,2,1,2)
+
       ! 0. initialization
-      zsrau = 1. / rau0
-
-      zeuler = 1.   ;  IF ( neuler .EQ. 0 ) zeuler = 0.
-
       DO jn = 1, jptra
          !
@@ -114,5 +112,5 @@
                DO ji = fs_2, fs_jpim1   ! vector opt.
                   zse3t = 1. / fse3t(ji,jj,1)
-                  tra(ji,jj,1,jn) = tra(ji,jj,1,jn) + zsfx(ji,jj) *  zsrau * trn(ji,jj,1,jn) * zse3t
+                  tra(ji,jj,1,jn) = tra(ji,jj,1,jn) + zsfx(ji,jj) * r1_rau0 * trn(ji,jj,1,jn) * zse3t
                END DO
             END DO
@@ -122,5 +120,5 @@
             DO jj = 2, jpj
                DO ji = fs_2, fs_jpim1   ! vector opt.
-   
+
                   zse3t = 1. / fse3t(ji,jj,1)
                   
@@ -133,28 +131,27 @@
                   ztfx  = zftra + zswitch * zcd                ! net tracer flux (+C/D if no ice/ocean mass exchange)
    
-                  ! tracer change (left member: euler; right member:leapfrog)
-                  ztra = ( 1. - zeuler ) * trn(ji,jj,1,jn) + zeuler * trb(ji,jj,1,jn)
-                  
-                  ! MAX is there to avoid integral ocean uptake in the case of freezing (for iron)
-                  zdtra = MAX ( - ztra / r2dtra(1) , zsrau * ( ztfx + zsfx(ji,jj) * trn(ji,jj,1,jn) ) * zse3t ) ! tracer tendency
-                  ! r2dtra is time step
-                  tra(ji,jj,1,jn) = tra(ji,jj,1,jn) + zdtra ! new line
+                  zdtra = r1_rau0 * ( ztfx + zsfx(ji,jj) * trn(ji,jj,1,jn) ) * zse3t
+                  tra(ji,jj,1,jn) = MAX( tra(ji,jj,1,jn) + zdtra, 0.) ! avoid integral ocean uptake if freezing (for iron)
    
-   !              IF ( ztfx .NE. 0.0 ) THEN
-   !                  WRITE(numout,*) ji, jj, jn
-   !                  WRITE(numout,*) ' trc_o  : ', trc_o(ji,jj,jn)
-   !                  WRITE(numout,*) ' trc_i  : ', trc_i(ji,jj,jn)
-   !                  WRITE(numout,*) ' fmmflx : ', fmmflx(ji,jj)
-   !                  WRITE(numout,*) ' zswitch: ', zswitch
-   !                  WRITE(numout,*) ' zcd   : ', zcd
-   !                  WRITE(numout,*) ' zftra : ', zftra
-   !                  WRITE(numout,*) ' ztfx  : ', ztfx
-   !                  WRITE(numout,*) ' zsrau : ', zsrau
-   !                  WRITE(numout,*) ' zsfx  : ', zsfx(ji,jj)
-   !                  WRITE(numout,*) ' zse3t : ', zse3t
-   !                  WRITE(numout,*) ' ztra  : ', ztra
-   !                  WRITE(numout,*) ' zdtra : ', zdtra
-   !                  WRITE(numout,*) ' Old tendency : ', zsfx(ji,jj) * zsrau * trn(ji,jj,1,jn) * zse3t
-   !              ENDIF
+!                 IF ( ztfx .NE. 0.0 ) THEN
+                  IF ( ( ji .EQ. 3 ) .AND. ( jj .EQ. 2 )  .AND. ( jn .EQ. 2 ) ) THEN
+                      WRITE(numout,*) ji, jj, jn
+                      WRITE(numout,*) ' trn    : ', trn(ji,jj,1,jn)
+                      WRITE(numout,*) ' trb    : ', trb(ji,jj,1,jn)
+                      WRITE(numout,*) ' tra    : ', tra(ji,jj,1,jn)
+                      WRITE(numout,*) ' trc_o  : ', trc_o(ji,jj,jn)
+                      WRITE(numout,*) ' trc_i  : ', trc_i(ji,jj,jn)
+                      WRITE(numout,*) ' fmmflx : ', fmmflx(ji,jj)
+                      WRITE(numout,*) ' zswitch: ', zswitch
+                      WRITE(numout,*) ' zcd   : ', zcd
+                      WRITE(numout,*) ' zftra : ', zftra
+                      WRITE(numout,*) ' ztfx  : ', ztfx
+                      WRITE(numout,*) ' r1_rau0 : ', r1_rau0
+                      WRITE(numout,*) ' zsfx  : ', zsfx(ji,jj)
+                      WRITE(numout,*) ' zse3t : ', zse3t
+                      WRITE(numout,*) ' ztra  : ', ztra
+                      WRITE(numout,*) ' zdtra : ', zdtra
+                      WRITE(numout,*) ' Old tendency : ', zsfx(ji,jj) * r1_rau0 * trn(ji,jj,1,jn) * zse3t
+                  ENDIF
    
                END DO
