Changeset 4936


Ignore:
Timestamp:
02/13/20 15:45:24 (3 years ago)
Author:
jgipsl
Message:

Updated LMDZOR_v6.3 configuration files to follow LMDZOR_v6.2 structure: compilation script instead of makefiles... These chages should be used together with new LMDZ/trunk, IOIPSL/trunk and XIOS/trunk. Only difference between v6.2 and v6.3 is the version of ORCHIDEE: ORCHIDEE_2_2 in v6.2 and ORCHIDEE_3 in v6.3.

Location:
CONFIG/UNIFORM/v6/LMDZOR_v6.3
Files:
5 deleted
18 edited
2 copied

Legend:

Unmodified
Added
Removed
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZ/CREATE_amip/config.card

    r4353 r4936  
    2929#============================ 
    3030PeriodNb=50 
     31#============================ 
     32#-- Source following file with module settings, only if it exists 
     33EnvFile=${SUBMIT_DIR}/../ARCH/arch.env 
     34#============================ 
     35#-- ResolAtm indicates the atmospheric resolution 
     36#   This variable is used in the executable name  
     37ResolAtm=144x142x79 
     38#============================ 
     39# OptMode indicates the optimization mode choosen during compilation 
     40# This variable is used in the executable name 
     41OptMode=prod 
    3142 
    3243#======================================================================== 
     
    4051[Executable] 
    4152#D- For each component: Real name of executable, Name of executable in the run directory  
    42 ATM= (create_etat0_limit.e, create_etat0_limit.e, 1MPI) 
     53ATM= (ce0l_${ResolAtm}_${OptMode}.e, ce0l.e, 1MPI) 
    4354 
    4455#======================================================================== 
     
    5869#D-- ATM - 
    5970[ATM] 
    60 # 
    61 WriteFrequency="1Y" 
    6271# If config_Restarts_OverRule == 'n' all params are read 
    6372Restart= n 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZ/CREATE_clim_360d/config.card

    r4353 r4936  
    2929#-- Compression level for netcdf output files 
    3030CompressionLevel=2 
     31#============================ 
     32#-- Source following file with module settings, only if it exists 
     33EnvFile=${SUBMIT_DIR}/../ARCH/arch.env 
     34#============================ 
     35#-- ResolAtm indicates the atmospheric resolution 
     36#   This variable is used in the executable name  
     37ResolAtm=144x142x79 
     38#============================ 
     39# OptMode indicates the optimization mode choosen during compilation 
     40# This variable is used in the executable name 
     41OptMode=prod 
     42 
    3143#======================================================================== 
    3244#D-- ListOfComponents - 
     
    3951[Executable] 
    4052#D- For each component: Real name of executable, Name of executable in the run directory  
    41 ATM= (create_etat0_limit.e, create_etat0_limit.e, 1MPI) 
     53ATM= (ce0l_${ResolAtm}_${OptMode}.e, ce0l.e, 1MPI) 
    4254 
    4355#======================================================================== 
     
    5769#D-- ATM - 
    5870[ATM] 
    59 # 
    60 WriteFrequency="1Y" 
    6171# If config_Restarts_OverRule == 'n' all params are read 
    6272Restart= n 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZ/clim_360d/COMP/lmdz.card

    r4724 r4936  
    3737ByPass_hgardfou_mats=n 
    3838 
    39 # Set OutLevel to choose the level of output for LMDZ 
    40 # OutLevel=low/medium/high 
    41 OutLevel=low 
    42  
    43 # Set COSP activation and output frequency (monthly, daily, HF) = y/n 
    44 LMDZ_COSP_OK=y 
    45 LMDZ_COSP_monthly=n 
    46 LMDZ_COSP_daily=n 
    47 LMDZ_COSP_hf=n 
    48  
    49 # Set NMC output frequency (monthly, daily, HF) = y/n 
    50 LMDZ_NMC_monthly=n 
    51 LMDZ_NMC_daily=n 
    52 LMDZ_NMC_hf=n 
    53  
    5439# Nugding : ok_guide=y/n 
    5540# If ok_guide=y, add nudging files(u.nc, v.nc, hur.nc,...) in BoundaryFiles section below. 
    5641ok_guide=n 
    5742 
     43# Specify which output file to activate and at which output_level 
     44# Use an integer to specify the output level or NONE if to deactivate the file 
     45# output_level_filename=1     : activate the corresponding file with low output level 
     46# output_level_filename=10    : activate the corresponding file with high output level 
     47# output_level_filename=NONE  : the file will not be written 
     48output_level_histmth = 5 
     49output_level_histday = NONE 
     50output_level_histhf  = NONE 
     51output_level_histmthNMC = NONE 
     52output_level_histdayNMC = NONE 
     53output_level_histhfNMC  = NONE 
     54output_level_histstrataer = NONE 
     55output_level_histdaystrataer = NONE 
     56output_level_histstn      = NONE 
     57 
     58# Activate COSP in config.def and set corresponding output files 
     59LMDZ_COSP_OK=y 
     60output_level_histmthCOSP = NONE 
     61output_level_histdayCOSP = NONE 
     62output_level_histhfCOSP  = NONE 
     63 
    5864[InitialStateFiles] 
    5965List=   (${R_IN}/ATM/START/eORCA1.2xLMD${RESOL_ATM_XY}/start_eORCA1.2xLMD${RESOL_ATM_3D}_o2a_v3.nc, start.nc),\ 
     
    6268[BoundaryFiles] 
    6369List=() 
    64 ListNonDel= (${R_IN}/ATM/LIMIT/AMIP.v20180427/interpol/${RESOL_ATM_XY}_eORCA1.2_360d/limit_1979_2008_clim.nc, limit.nc),\ 
    65             (${R_IN}/ATM/AEROSOLS/CMIP6/v1/${RESOL_ATM_XY}/L${RESOL_ATM_Z}/aerosols1850_from_inca.nc,   aerosols.nat.nc),\ 
     70# 
     71# With CMIP6 aerosols version 1 
     72# With 3D ozone 
     73ListNonDel= (${R_IN}/ATM/AEROSOLS/CMIP6/v1/${RESOL_ATM_XY}/L${RESOL_ATM_Z}/aerosols1850_from_inca.nc,   aerosols.nat.nc),\ 
    6674            (${R_IN}/ATM/AEROSOLS/CMIP6/v1/${RESOL_ATM_XY}/L${RESOL_ATM_Z}/aerosols1995_from_inca.nc,   aerosols1980.nc),\ 
    6775            (${R_IN}/ATM/OZONE/UReading/historical.v20160711.v2/interpol/${RESOL_ATM_XY}/climoz_LMDZ_1979_2008_clim.nc, climoz_LMDZ.nc),\ 
     76            (${R_IN}/ATM/LIMIT/AMIP.v20180427/interpol/${RESOL_ATM_XY}_eORCA1.2_360d/limit_1979_2008_clim.nc, limit.nc),\ 
    6877            (${R_IN}/ATM/SOLAR/CMIP6/v3.1corr/Control/solarforcing_v3.1_pdControl_ave_6bands_360days.nc, solarforcing.nc),\ 
    6978            (${R_IN}/ATM/STRATAERO/CMIP6/v3/${RESOL_ATM_XY}/L${RESOL_ATM_Z}/taulwstrat.2D.ave.nc, taulwstrat.2D.nc),\ 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZ/clim_360d/COMP/xios.card

    r2396 r4936  
    2121 
    2222[OutputText] 
    23 List=   (xios_client_*) 
     23List=   (xios_client_*,out_xios.x.err.*, out_xios.x.out.*) 
    2424 
    2525[OutputFiles] 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZ/clim_360d/config.card

    r4353 r4936  
    2929#-- Compression level for netcdf output files 
    3030CompressionLevel=2 
     31#============================ 
     32#-- Source following file with module settings, only if it exists 
     33EnvFile=${SUBMIT_DIR}/../ARCH/arch.env 
     34#============================ 
     35#-- ResolAtm indicates the atmospheric resolution 
     36#   This variable is used in the executable name  
     37ResolAtm=144x142x79 
     38#============================ 
     39# OptMode indicates the optimization mode choosen during compilation 
     40# This variable is used in the executable name 
     41OptMode=prod 
     42 
    3143#======================================================================== 
    3244#D-- ListOfComponents - 
     
    3547ATM= (lmdz, LMDZ) 
    3648IOS= (xios, XIOS) 
     49#======================================================================== 
    3750 
    38 #======================================================================== 
    3951#D-- Executable - 
    4052[Executable] 
    41 #D- For each component: Real name of executable, Name of executable in the run directory  
    42 #D- Here is set 47MPI*8OMP which is suitable for resolution 144x142x79 
     53#D- For each component: First argument is the executable name as in bin folder. 
     54#D  ResolAtm and OptMode are set in UserChoices section. 
     55#D- Here is set 71MPI*8OMP which is suitable for resolution 144x142x79 
    4356#D- Change to 31MPI*4OMP for resolution 96x95x39 
    44 ATM= (gcm.e, lmdz.x, 71MPI, 8OMP) 
    45 IOS= (xios_server.exe, xios.x, 1MPI) 
     57ATM= (gcm_${ResolAtm}_${OptMode}.e, lmdz.x, 71MPI, 8OMP) 
     58IOS= (xios_server_${OptMode}.exe, xios.x, 1MPI) 
    4659 
    4760#======================================================================== 
     
    6376#D-- ATM - 
    6477[ATM] 
    65 WriteFrequency="1M" 
    6678# If config_Restarts_OverRule == 'n' next 4 params are read 
    6779Restart= n 
     
    7688#D-- IOS - 
    7789[IOS] 
    78 WriteFrequency="" 
    7990# If config_Restarts_OverRule == 'n' next 4 params are read 
    8091Restart= n 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZOR/amip/COMP/lmdz.card

    r4724 r4936  
    3737ByPass_hgardfou_mats=n 
    3838 
    39 # Set OutLevel to choose the level of output for LMDZ 
    40 # OutLevel=low/medium/high 
    41 OutLevel=low 
    42  
    43 # Set COSP activation and output frequency (monthly, daily, HF) = y/n 
    44 LMDZ_COSP_OK=y 
    45 LMDZ_COSP_monthly=n 
    46 LMDZ_COSP_daily=n 
    47 LMDZ_COSP_hf=n 
    48  
    49 # Set NMC output frequency (monthly, daily, HF) = y/n 
    50 LMDZ_NMC_monthly=n 
    51 LMDZ_NMC_daily=n 
    52 LMDZ_NMC_hf=n 
    53  
    5439# Nugding : ok_guide=y/n 
    5540# If ok_guide=y, add nudging files(u.nc, v.nc, hur.nc,...) in BoundaryFiles section below. 
    5641ok_guide=n 
     42 
     43# Specify which output file to activate and at which output_level 
     44# Use an integer to specify the output level or NONE if to deactivate the file 
     45# output_level_filename=1     : activate the corresponding file with low output level 
     46# output_level_filename=10    : activate the corresponding file with high output level 
     47# output_level_filename=NONE  : the file will not be written 
     48output_level_histmth = 5 
     49output_level_histday = NONE 
     50output_level_histhf  = NONE 
     51output_level_histmthNMC = NONE 
     52output_level_histdayNMC = NONE 
     53output_level_histhfNMC  = NONE 
     54output_level_histstrataer = NONE 
     55output_level_histdaystrataer = NONE 
     56output_level_histstn      = NONE 
     57 
     58# Activate COSP in config.def and set corresponding output files 
     59LMDZ_COSP_OK=y 
     60output_level_histmthCOSP = NONE 
     61output_level_histdayCOSP = NONE 
     62output_level_histhfCOSP  = NONE 
    5763 
    5864[InitialStateFiles] 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZOR/amip/COMP/orchidee.card

    r4299 r4936  
    5353 
    5454[OutputText] 
    55 List=   (out_orchidee, orchidee.def, used_orchidee.def, iodef.xml, context_orchidee.xml, context_input_orchidee.xml, field_def_orchidee.xml, file_def_orchidee.xml, river_desc.nc) 
     55List=   (out_orchidee*, orchidee.def, used_orchidee.def, iodef.xml, context_orchidee.xml, context_input_orchidee.xml, field_def_orchidee.xml, file_def_orchidee.xml, river_desc.nc) 
    5656 
    5757[OutputFiles] 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZOR/amip/config.card

    r4353 r4936  
    2929#-- Compression level for netcdf output files 
    3030CompressionLevel=2 
     31#============================ 
     32#-- Source following file with module settings, only if it exists 
     33EnvFile=${SUBMIT_DIR}/../ARCH/arch.env 
     34#============================ 
     35#-- ResolAtm indicates the atmospheric resolution 
     36#   This variable is used in the executable name  
     37ResolAtm=144x142x79 
     38#============================ 
     39# OptMode indicates the optimization mode choosen during compilation 
     40# This variable is used in the executable name 
     41OptMode=prod 
     42 
    3143#======================================================================== 
    3244#D-- ListOfComponents - 
     
    4153#D-- Executable - 
    4254[Executable] 
    43 #D- For each component: Real name of executable, Name of executable in the run directory  
    44 #D- Here is set 47MPI*8OMP which is suitable for resolution 144x142x79 
     55#D- For each component: First argument is the executable name as in bin folder. 
     56#D  ResolAtm and OptMode are set in UserChoices section. 
     57#D- Here is set 71MPI*8OMP which is suitable for resolution 144x142x79 
    4558#D- Change to 31MPI*4OMP for resolution 96x95x39 
    46 ATM= (gcm.e, lmdz.x, 71MPI, 8OMP) 
     59ATM= (gcm_${ResolAtm}_${OptMode}.e, lmdz.x, 71MPI, 8OMP) 
    4760SRF= ("", "") 
    4861SBG= ("", "") 
    49 IOS= (xios_server.exe, xios.x, 1MPI) 
     62IOS= (xios_server_${OptMode}.exe, xios.x, 1MPI) 
    5063 
    5164#======================================================================== 
     
    6780#D-- ATM - 
    6881[ATM] 
    69 WriteFrequency="1M" 
    7082# If config_Restarts_OverRule == 'n' next 4 params are read 
    7183Restart= n 
     
    8092#D-- SRF - 
    8193[SRF] 
    82 # WriteFrequency is not used any more for ORCHIDEE  
    83 # Output files are now managed in orchidee.card  
    84 WriteFrequency="" 
    8594# If config_Restarts_OverRule == 'n' next 4 params are read 
    8695Restart= n 
     
    95104#D-- SBG - STOMATE 
    96105[SBG] 
    97 # WriteFrequency is not used any more for ORCHIDEE  
    98 # Output files are now managed in stomate.card  
    99 WriteFrequency="" 
    100106# If config_Restarts_OverRule == 'n' next 4 params are read 
    101107Restart= n 
     
    110116#D-- IOS - 
    111117[IOS] 
    112 WriteFrequency="" 
    113118# If config_Restarts_OverRule == 'n' next 4 params are read 
    114119Restart= n 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZOR/clim_pdControl/COMP/lmdz.card

    r4724 r4936  
    3737ByPass_hgardfou_mats=n 
    3838 
    39 # Set OutLevel to choose the level of output for LMDZ 
    40 # OutLevel=low/medium/high 
    41 OutLevel=low 
    42  
    43 # Set COSP activation and output frequency (monthly, daily, HF) = y/n 
    44 LMDZ_COSP_OK=y 
    45 LMDZ_COSP_monthly=n 
    46 LMDZ_COSP_daily=n 
    47 LMDZ_COSP_hf=n 
    48  
    49 # Set NMC output frequency (monthly, daily, HF) = y/n 
    50 LMDZ_NMC_monthly=n 
    51 LMDZ_NMC_daily=n 
    52 LMDZ_NMC_hf=n 
    53  
    5439# Nugding : ok_guide=y/n 
    5540# If ok_guide=y, add nudging files(u.nc, v.nc, hur.nc,...) in BoundaryFiles section below. 
    5641ok_guide=n 
     42 
     43# Specify which output file to activate and at which output_level 
     44# Use an integer to specify the output level or NONE if to deactivate the file 
     45# output_level_filename=1     : activate the corresponding file with low output level 
     46# output_level_filename=10    : activate the corresponding file with high output level 
     47# output_level_filename=NONE  : the file will not be written 
     48output_level_histmth = 5 
     49output_level_histday = NONE 
     50output_level_histhf  = NONE 
     51output_level_histmthNMC = NONE 
     52output_level_histdayNMC = NONE 
     53output_level_histhfNMC  = NONE 
     54output_level_histstrataer = NONE 
     55output_level_histdaystrataer = NONE 
     56output_level_histstn      = NONE 
     57 
     58# Activate COSP in config.def and set corresponding output files 
     59LMDZ_COSP_OK=y 
     60output_level_histmthCOSP = NONE 
     61output_level_histdayCOSP = NONE 
     62output_level_histhfCOSP  = NONE 
    5763 
    5864[InitialStateFiles] 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/EXPERIMENTS/LMDZOR/clim_pdControl/config.card

    r4353 r4936  
    2929#-- Compression level for netcdf output files 
    3030CompressionLevel=2 
    31  
     31#============================ 
     32#-- Source following file with module settings, only if it exists 
     33EnvFile=${SUBMIT_DIR}/../ARCH/arch.env 
     34#============================ 
     35#-- ResolAtm indicates the atmospheric resolution 
     36#   This variable is used in the executable name  
     37ResolAtm=144x142x79 
     38#============================ 
     39# OptMode indicates the optimization mode choosen during compilation 
     40# This variable is used in the executable name 
     41OptMode=prod 
    3242 
    3343#======================================================================== 
     
    4353#D-- Executable - 
    4454[Executable] 
    45 #D- For each component: Real name of executable, Name of executable in the run directory  
    46 #D- Here is set 47MPI*8OMP which is suitable for resolution 144x142x79 
     55#D- For each component: First argument is the executable name as in bin folder. 
     56#D  ResolAtm and OptMode are set in UserChoices section. 
     57#D- Here is set 71MPI*8OMP which is suitable for resolution 144x142x79 
    4758#D- Change to 31MPI*4OMP for resolution 96x95x39 
    48 ATM= (gcm.e, lmdz.x, 71MPI, 8OMP) 
     59ATM= (gcm_${ResolAtm}_${OptMode}.e, lmdz.x, 71MPI, 8OMP) 
    4960SRF= ("", "") 
    5061SBG= ("", "") 
    51 IOS= (xios_server.exe, xios.x, 1MPI) 
     62IOS= (xios_server_${OptMode}.exe, xios.x, 1MPI) 
    5263 
    5364#======================================================================== 
     
    6980#D-- ATM - 
    7081[ATM] 
    71 WriteFrequency="1M" 
    7282# If config_Restarts_OverRule == 'n' next 4 params are read 
    7383Restart= n 
     
    8292#D-- SRF - 
    8393[SRF] 
    84 # WriteFrequency is not used any more for ORCHIDEE  
    85 # Output files are now managed in orchidee.card  
    86 WriteFrequency="" 
    8794# If config_Restarts_OverRule == 'n' next 4 params are read 
    8895Restart= n 
     
    97104#D-- SBG - STOMATE 
    98105[SBG] 
    99 # WriteFrequency is not used any more for ORCHIDEE  
    100 # Output files are now managed in stomate.card  
    101 WriteFrequency="" 
    102106# If config_Restarts_OverRule == 'n' next 4 params are read 
    103107Restart= n 
     
    112116#D-- IOS - 
    113117[IOS] 
    114 WriteFrequency="" 
    115118# If config_Restarts_OverRule == 'n' next 4 params are read 
    116119Restart= n 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/DRIVER/lmdz.driver

    r4724 r4936  
    55    IGCM_debug_PushStack "ATM_Initialize" 
    66 
    7     RESOL_ATM=$( echo $RESOL | awk "-Fx" '{print $2}' | awk "-F-" '{print $1}') 
    8  
    9     [ -f ${SUBMIT_DIR}/../.resol ] && eval $(grep RESOL_ATM_3D ${SUBMIT_DIR}/../.resol) || RESOL_ATM_3D=96x95x39 
     7    # Read the resolution from the variables ResolAtm set in config.card UserChoices section or from .resol file 
     8    if [ X$ResolAtm != X ] ; then 
     9        # ResolAtm is set in config.card 
     10        RESOL_ATM_3D=${ResolAtm} 
     11    elif [ -f ${SUBMIT_DIR}/../.resol ] ; then 
     12        # ResolAtm was not set in config.card, try to read .resol file 
     13        eval $(grep RESOL_ATM_3D ${SUBMIT_DIR}/../.resol) || RESOL_ATM_3D=96x95x39 
     14    else 
     15        IGCM_debug_Exit "ResolAtm is not set in config.card and the .resol file does not exist." 
     16        IGCM_debug_Verif_Exit 
     17    fi 
     18     
     19    IGCM_debug_Print 1 "The atomsopheric resolution is ${RESOL_ATM_3D} "  
    1020 
    1121    RESOL_ATM_Z=$( echo ${RESOL_ATM_3D} | awk "-Fx" '{print $3}' ) 
     
    1323    RESOL_ATM_Y=$( echo ${RESOL_ATM_3D} | awk "-Fx" '{print $2}' ) 
    1424    RESOL_ATM_XY="${RESOL_ATM_X}x${RESOL_ATM_Y}" 
     25    RESOL_ATM=LMD${RESOL_ATM_X}${RESOL_ATM_Y} 
    1526 
    1627    ##- LMDZ physics version 
     
    3748    ConfType=${lmdz_UserChoices_ConfType} 
    3849 
    39     ##- LMDZ output level, to be set in lmdz.card 
    40     if [ X${lmdz_UserChoices_OutLevel} = X ] ; then 
    41         # OutLevel is not set. Take default value low. 
    42         OutLevel=low 
    43     else 
    44         OutLevel=${lmdz_UserChoices_OutLevel} 
    45     fi 
    46  
    47     ##-- Output frequency purpose .... 
    48     ##--  Initialisation  .... 
    49     ok_mensuel=.FALSE. 
    50     ok_journe=.FALSE. 
    51     ok_hf=.FALSE. 
    52     ok_hf3h=.FALSE. 
    53     ok_hf3hm=.FALSE. 
    54     ok_stn=.FALSE. 
    55  
    56  
    57     case ${config_UserChoices_PeriodLength} in 
    58         1Y|1y|1M|1m) ok_mensuel=.TRUE. ;; 
    59         5D|5d|1D|1d) ok_journe=.TRUE. ;; 
    60     esac 
    61  
    62     for frequency in ${config_ATM_WriteFrequency} ; do 
    63         case ${frequency} in 
    64             1M|1m) ok_mensuel=.TRUE. ;; 
    65         esac 
    66         case ${frequency} in 
    67             5D|5d|1D|1d) ok_journe=.TRUE. ;; 
    68         esac 
    69         case ${frequency} in 
    70             HF|hf) ok_hf=.TRUE. ;; 
    71         esac 
    72         case ${frequency} in  
    73             HF3h|hf3h) ok_hf3h=.TRUE. ;; 
    74         esac 
    75         case ${frequency} in  
    76             HF3hm|hf3hm) ok_hf3hm=.TRUE. ;; 
    77         esac 
    78         case ${frequency} in 
    79             STN|stn) ok_stn=.TRUE. ;; 
    80         esac 
    81     done 
    82  
    83  
    84 ##  Read LMDZ_COSP_OK in lmdz.card 
    85     if [ X${lmdz_UserChoices_LMDZ_COSP_OK} = Xy ] ; then 
    86         ##  LMDZ_COSP_OK=y, now read all other COSP variables 
    87         ##  Read LMDZ_COSP_monthly in lmdz.card 
    88         if [ X${lmdz_UserChoices_LMDZ_COSP_monthly} = Xy ] ; then 
    89             LMDZ_COSP_monthly=.TRUE. 
    90         else 
    91             LMDZ_COSP_monthly=.FALSE. 
    92         fi 
    93         ##  Read LMDZ_COSP_daily in lmdz.card 
    94         if [ X${lmdz_UserChoices_LMDZ_COSP_daily} = Xy ] ; then 
    95             LMDZ_COSP_daily=.TRUE. 
    96         else 
    97             LMDZ_COSP_daily=.FALSE. 
    98         fi 
    99         ##  Read LMDZ_COSP_hf in lmdz.card 
    100         if [ X${lmdz_UserChoices_LMDZ_COSP_hf} = Xy ] ; then 
    101             LMDZ_COSP_hf=.TRUE. 
    102         else 
    103             LMDZ_COSP_hf=.FALSE. 
    104         fi 
    105     else 
    106         # LMDZ_COSP_OK=n : All cosp output are deactivated 
    107         LMDZ_COSP_monthly=.FALSE. 
    108         LMDZ_COSP_daily=.FALSE. 
    109         LMDZ_COSP_hf=.FALSE. 
    110     fi   
    111  
    112     ##  Read LMDZ_NMC_monthly in lmdz.card 
    113     if [ X${lmdz_UserChoices_LMDZ_NMC_monthly} = Xy ] ; then 
    114         LMDZ_NMC_monthly=.TRUE. 
    115     else 
    116         LMDZ_NMC_monthly=.FALSE. 
    117     fi 
    118      
    119     ## Read LMDZ_NMC_daily in lmdz.card 
    120     if [ X${lmdz_UserChoices_LMDZ_NMC_daily} = Xy ] ; then 
    121         LMDZ_NMC_daily=.TRUE. 
    122     else 
    123         LMDZ_NMC_daily=.FALSE. 
    124     fi 
    125      
    126     ## Read LMDZ_NMC_hf in lmdz.card 
    127     if [ X${lmdz_UserChoices_LMDZ_NMC_hf} = Xy ] ; then 
    128         LMDZ_NMC_hf=.TRUE. 
    129     else 
    130         LMDZ_NMC_hf=.FALSE. 
    131     fi 
    132      
    133  
    13450    IGCM_debug_PopStack "ATM_Initialize" 
    13551} 
     
    276192    IGCM_comp_modifyDefFile nonblocker config.def t_coupl   ${LMDZ_t_coupl}  
    277193 
    278     ##-- Add special treatement for CARBON CYCLE 
    279     if [ X"${lmdz_UserChoices_CARBON_CYCLE}" = X"control" ] || [ X"${lmdz_UserChoices_CARBON_CYCLE}" = X"historical" ] ; then 
    280         ATM_Carbon_Update 
    281     fi 
    282  
    283  
    284     ##-- Set LMDZ_COSP_daily1979=y in section UserChoices in lmdz.card to activate  
    285     ##   COSP daily output for years 1979 and later (mandatory for historical CMIP5 run). 
    286     if ([ X"${lmdz_UserChoices_LMDZ_COSP_daily1979}" = X"y" ] &&  [ ${year} -ge 1979 ]) ; then 
    287         LMDZ_COSP_daily=.TRUE. 
    288     fi 
    289  
    290     ## Modifiy  
    291     IGCM_comp_modifyXmlFile nonblocker file_def_histmth_lmdz.xml histmth enabled ${ok_mensuel} 
    292      
    293     IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday enabled ${ok_journe} 
    294      
    295     if [ X${OutLevel} = Xlow ] || [ X${OutLevel} = Xmedium ] ; then 
    296         IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday output_level 2 
    297     else 
    298         IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday output_level 5 
    299     fi 
    300      
    301     IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf enabled ${ok_hf} 
    302      
    303     if [ X${OutLevel} = Xlow ] ; then 
    304         IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf output_level 5 
    305     elif [ X${OutLevel} = Xmedium ] ; then 
    306         IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf output_level 6 
    307     elif [ X${OutLevel} = Xhigh ] ; then 
    308         IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf output_level 7 
    309     fi 
    310          
    311     IGCM_comp_modifyXmlFile nonblocker file_def_histhf3h_lmdz.xml histhf3h enabled ${ok_hf3h} 
    312     IGCM_comp_modifyXmlFile nonblocker file_def_histhf3hm_lmdz.xml histhf3hm enabled ${ok_hf3hm} 
    313  
    314     IGCM_comp_modifyXmlFile nonblocker file_def_histstn_lmdz.xml histstn enabled ${ok_stn} 
    315  
    316     IGCM_comp_modifyXmlFile nonblocker file_def_histmthNMC_lmdz.xml histmthNMC enabled ${LMDZ_NMC_monthly} 
    317     IGCM_comp_modifyXmlFile nonblocker file_def_histdayNMC_lmdz.xml histdayNMC enabled ${LMDZ_NMC_daily} 
    318     IGCM_comp_modifyXmlFile nonblocker file_def_histhfNMC_lmdz.xml histhfNMC enabled ${LMDZ_NMC_hf} 
    319      
    320     IGCM_comp_modifyXmlFile nonblocker file_def_histmthCOSP_lmdz.xml histmthCOSP enabled ${LMDZ_COSP_monthly} 
    321     IGCM_comp_modifyXmlFile nonblocker file_def_histdayCOSP_lmdz.xml histdayCOSP enabled ${LMDZ_COSP_daily} 
    322     IGCM_comp_modifyXmlFile nonblocker file_def_histhfCOSP_lmdz.xml histhfCOSP enabled ${LMDZ_COSP_hf} 
    323  
    324     # Activate the histstrataer output files only for configuration with interactive stratospheric aerosols  
    325     # done by setting the key word LMDZ_strataero=y in lmdz.card 
    326     if [ X${lmdz_UserChoices_LMDZ_strataero} = Xy ] ; then 
    327         IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer enabled .TRUE. 
    328     IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer enabled .TRUE. 
    329     else 
    330         IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer enabled .FALSE. 
    331     IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer enabled .FALSE. 
     194 
     195 
     196    ## Activate diagnostic output files and set output_level for each file 
     197 
     198    # histmth 
     199    if [ X${lmdz_UserChoices_output_level_histmth} = X ] || [ X${lmdz_UserChoices_output_level_histmth} = XNONE ] ; then 
     200        IGCM_comp_modifyXmlFile nonblocker file_def_histmth_lmdz.xml histmth enabled FALSE 
     201        IGCM_comp_modifyXmlFile nonblocker file_def_histmth_lmdz.xml histmth output_level 0 
     202    else 
     203        IGCM_comp_modifyXmlFile nonblocker file_def_histmth_lmdz.xml histmth enabled TRUE 
     204        IGCM_comp_modifyXmlFile nonblocker file_def_histmth_lmdz.xml histmth output_level ${lmdz_UserChoices_output_level_histmth}  
     205    fi 
     206 
     207    # histday 
     208    if [ X${lmdz_UserChoices_output_level_histday} = X ] || [ X${lmdz_UserChoices_output_level_histday} = XNONE ] ; then 
     209        IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday enabled FALSE 
     210        IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday output_level 0 
     211    else 
     212        IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday enabled TRUE 
     213        IGCM_comp_modifyXmlFile nonblocker file_def_histday_lmdz.xml histday output_level ${lmdz_UserChoices_output_level_histday}  
     214    fi 
     215 
     216    # histhf 
     217    if [ X${lmdz_UserChoices_output_level_histhf} = X ] || [ X${lmdz_UserChoices_output_level_histhf} = XNONE ] ; then 
     218        IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf enabled FALSE 
     219        IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf output_level 0 
     220    else 
     221        IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf enabled TRUE 
     222        IGCM_comp_modifyXmlFile nonblocker file_def_histhf_lmdz.xml histhf output_level ${lmdz_UserChoices_output_level_histhf}  
     223    fi 
     224 
     225    # histmthNMC 
     226    if [ X${lmdz_UserChoices_output_level_histmthNMC} = X ] || [ X${lmdz_UserChoices_output_level_histmthNMC} = XNONE ] ; then 
     227        IGCM_comp_modifyXmlFile nonblocker file_def_histmthNMC_lmdz.xml histmthNMC enabled FALSE 
     228        IGCM_comp_modifyXmlFile nonblocker file_def_histmthNMC_lmdz.xml histmthNMC output_level 0 
     229    else 
     230        IGCM_comp_modifyXmlFile nonblocker file_def_histmthNMC_lmdz.xml histmthNMC enabled TRUE 
     231        IGCM_comp_modifyXmlFile nonblocker file_def_histmthNMC_lmdz.xml histmthNMC output_level ${lmdz_UserChoices_output_level_histmthNMC}  
     232    fi 
     233 
     234    # histdayNMC 
     235    if [ X${lmdz_UserChoices_output_level_histdayNMC} = X ] || [ X${lmdz_UserChoices_output_level_histdayNMC} = XNONE ] ; then 
     236        IGCM_comp_modifyXmlFile nonblocker file_def_histdayNMC_lmdz.xml histdayNMC enabled FALSE 
     237        IGCM_comp_modifyXmlFile nonblocker file_def_histdayNMC_lmdz.xml histdayNMC output_level 0 
     238    else 
     239        IGCM_comp_modifyXmlFile nonblocker file_def_histdayNMC_lmdz.xml histdayNMC enabled TRUE 
     240        IGCM_comp_modifyXmlFile nonblocker file_def_histdayNMC_lmdz.xml histdayNMC output_level ${lmdz_UserChoices_output_level_histdayNMC}  
     241    fi 
     242 
     243    # histhfNMC 
     244    if [ X${lmdz_UserChoices_output_level_histhfNMC} = X ] || [ X${lmdz_UserChoices_output_level_histhfNMC} = XNONE ] ; then 
     245        IGCM_comp_modifyXmlFile nonblocker file_def_histhfNMC_lmdz.xml histhfNMC enabled FALSE 
     246        IGCM_comp_modifyXmlFile nonblocker file_def_histhfNMC_lmdz.xml histhfNMC output_level 0 
     247    else 
     248        IGCM_comp_modifyXmlFile nonblocker file_def_histhfNMC_lmdz.xml histhfNMC enabled TRUE 
     249        IGCM_comp_modifyXmlFile nonblocker file_def_histhfNMC_lmdz.xml histhfNMC output_level ${lmdz_UserChoices_output_level_histhfNMC}  
     250    fi 
     251 
     252    # histstrataer 
     253    if [ X${lmdz_UserChoices_output_level_histstrataer} = X ] || [ X${lmdz_UserChoices_output_level_histstrataer} = XNONE ] ; then 
     254        IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer enabled FALSE 
     255        IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer output_level 0 
     256    else 
     257        IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer enabled TRUE 
     258        IGCM_comp_modifyXmlFile nonblocker file_def_histstrataer_lmdz.xml histstrataer output_level ${lmdz_UserChoices_output_level_histstrataer}  
     259    fi 
     260 
     261    # histdaystrataer 
     262    if [ X${lmdz_UserChoices_output_level_histdaystrataer} = X ] || [ X${lmdz_UserChoices_output_level_histdaystrataer} = XNONE ] ; then 
     263        IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer enabled FALSE 
     264        IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer output_level 0 
     265    else 
     266        IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer enabled TRUE 
     267        IGCM_comp_modifyXmlFile nonblocker file_def_histdaystrataer_lmdz.xml histdaystrataer output_level ${lmdz_UserChoices_output_level_histstrataer} 
     268    fi 
     269 
     270    # histstn 
     271    if [ X${lmdz_UserChoices_output_level_histstn} = X ] || [ X${lmdz_UserChoices_output_level_histstn} = XNONE ] ; then 
     272        IGCM_comp_modifyXmlFile nonblocker file_def_histstn_lmdz.xml histstn enabled FALSE 
     273        IGCM_comp_modifyXmlFile nonblocker file_def_histstn_lmdz.xml histstn output_level 0 
     274    else 
     275        IGCM_comp_modifyXmlFile nonblocker file_def_histstn_lmdz.xml histstn enabled TRUE 
     276        IGCM_comp_modifyXmlFile nonblocker file_def_histstn_lmdz.xml histstn output_level ${lmdz_UserChoices_output_level_histstn}  
     277    fi 
     278 
     279 
     280    # histmthCOSP 
     281    if [ X${lmdz_UserChoices_output_level_histmthCOSP} = X ] || [ X${lmdz_UserChoices_output_level_histmthCOSP} = XNONE ] ; then 
     282        IGCM_comp_modifyXmlFile nonblocker file_def_histmthCOSP_lmdz.xml histmthCOSP enabled FALSE 
     283        IGCM_comp_modifyXmlFile nonblocker file_def_histmthCOSP_lmdz.xml histmthCOSP output_level 0 
     284    else 
     285        IGCM_comp_modifyXmlFile nonblocker file_def_histmthCOSP_lmdz.xml histmthCOSP enabled TRUE 
     286        IGCM_comp_modifyXmlFile nonblocker file_def_histmthCOSP_lmdz.xml histmthCOSP output_level ${lmdz_UserChoices_output_level_histmthCOSP}  
     287    fi 
     288 
     289 
     290    # histdayCOSP 
     291    if [ X${lmdz_UserChoices_output_level_histdayCOSP} = X ] || [ X${lmdz_UserChoices_output_level_histdayCOSP} = XNONE ] ; then 
     292        IGCM_comp_modifyXmlFile nonblocker file_def_histdayCOSP_lmdz.xml histdayCOSP enabled FALSE 
     293        IGCM_comp_modifyXmlFile nonblocker file_def_histdayCOSP_lmdz.xml histdayCOSP output_level 0 
     294    else 
     295        IGCM_comp_modifyXmlFile nonblocker file_def_histdayCOSP_lmdz.xml histdayCOSP enabled TRUE 
     296        IGCM_comp_modifyXmlFile nonblocker file_def_histdayCOSP_lmdz.xml histdayCOSP output_level ${lmdz_UserChoices_output_level_histdayCOSP}  
     297    fi 
     298 
     299 
     300    # histhfCOSP 
     301    if [ X${lmdz_UserChoices_output_level_histhfCOSP} = X ] || [ X${lmdz_UserChoices_output_level_histhfCOSP} = XNONE ] ; then 
     302        IGCM_comp_modifyXmlFile nonblocker file_def_histhfCOSP_lmdz.xml histhfCOSP enabled FALSE 
     303        IGCM_comp_modifyXmlFile nonblocker file_def_histhfCOSP_lmdz.xml histhfCOSP output_level 0 
     304    else 
     305        IGCM_comp_modifyXmlFile nonblocker file_def_histhfCOSP_lmdz.xml histhfCOSP enabled TRUE 
     306        IGCM_comp_modifyXmlFile nonblocker file_def_histhfCOSP_lmdz.xml histhfCOSP output_level ${lmdz_UserChoices_output_level_histhfCOSP}  
    332307    fi 
    333308 
     
    393368 
    394369    if [ X${config_ListOfComponents_CHM} = Xinca ] ; then 
    395     echo "Activate coupling to INCA, set type_trac=inca in run.def" 
    396     IGCM_comp_modifyDefFile blocker run.def type_trac inca 
     370        echo "Activate coupling to INCA, set type_trac=inca in run.def" 
     371        IGCM_comp_modifyDefFile blocker run.def type_trac inca 
     372        IGCM_comp_modifyDefFile blocker run.def iflag_phytrac 1   
    397373    elif [ X${config_ListOfComponents_CHM} = Xreprobus ] ; then 
    398     echo "Activate coupling to REPROBUS, set type_trac=repr in run.def" 
    399     IGCM_comp_modifyDefFile blocker run.def type_trac repr 
     374        echo "Activate coupling to REPROBUS, set type_trac=repr in run.def" 
     375        IGCM_comp_modifyDefFile blocker run.def type_trac repr 
    400376        IGCM_comp_modifyDefFile blocker run.def config_inca none 
     377        IGCM_comp_modifyDefFile blocker run.def iflag_phytrac 1   
     378    elif [ X${config_UserChoices_ConfigType} = XESMCO2 ] ; then  
     379        echo "ESM config, set type_trac=co2i in run.def" 
     380        IGCM_comp_modifyDefFile blocker run.def type_trac co2i 
     381        IGCM_comp_modifyDefFile blocker run.def config_inca none 
     382        IGCM_comp_modifyDefFile blocker run.def iflag_phytrac 1   
    401383    elif [ X${lmdz_UserChoices_LMDZ_strataero} = Xy ] ; then 
    402384        echo "No coupling to chemistry model but it is a LMDZ STRATAER configuration, set type_trac=coag in run.def" 
    403385        IGCM_comp_modifyDefFile blocker run.def type_trac coag 
    404386        IGCM_comp_modifyDefFile blocker run.def config_inca none 
    405     else 
    406     echo "No coupling to chemistry model, set type_trac=lmdz in run.def" 
    407     IGCM_comp_modifyDefFile blocker run.def type_trac lmdz 
     387        IGCM_comp_modifyDefFile blocker run.def iflag_phytrac 1   
     388    else 
     389        echo "No coupling to chemistry model, set type_trac=lmdz in run.def" 
     390        IGCM_comp_modifyDefFile blocker run.def type_trac lmdz 
    408391        IGCM_comp_modifyDefFile blocker run.def config_inca none 
    409     fi 
    410  
    411     # run.def : Activate the call to phytrac  
    412     if [ ! X${lmdz_UserChoices_iflag_phytrac} = X ]; then  
    413         IGCM_comp_modifyDefFile nonblocker run.def iflag_phytrac ${lmdz_UserChoices_iflag_phytrac} 
    414     elif [ X${lmdz_UserChoices_LMDZ_strataero} = Xy ] ; then 
    415     IGCM_comp_modifyDefFile nonblocker run.def iflag_phytrac 1 
    416     else 
    417         IGCM_comp_modifyDefFile nonblocker run.def iflag_phytrac 0 
     392        IGCM_comp_modifyDefFile blocker run.def iflag_phytrac 0 
     393    fi 
     394 
     395    # run.def : Activate the new calving  
     396    if [ ! X${lmdz_UserChoices_cpl_old_calving} = X ]; then  
     397        IGCM_comp_modifyDefFile nonblocker run.def cpl_old_calving ${lmdz_UserChoices_cpl_old_calving} 
     398    else 
     399        IGCM_comp_modifyDefFile nonblocker run.def cpl_old_calving y 
    418400    fi  
    419401 
     
    423405    else 
    424406        IGCM_comp_modifyDefFile nonblocker physiq.def ok_bug_cv_trac  n 
     407    fi  
     408 
     409    # config.def : Activate aerosol strato  
     410    if [ ! X${lmdz_UserChoices_flag_aerosol_strat} = X ]; then  
     411        IGCM_comp_modifyDefFile nonblocker config.def flag_aerosol_strat ${lmdz_UserChoices_flag_aerosol_strat} 
     412    else 
     413        IGCM_comp_modifyDefFile nonblocker config.def flag_aerosol_strat DEFAULT 
    425414    fi  
    426415 
     
    491480    fi  
    492481 
    493     # config.def : Modify parameter ok_volcan if it is set in lmdz.card 
    494     if [ ! X${lmdz_UserChoices_ok_volcan} = X ]; then 
    495     IGCM_comp_modifyDefFile nonblocker config.def ok_volcan ${lmdz_UserChoices_ok_volcan} 
    496     else 
    497     # Take default value set in config.def 
    498     IGCM_comp_modifyDefFile nonblocker config.def ok_volcan DEFAULT 
    499     fi 
    500  
    501     # config.def : set ok_volcan to y if we are in the strataero config 
    502     if [ X${lmdz_UserChoices_LMDZ_strataero} = Xy ] ; then 
    503     IGCM_comp_modifyDefFile nonblocker config.def ok_volcan y 
    504     else 
    505     IGCM_comp_modifyDefFile nonblocker config.def ok_volcan DEFAULT 
    506     fi 
    507  
     482    if [ X${config_UserChoices_ConfigType} = XESMCO2 ] ; then 
     483        # Set carbon cycle parameters according to parmeters in lmdz.card  
     484        IGCM_comp_modifyDefFile blocker config.def level_coupling_esm 2  
     485        IGCM_comp_modifyDefFile blocker config.def carbon_cycle_cpl ${lmdz_UserChoices_carbon_cycle_cpl}  
     486        IGCM_comp_modifyDefFile blocker config.def carbon_cycle_tr ${lmdz_UserChoices_carbon_cycle_tr} 
     487        IGCM_comp_modifyDefFile blocker config.def carbon_cycle_rad ${lmdz_UserChoices_carbon_cycle_rad} 
     488    else 
     489        # Take default value set in config.def 
     490        IGCM_comp_modifyDefFile nonblocker config.def level_coupling_esm DEFAULT 
     491        IGCM_comp_modifyDefFile nonblocker config.def carbon_cycle_cpl DEFAULT  
     492        IGCM_comp_modifyDefFile nonblocker config.def carbon_cycle_tr DEFAULT 
     493        IGCM_comp_modifyDefFile nonblocker config.def carbon_cycle_rad DEFAULT 
     494    fi 
     495 
     496    # config.def : Modify parameter ok_volcan if ok_volcan=y or LMDZ_strataero=y in lmdz.card 
    508497    # Note: ok_volcan is a flag allowing a double-call with/without natural forcing (instead of with/without anthro forcing). 
     498    if [ ! X${lmdz_UserChoices_ok_volcan} = X ] || [ X${lmdz_UserChoices_LMDZ_strataero} = Xy ] ; then 
     499        IGCM_comp_modifyDefFile nonblocker config.def ok_volcan ${lmdz_UserChoices_ok_volcan} 
     500    else 
     501        # Take default value set in config.def 
     502        IGCM_comp_modifyDefFile nonblocker config.def ok_volcan DEFAULT 
     503    fi 
    509504 
    510505    # physiq.def : Modify parameter tau_gl if it is set in lmdz.card 
     
    581576    fi 
    582577 
    583     #Compression level (if CompressionLevel is not empty) 
     578    # Compression level (if CompressionLevel is not empty) 
    584579    if [ ! "X${config_UserChoices_CompressionLevel}" = "X" ] ; then 
    585580    echo "NetCDF output files compression level is " ${config_UserChoices_CompressionLevel} 
    586581    listfile=$(ls file_def*lmdz.xml) 
    587     for file in ${listfile} 
    588     do 
     582    for file in ${listfile} ; do 
    589583        sed -i -e "s/\(compression_level=\"\)[^\"]*\(\"\)/\1${config_UserChoices_CompressionLevel}\2/" ${file} 
    590584    done 
     
    600594    IGCM_debug_PushStack "ATM_Finalize" 
    601595 
    602     # Add special treatement for CARBON CYCLE 
    603     if [ X"${lmdz_UserChoices_CARBON_CYCLE}" = X"control" ] || [ X"${lmdz_UserChoices_CARBON_CYCLE}" = X"historical" ] ; then 
    604         ATM_Carbon_Finalize 
    605     fi 
    606  
    607     echo FINALIZE ATM ! 
     596    IGCM_debug_Print 1 "FINALIZE ATM !" 
    608597 
    609598    IGCM_debug_PopStack "ATM_Finalize" 
    610599} 
    611600 
    612  
    613  
    614 function ATM_Carbon_Update 
    615 { 
    616     # This fuction will be called only if CARBON_CYCLE is set to control or historical in lmdz.card 
    617  
    618     IGCM_debug_PushStack "ATM_Carbon_Update" 
    619  
    620     typeset InitPeriodCo2 InitDateBeginCo2 InitDateEndCo2 
    621     typeset CO2SBG CO2MBG CO2LU CO2_ppm CO2_ppm_prec fCO2_ff 
    622     typeset PathCO2log  
    623     typeset PreviousLinelog LastPeriodDateBegin LastPeriodDateEnd LastDatesPeriod LastPREFIX 
    624      
    625     if ( ${FirstInitialize} && [ X"${config_ATM_Restart}" = X"n" ] ) ; then 
    626         ##--Initialization of fluxes to an undefined value at the first run 
    627         UndefinedValueCo2=-9999 
    628         InitPeriodCo2=0 
    629         InitDateBeginCo2=${UndefinedValueCo2} 
    630         InitYearCo2=$(( ${year} - 1 ))  
    631         InitDateEndCo2=${InitYearCo2}1231 
    632         fCO2_ff=${UndefinedValueCo2}  
    633         CO2SBG=${UndefinedValueCo2} 
    634         CO2LU=${UndefinedValueCo2} 
    635         CO2MBG=${UndefinedValueCo2} 
    636         CO2_ppm_prec=${UndefinedValueCo2} 
    637         # Get the initial value of atmosp. pco2  
    638         CO2_ppm=${lmdz_UserChoices_co2_init} 
    639          
    640         IGCM_sys_Cp ${SUBMIT_DIR}/co2.log.init ${SUBMIT_DIR}/co2.log 
    641         IGCM_sys_Chmod u+w ${SUBMIT_DIR}/co2.log 
    642          
    643         # Save CO2 values in ExeCpuLog variable contents 5 fields 
    644         echo "${InitPeriodCo2} ${InitDateBeginCo2} ${InitDateEndCo2} ${CO2_ppm} ${CO2_ppm_prec} ${fCO2_ff} ${CO2MBG} ${CO2SBG} ${CO2LU}" |   \ 
    645             gawk '{printf("  %11d | %15s | %15s | %22.15g | %20.15g | %11.8g | %11.8g | %12.8g | %12.8g \n", \ 
    646                               $1,$2,$3,$4,$5,$6,$7,$8,$9)}' >> ${SUBMIT_DIR}/co2.log 
    647          
    648         # Get the path where the log file co2.log is 
    649         PathCO2log=${SUBMIT_DIR}  
    650         # Get Previous line in co2.log 
    651         PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
    652          
    653     else 
    654          
    655         # NEW parameter in config.card (even for Overule all restarts, you must modify the line after this comment ): 
    656         # !! NEW for Carbone cycle !! Path where to find old co2.log file for restart CO2. 
    657         #SubmitRestartPath= 
    658         if ( ${FirstInitialize} && [ X"${config_ATM_Restart}" = X"y" ] ) ; then 
    659             IGCM_card_DefineVariableFromOption ${SUBMIT_DIR}/config.card ATM SubmitRestartPath 
    660             PathCO2log=${config_ATM_SubmitRestartPath} 
    661             Date_r=$( IGCM_date_ConvertFormatToGregorian ${config_ATM_RestartDate} ) 
    662             PreviousLinelog=$( grep ${Date_r} ${PathCO2log}/co2.log ) 
    663              
    664             IGCM_sys_Cp ${SUBMIT_DIR}/co2.log.init ${SUBMIT_DIR}/co2.log 
    665             IGCM_sys_Chmod u+w ${SUBMIT_DIR}/co2.log 
    666              
    667             # Save Last Line of control in new co2.log file 
    668             InitPeriodCo2=0    
    669             InitDateBeginCo2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $2}' ) 
    670             InitDateEndCo2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $3}' ) 
    671             fCO2_ff=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $6}' ) 
    672             CO2SBG=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $8}' ) 
    673             CO2LU=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $9}' ) 
    674             CO2MBG=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $7}' ) 
    675             CO2_ppm_prec=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $5}' ) 
    676             CO2_ppm=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
    677              
    678             echo "${InitPeriodCo2} ${InitDateBeginCo2} ${InitDateEndCo2} ${CO2_ppm} ${CO2_ppm_prec} ${fCO2_ff} ${CO2MBG} ${CO2SBG} ${CO2LU}" |   \ 
    679                 gawk '{printf("  %11d | %15s | %15s | %22.15g | %20.15g | %11.8g | %11.8g | %12.8g | %12.8g \n", \ 
    680                               $1,$2,$3,$4,$5,$6,$7,$8,$9)}' >> ${SUBMIT_DIR}/co2.log 
    681         else 
    682            # Get restart line in co2.log 
    683             PathCO2log=${SUBMIT_DIR} 
    684             PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
    685            # Get the value of atmosp. pco2 in co2.log 
    686             CO2_ppm=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
    687         fi 
    688          
    689     fi 
    690      
    691     if [ ${lmdz_UserChoices_CARBON_CYCLE} = historical ] ; then 
    692         # Modify co2_ppm in config.def only for historical run 
    693         # If not historical run, keep co2_ppm value set earlier by IGCM_comp_modifyDefFile 
    694         IGCM_comp_modifyDefFile force config.def co2_ppm     ${CO2_ppm} 
    695     fi 
    696     IGCM_debug_PopStack "ATM_Carbon_Update" 
    697 } 
    698  
    699  
    700 function ATM_Carbon_Finalize 
    701 { 
    702     # This fuction will be called only if CARBON_CYCLE is set to control or historical in lmdz.card 
    703  
    704     IGCM_debug_PushStack "ATM_Carbon_Finalize" 
    705  
    706     typeset CO2SBG_3V CO2SBG CO2MBG CO2SRF CO2LU CO2_ppm CO2_ppm_prec fCO2_ff 
    707      
    708         # Fossil fuel emission 
    709     if [ ${lmdz_UserChoices_CARBON_CYCLE} = control ] ; then 
    710             # For Control, no fossil fuel emission : 
    711         fCO2_ff=0 
    712         echo "Fossil Fuel for control run  :" ${fCO2_ff} 
    713     else 
    714             # For historical, get the fossile fuel file : 
    715         fCO2_ff=$( gawk "{if (match(\$0,\"${year}\ *${month}\")) {print \$3}}" ${SUBMIT_DIR}/PARAM/CMIP5_gridcar_CO2_emissions_fossil_fuel_Andres_1751-2007_monthly_SC.txt ) 
    716         echo "Fossil Fuel for historical run  :" ${fCO2_ff} 
    717     fi 
    718      
    719         # Get the value of ocean carbon flux 
    720     CO2MBG=$( ${SUBMIT_DIR}/COMP/lmdz_analyse_pisces_out.awk ocean.output ) 
    721     CO2MBG=$( echo ${CO2MBG} | sed -e "s/ *//" ) 
    722     echo "Ocean carbon flux  :" ${CO2MBG} 
    723      
    724         # Get the value of land fluxes 
    725     set +A CO2SBG_3V -- $( ${SUBMIT_DIR}/COMP/lmdz_analyse_stomate_out.awk out_orchidee_0000 ) 
    726     CO2SRF=$( echo ${CO2SBG_3V[0]} | sed -e "s/ *//" ) 
    727     CO2LU=$( echo ${CO2SBG_3V[1]} | sed -e "s/ *//" ) 
    728     CO2SBG=$( echo ${CO2SBG_3V[2]} | sed -e "s/ *//" ) 
    729     echo "Land carbon flux (NEP)         :" ${CO2SRF} 
    730     echo "LU flux          (FLUC)        :" ${CO2LU} 
    731     echo "Total Land carbon flux (NBP)   :" ${CO2SBG} 
    732      
    733         # Previous CO2 
    734     CO2_ppm_prec=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
    735     echo "Previous CO2  :" ${CO2_ppm_prec} 
    736      
    737         # Formula 
    738     CO2_ppm=$( echo "${CO2_ppm_prec} + (${fCO2_ff} + ${CO2MBG} + ${CO2SBG}) / 2.12" | bc -l ) 
    739     echo "New CO2  :" ${CO2_ppm} 
    740      
    741         # Save CO2 values in ExeCpuLog variable contents 5 fields 
    742     echo "${CumulPeriod} ${PeriodDateBegin} ${PeriodDateEnd} ${CO2_ppm} ${CO2_ppm_prec} ${fCO2_ff} ${CO2MBG} ${CO2SBG} ${CO2LU}" |   \ 
    743         gawk '{printf("  %11d | %15s | %15s | %22.15g | %20.15g | %11.8g | %11.8g | %12.8g | %12.8g \n", \ 
    744                            $1,$2,$3,$4,$5,$6,$7,$8,$9)}' >> ${SUBMIT_DIR}/co2.log 
    745      
    746     IGCM_debug_PopStack "ATM_Carbon_Finalize" 
    747 } 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/DRIVER/orchidee.driver

    r4353 r4936  
    169169    fi 
    170170 
    171     #Compression level (if CompressionLevel is not empty) 
     171    # Compression level (if CompressionLevel is not empty) 
    172172    if [ ! "X${config_UserChoices_CompressionLevel}" = "X" ] ; then 
    173173        echo "NetCDF output files compression level is " ${config_UserChoices_CompressionLevel} 
    174174        listfile=$(ls file_def*orchidee.xml) 
    175         for file in ${listfile} 
    176         do 
     175        for file in ${listfile} ; do 
    177176            sed -i -e "s/\(compression_level=\"\)[^\"]*\(\"\)/\1${config_UserChoices_CompressionLevel}\2/" ${file} 
    178177        done 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/DRIVER/xios.driver

    r3864 r4936  
    2020 
    2121# Activate 2nd server level for CMIP6 type experiments (CMIP6 workflow) 
    22     if [ X"$( echo ${config_UserChoices_ExpType} | grep CMIP6 )" != "X" ] ; then 
    23     IGCM_comp_modifyXmlFile force iodef.xml using_server2 NONE true 
     22    if [ X"$( echo ${config_UserChoices_ExpType} | grep CMIP6 )" != "X" ] || [ X"$( echo ${config_UserChoices_ExpType} | grep MR025 )" != "X" ] ; then 
     23       IGCM_comp_modifyXmlFile force iodef.xml using_server2 NONE true 
    2424    fi 
    2525 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/PARAM/config.def_actuel

    r4724 r4936  
     1## level_coupling_esm : 0(pas d'echange de carbone), 2 (change entre LMDZ/CPL/NEMO et LMDZ/ORCHIDEE) 
     2level_coupling_esm=  _AUTO_: DEFAULT = 0 
     3## carbon_cycle_cpl: couplage des flux de carbone ATM/OCE, ATM/SRF 
     4carbon_cycle_cpl=_AUTO_ : DEFAULT=n 
     5## carbon_cycle_tr: transport atmospherique de CO2 dans LMDZ 
     6carbon_cycle_tr=_AUTO_ : DEFAULT=n 
     7## carbon_cycle_rad: utilisation de traceur CO2 dans le code radiatif 
     8carbon_cycle_rad=_AUTO_ : DEFAULT=n 
     9 
    110##  Cycle diurne  ou non                  
    211iflag_cycle_diurne=1 
     
    7281#  
    7382# Aerosols stratospheriques utilises par defaut  
    74 flag_aerosol_strat=2 
    75 # Flag to yield double call with/without natural forcing (instead of with/without anthropic) 
    76 ok_volcan=_AUTO_: DEFAULT = n 
     83flag_aerosol_strat=_AUTO_ : DEFAULT=2 
     84# Diag VolMIP to get volcanic aerosols effects instead of tropospheric ones 
     85ok_volcan=n 
    7786# 
    7887# COSP 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/PARAM/config.def_annuel

    r4724 r4936  
     1# level_coupling_esm : 0(pas d'echange de carbone), 2 (change entre LMDZ/CPL/NEMO et LMDZ/ORCHIDEE) 
     2level_coupling_esm=  _AUTO_: DEFAULT = 0 
     3## carbon_cycle_cpl: couplage des flux de carbone ATM/OCE, ATM/SRF 
     4carbon_cycle_cpl=_AUTO_ : DEFAULT=n 
     5## carbon_cycle_tr: transport atmospherique de CO2 dans LMDZ 
     6carbon_cycle_tr=_AUTO_ : DEFAULT=n 
     7## carbon_cycle_rad: utilisation de traceur CO2 dans le code radiatif 
     8carbon_cycle_rad=_AUTO_ : DEFAULT=n 
     9 
    110##  Cycle diurne  ou non                  
    211iflag_cycle_diurne=1 
     
    7382#  
    7483# Aerosols stratospheriques utilises par defaut  
    75 flag_aerosol_strat=2 
    76 # Flag to yield double call with/without natural forcing (instead of with/without anthropic) 
    77 ok_volcan=_AUTO_: DEFAULT = n 
     84flag_aerosol_strat=_AUTO_ : DEFAULT=2 
     85# Diag VolMIP to get volcanic aerosols effects instead of tropospheric ones 
     86ok_volcan=n 
    7887# 
    7988# COSP 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/PARAM/config.def_preind

    r4724 r4936  
     1## level_coupling_esm : 0(pas d'echange de carbone), 2 (change entre LMDZ/CPL/NEMO et LMDZ/ORCHIDEE) 
     2level_coupling_esm=  _AUTO_: DEFAULT = 0 
     3## carbon_cycle_cpl: couplage des flux de carbone ATM/OCE, ATM/SRF 
     4carbon_cycle_cpl=_AUTO_ : DEFAULT=n 
     5## carbon_cycle_tr: transport atmospherique de CO2 dans LMDZ 
     6carbon_cycle_tr=_AUTO_ : DEFAULT=n 
     7## carbon_cycle_rad: utilisation de traceur CO2 dans le code radiatif 
     8carbon_cycle_rad=_AUTO_ : DEFAULT=n 
     9 
    110##  Cycle diurne  ou non                  
    211iflag_cycle_diurne=1 
     
    7382# Aerosols stratospheriques utilises par defaut  
    7483# 
    75 flag_aerosol_strat=2 
    76 # Flag to yield double call with/without natural forcing (instead of with/without anthropic) 
    77 ok_volcan=_AUTO_: DEFAULT = n 
    78 # 
     84flag_aerosol_strat=_AUTO_ : DEFAULT=2 
     85# Diag VolMIP to get volcanic aerosols effects instead of tropospheric ones 
     86ok_volcan=n 
    7987# 
    8088# COSP 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/PARAM/iodef.xml

    r3864 r4936  
    3434      <variable id="activate_non_distributed_transformation" type="bool">true</variable> 
    3535      <variable id="recv_field_timeout" type="double">3000.0</variable> 
     36      <variable id="call_oasis_enddef" type="bool">true</variable> 
    3637    </variable_definition> 
    3738 
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/GENERAL/PARAM/run.def

    r4020 r4936  
    5555no_ter_antartique=y 
    5656### Do not call phytrac to speed things up 
    57 iflag_phytrac=_AUTO_: DEFAULT = 0 
     57iflag_phytrac=_AUTOBLOCKER_: DEFAULT = 0 
     58### cpl_old_calving : use n for DYNAMICO and new coupling weight(MR025) 
     59cpl_old_calving = _AUTO_ 
    5860 
Note: See TracChangeset for help on using the changeset viewer.