Index: branches/2012/dev_LOCEAN_UKMO_2012/NEMOGCM/SETTE/sette.sh
===================================================================
--- branches/2012/dev_LOCEAN_UKMO_2012/NEMOGCM/SETTE/sette.sh	(revision 3650)
+++ branches/2012/dev_LOCEAN_UKMO_2012/NEMOGCM/SETTE/sette.sh	(revision 3653)
@@ -41,9 +41,9 @@
 # BATCH_COMMAND :  name of the command for batch submission
 #
-# MPI_INTERACT :  
-#
-#         for MPP tests, "no" for batch execution, "yes" for interactive execution 
-#
-#         NOTE: for run with 1 process tests are run always in MPI_INTERACT="yes"
+# INTERACT_FLAG :  flag to run in interactive mode "yes"
+#                       to run in batch mode "no"
+#
+# MPIRUN_FLAG   :  flag to run in parallel (MPI) "yes"
+#                       to run in sequential mode (NB_PROC = 1) "no"
 #
 # Principal script is sette.sh, that calls 
@@ -84,9 +84,11 @@
 #
 #
+#  prepare_job.sh
+#
+#  to generate the script run_job.sh
+#
 #  fcm_job.sh 
 #
-#   runs job in interactive or batch mode : all jobs using 1 process are run interactive, and all MPP jobs are
-#
-#   run in batch (MPI_INTERACT="no") or interactive (MPI_INTERACT="yes") see sette.sh and BATCH_TEMPLATE directory
+#   run in batch (INTERACT_FLAG="no") or interactive (INTERACT_FLAG="yes") see sette.sh and BATCH_TEMPLATE directory
 #
 #   (note this job needs to have an input_CONFIG.cfg in which can be found input tar file)
@@ -121,5 +123,5 @@
 # ==========
 #
-# $Id:$
+# $Id$
 #
 #   * creation
@@ -135,4 +137,5 @@
 export MPIRUN_FLAG="yes"
 
+
 # Directory to run the tests
 SETTE_DIR=$(cd $(dirname "$0"); pwd)
@@ -150,10 +153,10 @@
 do
 
-# TESTS FOR GYRE_LOBSTER CONFIGURATION
+# TESTS FOR GYRE CONFIGURATION
 if [ ${config} -eq 1 ] ;  then
-    ## Restartability tests for GYRE_LOBSTER
+    ## Restartability tests for GYRE
     export TEST_NAME="LONG"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRELOB_LONG -r GYRE_LOBSTER add_key "key_mpp_mpi"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRE_LONG -r GYRE -j 8 add_key "key_mpp_mpi" 
     cd ${SETTE_DIR}
     . param.cfg
@@ -164,5 +167,5 @@
     \rm ${JOB_FILE}
     cd ${EXE_DIR}
-    set_namelist namelist cn_exp \"GYRELOB_LONG\"
+    set_namelist namelist cn_exp \"GYRE_LONG\"
     set_namelist namelist nn_it000 1
     set_namelist namelist nn_itend 120
@@ -170,5 +173,4 @@
     set_namelist namelist ln_clobber .true.
     set_namelist namelist nn_solv 2
-    set_namelist namelist_top ln_diatrc .false.
     set_namelist namelist jpni 2
     set_namelist namelist jpnj 2
@@ -181,5 +183,5 @@
     . prepare_exe_dir.sh
     cd ${EXE_DIR}
-    set_namelist namelist cn_exp \"GYRELOB_SHORT\"
+    set_namelist namelist cn_exp \"GYRE_SHORT\"
     set_namelist namelist nn_it000 61
     set_namelist namelist nn_itend 120
@@ -192,14 +194,9 @@
     set_namelist namelist jpnj 2
     set_namelist namelist jpnij 4
-    set_namelist namelist cn_ocerst_in \"GYRELOB_LONG_00000060_restart\"
-    set_namelist namelist_top cn_trcrst_in \"GYRELOB_LONG_00000060_restart_trc\"
-    set_namelist namelist_top ln_diatrc .false.
-    set_namelist namelist_top ln_rsttr .true.
-    set_namelist namelist_top nn_rsttr 2
+    set_namelist namelist cn_ocerst_in \"GYRE_LONG_00000060_restart\"
     for (( i=1; i<=$NPROC; i++)) ; do
         L_NPROC=$(( $i - 1 ))
         L_NPROC=`printf "%04d\n" ${L_NPROC}`
-        ln -sf ../LONG/GYRELOB_LONG_00000060_restart_${L_NPROC}.nc .
-        ln -sf ../LONG/GYRELOB_LONG_00000060_restart_trc_${L_NPROC}.nc .
+        ln -sf ../LONG/GYRE_LONG_00000060_restart_${L_NPROC}.nc .
     done
     cd ${SETTE_DIR}
@@ -210,8 +207,8 @@
 
 if [ ${config} -eq 2 ] ;  then
-    ## Repropducibility tests for GYRE_LOBSTER
+    ## Reproducibility tests for GYRE
     export TEST_NAME="REPRO_1_4"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRELOB_4 -r GYRE_LOBSTER add_key "key_mpp_mpi key_mpp_rep"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRE_4 -r GYRE -j 8 add_key "key_mpp_mpi key_mpp_rep"
     cd ${SETTE_DIR}
     . param.cfg
@@ -222,5 +219,5 @@
     \rm ${JOB_FILE}
     cd ${EXE_DIR}
-    set_namelist namelist cn_exp \"GYRELOB_14\"
+    set_namelist namelist cn_exp \"GYRE_14\"
     set_namelist namelist nn_it000 1
     set_namelist namelist nn_itend 60
@@ -230,6 +227,4 @@
     set_namelist namelist ln_clobber .true.
     set_namelist namelist nn_solv 2
-    set_namelist namelist_top ln_diatrc .false.
-    set_namelist namelist_top ln_trcdta .false.
     set_namelist namelist jpni 1
     set_namelist namelist jpnj 4
@@ -243,6 +238,9 @@
     export TEST_NAME="REPRO_2_2"
     . prepare_exe_dir.sh
-    cd ${EXE_DIR}
-    set_namelist namelist cn_exp \"GYRELOB_22\"
+    JOB_FILE=${EXE_DIR}/run_job.sh
+    NPROC=4
+    \rm $JOB_FILE
+    cd ${EXE_DIR}
+    set_namelist namelist cn_exp \"GYRE_22\"
     set_namelist namelist nn_it000 1
     set_namelist namelist nn_itend 60
@@ -251,6 +249,4 @@
     set_namelist namelist ln_clobber .true.
     set_namelist namelist nn_solv 2
-    set_namelist namelist_top ln_diatrc .false.
-    set_namelist namelist_top ln_trcdta .false.
     set_namelist namelist jpni 2
     set_namelist namelist jpnj 2
@@ -268,5 +264,5 @@
     export TEST_NAME="LONG"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_LONG -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi" 
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_LONG -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi"
     cd ${SETTE_DIR}
     . param.cfg
@@ -290,9 +286,12 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -313,17 +312,22 @@
     set_namelist namelist jpnij 4
     set_namelist namelist nn_solv 2
+    set_namelist namelist_top ln_diatrc .false.
+    set_namelist namelist_top ln_rsttr .true.
+    set_namelist namelist_top nn_rsttr 2
     set_namelist namelist cn_ocerst_in \"O2LP_LONG_00000075_restart\"
     set_namelist namelist_ice cn_icerst_in \"O2LP_LONG_00000075_restart_ice\"
     set_namelist namelist_top cn_trcrst_in \"O2LP_LONG_00000075_restart_trc\"
-    set_namelist namelist_top ln_diatrc .false.
-    set_namelist namelist_top ln_rsttr .true.
-    set_namelist namelist_top nn_rsttr 2
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     for (( i=1; i<=$NPROC; i++)) ; do
         L_NPROC=$(( $i - 1 ))
@@ -340,8 +344,8 @@
 
 if [ ${config} -eq 4 ] ;  then
-    ## Repropducibility tests for ORCA2_LIM_PISCES
+    ## Reproducibility tests for ORCA2_LIM_PISCES
     export TEST_NAME="REPRO_4_4"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_16 -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_rep key_mpp_mpi"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_16 -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep"
     cd ${SETTE_DIR}
     . param.cfg
@@ -365,9 +369,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -378,9 +387,11 @@
     export TEST_NAME="REPRO_2_8"
     . prepare_exe_dir.sh
+    JOB_FILE=${EXE_DIR}/run_job.sh
+    NPROC=16
+    \rm $JOB_FILE
     cd ${EXE_DIR}
     set_namelist namelist nn_it000 1
     set_namelist namelist nn_itend 75
     set_namelist namelist nn_fwb 0
-    set_namelist namelist ln_ctl .false.
     set_namelist namelist ln_clobber .true.
     set_namelist namelist jpni 2
@@ -392,9 +403,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -408,5 +424,5 @@
     export TEST_NAME="LONG"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_LONG -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_LONG -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep" 
     cd ${SETTE_DIR}
     . param.cfg
@@ -429,9 +445,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -440,7 +461,4 @@
     export TEST_NAME="SHORT"
     . prepare_exe_dir.sh
-    JOB_FILE=${EXE_DIR}/run_job.sh
-    NPROC=4
-    \rm $JOB_FILE
     cd ${EXE_DIR}
     set_namelist namelist cn_exp \"OFFP_SHORT\"
@@ -452,5 +470,4 @@
     set_namelist namelist jpnj 2
     set_namelist namelist jpnij 4
-    cp ../LONG/OFFP_LONG_00000020_restart*nc .
     set_namelist namelist_top ln_diatrc .false.
     set_namelist namelist_top ln_rsttr .true.
@@ -464,9 +481,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME}  ${MPIRUN_FLAG} ${JOB_FILE}
@@ -476,8 +498,8 @@
 
 if [ ${config} -eq 6 ] ;  then
-    ## Repropducibility tests for ORCA2_OFF_PISCES
+    ## Reproducibility tests for ORCA2_OFF_PISCES
     export TEST_NAME="REPRO_4_4"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_16 -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_rep key_mpp_mpi"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_16 -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep"
     cd ${SETTE_DIR}
     . param.cfg
@@ -499,9 +521,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false.
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -512,4 +539,7 @@
     export TEST_NAME="REPRO_2_8"
     . prepare_exe_dir.sh
+    JOB_FILE=${EXE_DIR}/run_job.sh
+    NPROC=16
+    \rm $JOB_FILE
     cd ${EXE_DIR}
     set_namelist namelist nn_it000 1
@@ -524,9 +554,14 @@
     # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
     # if not you need input files, and for tests is not necessary
-    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_varpar .false.
+    set_namelist namelist_pisces ln_dust .false.
+    set_namelist namelist_pisces ln_solub .false.
     set_namelist namelist_pisces ln_river .false.
     set_namelist namelist_pisces ln_ndepo .false.
-    set_namelist namelist_pisces ln_dust .false.
-    set_namelist namelist_pisces ln_presatm .false.
+    set_namelist namelist_pisces ln_ironsed .false.
+    set_namelist namelist_pisces ln_hydrofe .false.
+    # put ln_pisdmp to false : no restoring to global mean value
+    set_namelist namelist_pisces ln_pisdmp .false. 
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -535,4 +570,5 @@
 fi
 
+# TESTS FOR AMM12 CONFIGURATION
 if [ ${config} -eq 7 ] ;  then
     ## Restartability tests for AMM12
@@ -565,4 +601,7 @@
     export TEST_NAME="SHORT"
     . prepare_exe_dir.sh
+    JOB_FILE=${EXE_DIR}/run_job.sh
+    NPROC=32
+    \rm $JOB_FILE
     cd ${EXE_DIR}
     set_namelist namelist nn_it000 7
@@ -594,5 +633,5 @@
     export TEST_NAME="REPO_8_4"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_32 -r AMM12 add_key "key_mpp_rep"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_32 -r AMM12 add_key "key_mpp_mpi key_mpp_rep"
     cd ${SETTE_DIR}
     . param.cfg
@@ -604,5 +643,6 @@
     cd ${EXE_DIR}
     set_namelist namelist nn_it000 1
-    set_namelist namelist nn_itend 576
+    set_namelist namelist nn_itend 12
+    set_namelist namelist nn_stock 6
     set_namelist namelist nn_fwb 0
     set_namelist namelist ln_ctl .false.
@@ -626,4 +666,5 @@
     set_namelist namelist nn_fwb 0
     set_namelist namelist ln_ctl .false.
+    set_namelist namelist ln_clobber .true.
     set_namelist namelist nn_dyn2d 2
     set_namelist namelist nn_tra_dta 0
@@ -632,4 +673,7 @@
     set_namelist namelist jpnj 8
     set_namelist namelist jpnij 32
+    set_namelist namelist ln_rstart .true.
+    set_namelist namelist nn_rstctl 2
+    set_namelist namelist cn_ocerst_in \"../LONG/AMM12_00000006_restart\"
     cd ${SETTE_DIR}
     . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
@@ -643,5 +687,5 @@
     export TEST_NAME="SHORT"
     cd ${SETTE_DIR}
-    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2AGUL_1_2 -r ORCA2_LIM -j 8 add_key "key_mpp_rep key_mpp_mpi key_agrif" del_key "key_zdftmx"
+    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2AGUL_1_2 -r ORCA2_LIM -j 8 add_key "key_mpp_mpi key_mpp_rep key_agrif" del_key "key_zdftmx"
     cd ${SETTE_DIR}
     . param.cfg
