Index: trunk/NEMO/TOP_SRC/sms.F90
===================================================================
--- trunk/NEMO/TOP_SRC/sms.F90	(revision 944)
+++ trunk/NEMO/TOP_SRC/sms.F90	(revision 944)
@@ -0,0 +1,43 @@
+MODULE sms
+   !!======================================================================
+   !!                        ***  sms  ***
+   !! passive tracers :   set the passive tracers variables
+   !!======================================================================
+   !! History :    -   !  2004-03  (C. Ethe)  Free form and module
+   !!----------------------------------------------------------------------
+   !! NEMO/TOP 1.0 , LOCEAN-IPSL (2005) 
+   !! $Header:$ 
+   !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt)
+   !!----------------------------------------------------------------------
+#if defined key_top
+   !!----------------------------------------------------------------------
+   !!   'key_top'                                                TOP models
+   !!----------------------------------------------------------------------
+   USE par_oce
+   USE par_trc
+
+   IMPLICIT NONE
+   PUBLIC
+
+# if defined key_lobster
+   !!----------------------------------------------------------------------
+   !!   'key_lobster'                                     LOBSTER bio-model  
+   !!----------------------------------------------------------------------
+#  include "sms_lobster.h90"
+
+# elif defined key_pisces
+   !!----------------------------------------------------------------------
+   !!   'key_pisces'                                       PISCES bio-model                  
+   !!----------------------------------------------------------------------
+#  include "sms_pisces.h90"
+
+# endif
+
+#else
+   !!----------------------------------------------------------------------
+   !!  Empty module :                                     No passive tracer
+   !!----------------------------------------------------------------------
+#endif
+
+   !!======================================================================
+END MODULE sms
Index: trunk/NEMO/TOP_SRC/top_substitute.h90
===================================================================
--- trunk/NEMO/TOP_SRC/top_substitute.h90	(revision 944)
+++ trunk/NEMO/TOP_SRC/top_substitute.h90	(revision 944)
@@ -0,0 +1,80 @@
+   !!----------------------------------------------------------------------
+   !!                    ***  top_substitute.h90   ***
+   !!----------------------------------------------------------------------
+   !! ** purpose : Statement function file: to be include in all routines
+   !!              concerning passive tracer model 
+   !!----------------------------------------------------------------------
+   !! History :   1.0  !  2004-03 (C. Ethe) Original code
+   !!             2.0  !  2007-12 (C. Ethe, G. Madec) new architecture
+   !!----------------------------------------------------------------------
+   !! NEMO/TOP 2.0 , LOCEAN-IPSL (2007) 
+   !! $Id: top_substitute.h90 776 2007-12-19 14:10:14Z gm $ 
+   !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt)
+   !!----------------------------------------------------------------------
+
+    ! Lateral eddy diffusivity coefficient for passive tracer:
+    ! ========================================================
+#if defined key_traldf_c3d || defined key_off_degrad
+!   'key_traldf_c3d' :                 aht: 3D coefficient
+#       define fsahtrt(i,j,k)  trcrat * ahtt(i,j,k)
+#       define fsahtru(i,j,k)  trcrat * ahtu(i,j,k)
+#       define fsahtrv(i,j,k)  trcrat * ahtv(i,j,k)
+#       define fsahtrw(i,j,k)  trcrat * ahtw(i,j,k)
+#elif defined key_traldf_c2d
+!   'key_traldf_c2d' :                 aht: 2D coefficient
+#       define fsahtrt(i,j,k)  trcrat * ahtt(i,j)
+#       define fsahtru(i,j,k)  trcrat * ahtu(i,j)
+#       define fsahtrv(i,j,k)  trcrat * ahtv(i,j)
+#       define fsahtrw(i,j,k)  trcrat * ahtw(i,j)
+#elif defined key_traldf_c1d
+!   'key_traldf_c1d' :                 aht: 1D coefficient
+#       define fsahtrt(i,j,k)  trcrat * ahtt(k)
+#       define fsahtru(i,j,k)  trcrat * ahtu(k)
+#       define fsahtrv(i,j,k)  trcrat * ahtv(k)
+#       define fsahtrw(i,j,k)  trcrat * ahtw(k)
+#else
+!   Default option :             aht: Constant coefficient
+#       define fsahtrt(i,j,k)  ahtrc0
+#       define fsahtru(i,j,k)  ahtrc0
+#       define fsahtrv(i,j,k)  ahtrc0
+#       define fsahtrw(i,j,k)  ahtrc0
+#endif
+
+    ! Eddy induced velocity  coefficient for passive tracer:
+    ! ========================================================
+#if defined key_traldf_c3d || defined key_off_degrad
+!   'key_traldf_c3d' :                 eiv: 3D coefficient
+#       define fsaeitru(i,j,k)  trcrat * aeiu(i,j,k)
+#       define fsaeitrv(i,j,k)  trcrat * aeiv(i,j,k)
+#       define fsaeitrw(i,j,k)  trcrat * aeiw(i,j,k)
+#elif defined key_traldf_c2d
+!   'key_traldf_c2d' :                 eiv: 2D coefficient
+#       define fsaeitru(i,j,k)  trcrat * aeiu(i,j)
+#       define fsaeitrv(i,j,k)  trcrat * aeiv(i,j)
+#       define fsaeitrw(i,j,k)  trcrat * aeiw(i,j)
+#elif defined key_traldf_c1d
+!   'key_traldf_c1d' :                 eiv: 1D coefficient
+#       define fsaeitru(i,j,k)  trcrat * aeiu(k)
+#       define fsaeitrv(i,j,k)  trcrat * aeiv(k)
+#       define fsaeitrw(i,j,k)  trcrat * aeiw(k)
+#else
+!   Default option :             eiv: Constant coefficient
+#       define fsaeitru(i,j,k)  aeiv0
+#       define fsaeitrv(i,j,k)  aeiv0
+#       define fsaeitrw(i,j,k)  aeiv0
+#endif
+    ! mixing for passive tracer:
+    ! ========================================================
+#if defined key_trc_zdfddm
+!   'key_trc_zdfddm' :    avs 
+#       define fstravs(i,j,k)   avs(i,j,k)
+#else
+!   Defautl option :   avs = avt
+#       define fstravs(i,j,k)   avt(i,j,k)
+#endif
+
+! ========================================================
+#include "domzgr_substitute.h90"
+#include "ldfeiv_substitute.h90"
+#include "ldftra_substitute.h90"
+#include "vectopt_loop_substitute.h90"
