Changeset 2343 for CONFIG/UNIFORM/v6/IPSLCM6/GENERAL/DRIVER/lmdz.driver
- Timestamp:
- 09/26/14 11:46:12 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
CONFIG/UNIFORM/v6/IPSLCM6/GENERAL/DRIVER/lmdz.driver
r2321 r2343 1 1 #!/bin/ksh 2 2 #----------------------------------------------------------------- 3 function LMDZ_sed4 {5 # Usage : LMDZ_sed filedef var_name myvalue6 # In file filedef modify the line containing var_name=xxx into var_name=myvalue7 IGCM_debug_PushStack "LMDZ_sed"8 9 # Test if the fichier exist10 if [ ! -f ${1} ] ; then11 echo "WARNING : ${1} file does not exist. Following will not be done : LMDZ_sed : ${1} ${2} ${3}"12 IGCM_debug_PopStack "LMDZ_sed"13 return14 fi15 16 sed -e "s/^${2}\ *=.*/${2}= ${3}/" ${1} > ${1}.tmp17 RET=$?18 echo "LMDZ_sed : ${1} ${2} ${3}"19 \mv ${1}.tmp ${1}20 21 IGCM_debug_PopStack "LMDZ_sed"22 return $RET23 }24 25 function LMDZ_sed_default26 {27 # Usage : LMDZ_sed_default filedef var_name28 # In file filedef modify the line "var_name=xxx DEFAULT= myvalue"29 # into "var_name=myvalue"30 IGCM_debug_PushStack "LMDZ_sed_default"31 32 DefValue=$( grep ${2} ${1} | awk -F"DEFAULT.=*" '{print $2}')33 34 LMDZ_sed ${1} ${2} $DefValue35 IGCM_debug_PopStack "LMDZ_sed_default"36 return $RET37 }38 39 function LMDZ_sed_xml40 {41 # Usage : LMDZ_sed_xml xml_file output_file attribute value42 # In file xml_file modify at the line containing id="output_file" the attribute "attribute=xxx" into "attribute=value"43 44 IGCM_debug_PushStack "LMDZ_sed_xml"45 # Test if the fichier exist46 if [ ! -f ${1} ] ; then47 echo "WARNING : ${1} file does not exist. Following will not be done : LMDZ_sed : ${1} ${2} ${3} ${4}"48 IGCM_debug_PopStack "LMDZ_sed_xml"49 return50 fi51 sed -e "/id=\"${2}\"/s/\(${3}=\"\)[^\"]*\(\"\)/\1${4}\2/" ${1} > ${1}.tmp52 RET=$?53 echo "LMDZ_sed : ${1} ${2} ${3} ${4}"54 \mv ${1}.tmp ${1}55 IGCM_debug_PopStack "LMDZ_sed_xml"56 return $RET57 }58 59 3 function ATM_Initialize 60 4 { … … 69 13 RESOL_ATM_Y=$( echo ${RESOL_ATM_3D} | awk "-Fx" '{print $2}' ) 70 14 RESOL_ATM_XY="${RESOL_ATM_X}x${RESOL_ATM_Y}" 71 FreqCoupling=${oasis_UserChoices_FreqCoupling:-86400}72 15 73 16 ##-- Calendar type for LMDZ and create_etat0_limit … … 281 224 ## If forcing file exist in run directory, read values for the current year 282 225 ## and set in config.def. If not use the default value set in config.def 226 227 # Read value for solaire from file SOLARANDVOLCANOES.txt. If file not existing, take DEFAULT value from file. 283 228 if [ -f SOLARANDVOLCANOES.txt ] ; then 284 IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'`285 if [ X"${ IPCC_SOLAR}" = X ] ; then229 value=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 230 if [ X"${value}" = X ] ; then 286 231 # The grep returned empty variable, stop execution 287 232 IGCM_debug_Exit "The file SOLARANDVOLCANOES.txt do not contain the current year." 288 233 IGCM_debug_Verif_Exit 289 else290 # Set new variable in config.def file291 LMDZ_sed config.def solaire ${IPCC_SOLAR}292 293 else294 LMDZ_sed_default config.def solaire 295 fi 296 234 fi 235 else 236 value=DEFAULT 237 fi 238 IGCM_comp_modifyDefFile nonblocker config.def solaire $value 239 240 241 # Read value for co2_ppm from file CO2.txt. If file not existing, take DEFAULT value from file. 297 242 if [ -f CO2.txt ] ; then 298 IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'`299 if [ X"${ IPCC_CO2}" = X ] ; then243 value=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 244 if [ X"${value}" = X ] ; then 300 245 # The grep returned empty variable, stop execution 301 246 IGCM_debug_Exit "The file CO2.txt do not contain the current year." 302 247 IGCM_debug_Verif_Exit 303 else304 # Set new variable in config.def file305 LMDZ_sed config.def co2_ppm ${IPCC_CO2}306 307 else308 LMDZ_sed_default config.def co2_ppm 309 fi 310 248 fi 249 else 250 value=DEFAULT 251 fi 252 IGCM_comp_modifyDefFile nonblocker config.def co2_ppm $value 253 254 255 # Read value for CH4_ppb from file CH4.txt. If file not existing, take DEFAULT value from file. 311 256 if [ -f CH4.txt ] ; then 312 IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'`313 if [ X"${ IPCC_CH4}" = X ] ; then257 value=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 258 if [ X"${value}" = X ] ; then 314 259 # The grep returned empty variable, stop execution 315 260 IGCM_debug_Exit "The file CH4.txt do not contain the current year." 316 261 IGCM_debug_Verif_Exit 317 else318 # Set new variable in config.def file319 LMDZ_sed config.def CH4_ppb ${IPCC_CH4}320 321 else322 LMDZ_sed_default config.def CH4_ppb 323 fi 324 262 fi 263 else 264 value=DEFAULT 265 fi 266 IGCM_comp_modifyDefFile nonblocker config.def CH4_ppb $value 267 268 269 # Read value for N2O_ppb from file N2O.txt. If file not existing, take DEFAULT value from file. 325 270 if [ -f N2O.txt ] ; then 326 IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'`327 if [ X"${ IPCC_N2O}" = X ] ; then271 value=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 272 if [ X"${value}" = X ] ; then 328 273 # The grep returned empty variable, stop execution 329 274 IGCM_debug_Exit "The file N2O.txt do not contain the current year." 330 275 IGCM_debug_Verif_Exit 331 else 332 # Set new variable in config.def file 333 LMDZ_sed config.def N2O_ppb ${IPCC_N2O} 334 fi 335 else 336 LMDZ_sed_default config.def N2O_ppb 337 fi 338 276 fi 277 else 278 value=DEFAULT 279 fi 280 IGCM_comp_modifyDefFile nonblocker config.def N2O_ppb $value 281 282 # Read value for CFC11_ppt from file CFC11.txt. If file not existing, take DEFAULT value from file. 339 283 if [ -f CFC11.txt ] ; then 340 IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'`341 if [ X"${ IPCC_CFC11}" = X ] ; then284 value=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 285 if [ X"${value}" = X ] ; then 342 286 # The grep returned empty variable, stop execution 343 287 IGCM_debug_Exit "The file CFC11.txt do not contain the current year." 344 288 IGCM_debug_Verif_Exit 345 else346 # Set new variable in config.def file347 LMDZ_sed config.def CFC11_ppt ${IPCC_CFC11}348 349 else350 LMDZ_sed_default config.def CFC11_ppt 351 fi 352 289 fi 290 else 291 value=DEFAULT 292 fi 293 IGCM_comp_modifyDefFile nonblocker config.def CFC11_ppt $value 294 295 296 # Read value for CFC12_ppt from file CFC12.txt. If file not existing, take DEFAULT value from file. 353 297 if [ -f CFC12.txt ] ; then 354 IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'`355 if [ X"${ IPCC_CFC12}" = X ] ; then298 value=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 299 if [ X"${value}" = X ] ; then 356 300 # The grep returned empty variable, stop execution 357 301 IGCM_debug_Exit "The file CFC12.txt do not contain the current year." 358 302 IGCM_debug_Verif_Exit 359 else 360 # Set new variable in config.def file 361 LMDZ_sed config.def CFC12_ppt ${IPCC_CFC12} 362 fi 363 else 364 LMDZ_sed_default config.def CFC12_ppt 365 fi 366 367 368 ## Coupling Time Step 369 LMDZ_t_coupl=${oasis_UserChoices_FreqCoupling:-${lmdz_UserChoices_t_coupl}} 303 fi 304 else 305 value=DEFAULT 306 fi 307 IGCM_comp_modifyDefFile nonblocker config.def CFC12_ppt $value 308 309 310 ## Coupling Time Step : Take value of FreqCoupling set in oasis.card or if it is not set, take default value 86400 311 LMDZ_t_coupl=${oasis_UserChoices_FreqCoupling:-86400} 370 312 IGCM_debug_Print 3 "LMDZ_t_coupl " ${LMDZ_t_coupl} 371 LMDZ_sed config.def t_coupl ${LMDZ_t_coupl}313 IGCM_comp_modifyDefFile nonblocker config.def t_coupl ${LMDZ_t_coupl} 372 314 373 315 ##-- Add special treatement for CARBON CYCLE … … 386 328 ## output.def parameters 387 329 # columns in phys_output_filekeys refer to the filenames given in phys_out_filenames in output.def : 388 # histmth histday histhf hist fh3h histhf3hm histstn389 LMDZ_sed output.def phys_out_filekeys"${ok_mensuel} ${ok_journe} ${ok_hf} ${ok_hf3h} ${ok_hf3hm} ${ok_stn}"390 LMDZ_sedoutput.def ecrit_ISCCP ${LMDZ_ecrit_ISCCP}391 LMDZ_sedoutput.def ok_cosp ${LMDZ_COSP_OK}392 LMDZ_sedoutput.def ok_mensuelCOSP ${LMDZ_COSP_monthly}393 LMDZ_sedoutput.def ok_journeCOSP ${LMDZ_COSP_daily}394 LMDZ_sedoutput.def ok_hfCOSP ${LMDZ_COSP_hf}395 LMDZ_sedoutput.def ok_histNMC "${LMDZ_NMC_monthly} ${LMDZ_NMC_daily} ${LMDZ_NMC_hf}"330 # histmth histday histhf histhf3h histhf3hm histstn 331 IGCM_comp_modifyDefFile nonblocker output.def phys_out_filekeys "${ok_mensuel} ${ok_journe} ${ok_hf} ${ok_hf3h} ${ok_hf3hm} ${ok_stn}" 332 IGCM_comp_modifyDefFile nonblocker output.def ecrit_ISCCP ${LMDZ_ecrit_ISCCP} 333 IGCM_comp_modifyDefFile nonblocker output.def ok_cosp ${LMDZ_COSP_OK} 334 IGCM_comp_modifyDefFile nonblocker output.def ok_mensuelCOSP ${LMDZ_COSP_monthly} 335 IGCM_comp_modifyDefFile nonblocker output.def ok_journeCOSP ${LMDZ_COSP_daily} 336 IGCM_comp_modifyDefFile nonblocker output.def ok_hfCOSP ${LMDZ_COSP_hf} 337 IGCM_comp_modifyDefFile nonblocker output.def ok_histNMC "${LMDZ_NMC_monthly} ${LMDZ_NMC_daily} ${LMDZ_NMC_hf}" 396 338 397 339 # XIOS XML definition 398 340 # Default init : files are desactivated 399 LMDZ_sed_xmlfile_def_histmth_lmdz.xml histmth enabled .FALSE.400 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday enabled .FALSE.401 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf enabled .FALSE.402 LMDZ_sed_xml file_def_histfh3h_lmdz.xml histfh3h enabled .FALSE.403 LMDZ_sed_xml file_def_histhf3hm_lmdz.xml histfh3hm enabled .FALSE.404 LMDZ_sed_xmlfile_def_histstn_lmdz.xml histstn enabled .FALSE.405 LMDZ_sed_xmlfile_def_histmthNMC_lmdz.xml histmthNMC enabled .FALSE.406 LMDZ_sed_xmlfile_def_histdayNMC_lmdz.xml histdayNMC enabled .FALSE.407 LMDZ_sed_xmlfile_def_histhfNMC_lmdz.xml histhfNMC enabled .FALSE.341 IGCM_comp_modifyXmlFile force file_def_histmth_lmdz.xml histmth enabled .FALSE. 342 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday enabled .FALSE. 343 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf enabled .FALSE. 344 # IGCM_comp_modifyXmlFile force file_def_histhf3h_lmdz.xml histhf3h enabled .FALSE. 345 # IGCM_comp_modifyXmlFile force file_def_histhf3hm_lmdz.xml histhf3hm enabled .FALSE. 346 IGCM_comp_modifyXmlFile force file_def_histstn_lmdz.xml histstn enabled .FALSE. 347 IGCM_comp_modifyXmlFile force file_def_histmthNMC_lmdz.xml histmthNMC enabled .FALSE. 348 IGCM_comp_modifyXmlFile force file_def_histdayNMC_lmdz.xml histdayNMC enabled .FALSE. 349 IGCM_comp_modifyXmlFile force file_def_histhfNMC_lmdz.xml histhfNMC enabled .FALSE. 408 350 if [ X${lmdz_UserChoices_XIOS} = Xy ] ; then 409 351 # Default output level : 5 410 LMDZ_sed_xmlfile_def_histmth_lmdz.xml histmth output_level 5411 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday output_level 5412 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf output_level 5413 LMDZ_sed_xml file_def_histfh3h_lmdz.xml histfh3h output_level 5414 LMDZ_sed_xml file_def_histhf3hm_lmdz.xml histfh3hm output_level 5415 LMDZ_sed_xmlfile_def_histstn_lmdz.xml histstn output_level 5416 LMDZ_sed_xmlfile_def_histmthNMC_lmdz.xml histmthNMC output_level 5417 LMDZ_sed_xmlfile_def_histdayNMC_lmdz.xml histdayNMC output_level 5418 LMDZ_sed_xmlfile_def_histhfNMC_lmdz.xml histhfNMC output_level 5352 IGCM_comp_modifyXmlFile force file_def_histmth_lmdz.xml histmth output_level 5 353 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday output_level 5 354 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf output_level 5 355 # IGCM_comp_modifyXmlFile force file_def_histhf3h_lmdz.xml histhf3h output_level 5 356 # IGCM_comp_modifyXmlFile force file_def_histhf3hm_lmdz.xml histhf3hm output_level 5 357 IGCM_comp_modifyXmlFile force file_def_histstn_lmdz.xml histstn output_level 5 358 IGCM_comp_modifyXmlFile force file_def_histmthNMC_lmdz.xml histmthNMC output_level 5 359 IGCM_comp_modifyXmlFile force file_def_histdayNMC_lmdz.xml histdayNMC output_level 5 360 IGCM_comp_modifyXmlFile force file_def_histhfNMC_lmdz.xml histhfNMC output_level 5 419 361 # Filling of XML files 420 362 if [ X${ok_mensuel} = Xy ] ; then 421 LMDZ_sed_xmlfile_def_histmth_lmdz.xml histmth enabled .TRUE.422 LMDZ_sed_xmlfile_def_histmth_lmdz.xml histmth output_freq 1mo423 LMDZ_sed_xmlfile_def_histmth_lmdz.xml histmth name histmth363 IGCM_comp_modifyXmlFile force file_def_histmth_lmdz.xml histmth enabled .TRUE. 364 IGCM_comp_modifyXmlFile force file_def_histmth_lmdz.xml histmth output_freq 1mo 365 IGCM_comp_modifyXmlFile force file_def_histmth_lmdz.xml histmth name histmth 424 366 fi 425 367 if [ X${ok_journe} = Xy ] ; then 426 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday enabled .TRUE.427 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday output_freq 1d428 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday name histday368 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday enabled .TRUE. 369 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday output_freq 1d 370 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday name histday 429 371 if [ X${OutLevel} = Xlow ] || [ X${OutLevel} = Xmedium ] ; then 430 LMDZ_sed_xmlfile_def_histday_lmdz.xml histday output_level 2372 IGCM_comp_modifyXmlFile force file_def_histday_lmdz.xml histday output_level 2 431 373 fi 432 374 fi 433 375 if [ X${ok_hf} = Xy ] ; then 434 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf enabled .TRUE.435 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf output_freq 6h436 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf name histhf376 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf enabled .TRUE. 377 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf output_freq 6h 378 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf name histhf 437 379 if [ X${OutLevel} = Xlow ] ; then 438 LMDZ_sed_xmlfile_def_histhf_lmdz.xml histhf output_level 2380 IGCM_comp_modifyXmlFile force file_def_histhf_lmdz.xml histhf output_level 2 439 381 fi 440 382 fi 441 if [ X${ok_hf3h} = Xy ] ; then442 LMDZ_sed_xmlfile_def_histhf3h_lmdz.xml histhf3h enabled .TRUE.443 LMDZ_sed_xmlfile_def_histhf3h_lmdz.xml histhf3h output_freq 3h444 LMDZ_sed_xmlfile_def_histhf3h_lmdz.xml histhf3h name histhf3h445 fi446 if [ X${ok_hf3hm} = Xy ] ; then447 LMDZ_sed_xmlfile_def_histhf3hm_lmdz.xml histhf3hm enabled .TRUE.448 LMDZ_sed_xmlfile_def_histhf3hm_lmdz.xml histhf3hm output_freq 3h449 LMDZ_sed_xmlfile_def_histhf3hm_lmdz.xml histhf3hm name histhf3hm450 fi383 # if [ X${ok_hf3h} = Xy ] ; then 384 # IGCM_comp_modifyXmlFile force file_def_histhf3h_lmdz.xml histhf3h enabled .TRUE. 385 # IGCM_comp_modifyXmlFile force file_def_histhf3h_lmdz.xml histhf3h output_freq 3h 386 # IGCM_comp_modifyXmlFile force file_def_histhf3h_lmdz.xml histhf3h name histhf3h 387 # fi 388 # if [ X${ok_hf3hm} = Xy ] ; then 389 # IGCM_comp_modifyXmlFile force file_def_histhf3hm_lmdz.xml histhf3hm enabled .TRUE. 390 # IGCM_comp_modifyXmlFile force file_def_histhf3hm_lmdz.xml histhf3hm output_freq 3h 391 # IGCM_comp_modifyXmlFile force file_def_histhf3hm_lmdz.xml histhf3hm name histhf3hm 392 # fi 451 393 if [ X${ok_stn} = Xy ] ; then 452 LMDZ_sed_xmlfile_def_histstn_lmdz.xml histstn enabled .TRUE.453 LMDZ_sed_xmlfile_def_histstn_lmdz.xml histstn output_freq 1800s454 LMDZ_sed_xmlfile_def_histstn_lmdz.xml histstn name histstn394 IGCM_comp_modifyXmlFile force file_def_histstn_lmdz.xml histstn enabled .TRUE. 395 IGCM_comp_modifyXmlFile force file_def_histstn_lmdz.xml histstn output_freq 1800s 396 IGCM_comp_modifyXmlFile force file_def_histstn_lmdz.xml histstn name histstn 455 397 fi 456 398 if [ X${LMDZ_NMC_monthly} = Xy ] ; then 457 LMDZ_sed_xmlfile_def_histmthNMC_lmdz.xml histmthNMC enabled .TRUE.458 LMDZ_sed_xmlfile_def_histmthNMC_lmdz.xml histmthNMC output_freq 1mo459 LMDZ_sed_xmlfile_def_histmthNMC_lmdz.xml histmthNMC name histmthNMC399 IGCM_comp_modifyXmlFile force file_def_histmthNMC_lmdz.xml histmthNMC enabled .TRUE. 400 IGCM_comp_modifyXmlFile force file_def_histmthNMC_lmdz.xml histmthNMC output_freq 1mo 401 IGCM_comp_modifyXmlFile force file_def_histmthNMC_lmdz.xml histmthNMC name histmthNMC 460 402 fi 461 403 if [ X${LMDZ_NMC_daily} = Xy ] ; then 462 LMDZ_sed_xmlfile_def_histdayNMC_lmdz.xml histdayNMC enabled .TRUE.463 LMDZ_sed_xmlfile_def_histdayNMC_lmdz.xml histdayNMC output_freq 1d464 LMDZ_sed_xmlfile_def_histdayNMC_lmdz.xml histdayNMC name histdayNMC404 IGCM_comp_modifyXmlFile force file_def_histdayNMC_lmdz.xml histdayNMC enabled .TRUE. 405 IGCM_comp_modifyXmlFile force file_def_histdayNMC_lmdz.xml histdayNMC output_freq 1d 406 IGCM_comp_modifyXmlFile force file_def_histdayNMC_lmdz.xml histdayNMC name histdayNMC 465 407 fi 466 408 if [ X${LMDZ_NMC_hf} = Xy ] ; then 467 LMDZ_sed_xmlfile_def_histhfNMC_lmdz.xml histhfNMC enabled .TRUE.468 LMDZ_sed_xmlfile_def_histhfNMC_lmdz.xml histhfNMC output_freq 6h469 LMDZ_sed_xmlfile_def_histhfNMC_lmdz.xml histhfNMC name histhfNMC409 IGCM_comp_modifyXmlFile force file_def_histhfNMC_lmdz.xml histhfNMC enabled .TRUE. 410 IGCM_comp_modifyXmlFile force file_def_histhfNMC_lmdz.xml histhfNMC output_freq 6h 411 IGCM_comp_modifyXmlFile force file_def_histhfNMC_lmdz.xml histhfNMC name histhfNMC 470 412 fi 471 413 fi 472 414 473 415 ## gcm.def parameters : 474 # Modification o nly for newphysics416 # Modification of variable iphysiq depending on the physics 475 417 if [ X${LMDZ_Physics} = X"AP" ] ; then 476 LMDZ_sed gcm.def iphysiq 10 477 else 478 LMDZ_sed_default gcm.def iphysiq 479 fi 418 value=10 419 else 420 value=DEFAULT 421 fi 422 IGCM_comp_modifyDefFile nonblocker gcm.def iphysiq $value 480 423 481 424 482 425 ## run.def parameters 483 LMDZ_sedrun.def dayref ${InitDay}484 LMDZ_sedrun.def nday ${PeriodLengthInDays}485 LMDZ_sedrun.def raz_date ${RAZ_DATE}486 LMDZ_sedrun.def periodav ${LMDZ_periodav}487 LMDZ_sedrun.def adjust ${LMDZ_adjust}426 IGCM_comp_modifyDefFile blocker run.def dayref ${InitDay} 427 IGCM_comp_modifyDefFile blocker run.def nday ${PeriodLengthInDays} 428 IGCM_comp_modifyDefFile blocker run.def raz_date ${RAZ_DATE} 429 IGCM_comp_modifyDefFile blocker run.def periodav ${LMDZ_periodav} 430 IGCM_comp_modifyDefFile nonblocker run.def adjust ${LMDZ_adjust} 488 431 489 432 # Set anneeref different for gcm and ce0l … … 492 435 if [ -f create_etat0_limit* ] || [ -f ce0l* ] && [ ! -f lmdz.x ] ; then 493 436 # for case ce0l : always take current year 494 LMDZ_sedrun.def anneeref ${year}495 LMDZ_sedrun.def calend ${CalendarTypeForCreate}437 IGCM_comp_modifyDefFile blocker run.def anneeref ${year} 438 IGCM_comp_modifyDefFile blocker run.def calend ${CalendarTypeForCreate} 496 439 else 497 440 # for case gcm : take first year of simulation 498 LMDZ_sedrun.def anneeref ${InitYear}499 LMDZ_sedrun.def calend ${CalendarTypeForLmdz}441 IGCM_comp_modifyDefFile blocker run.def anneeref ${InitYear} 442 IGCM_comp_modifyDefFile blocker run.def calend ${CalendarTypeForLmdz} 500 443 fi 501 444 502 445 # Activate creation of file grilles_gcm.nc only at first period 503 446 if [ ${CumulPeriod} -eq 1 ] ; then 504 LMDZ_sedrun.def grilles_gcm_netcdf y505 else 506 LMDZ_sedrun.def grilles_gcm_netcdf n447 IGCM_comp_modifyDefFile nonblocker run.def grilles_gcm_netcdf y 448 else 449 IGCM_comp_modifyDefFile nonblocker run.def grilles_gcm_netcdf n 507 450 fi 508 451 … … 513 456 if [ X${config_ListOfComponents_SRF} = Xorchidee ] ; then 514 457 echo "Activate ORCHIDEE, set VEGET=y in run.def" 515 LMDZ_sedrun.def VEGET y458 IGCM_comp_modifyDefFile blocker run.def VEGET y 516 459 else 517 460 echo "No ORCHIDEE, set VEGET=n in run.def" 518 LMDZ_sedrun.def VEGET n461 IGCM_comp_modifyDefFile blocker run.def VEGET n 519 462 fi 520 463 521 464 if [ X${config_ListOfComponents_CPL} = Xoasis ] ; then 522 465 echo "Activate coupling to ocean, set type_ocean=couple in run.def" 523 LMDZ_sedrun.def type_ocean couple466 IGCM_comp_modifyDefFile blocker run.def type_ocean couple 524 467 else 525 468 echo "LMDZ is running in forced mode without ocean model, set type_ocean=force in run.def" 526 LMDZ_sedrun.def type_ocean force469 IGCM_comp_modifyDefFile blocker run.def type_ocean force 527 470 fi 528 471 529 472 if [ X${config_ListOfComponents_CHM} = Xinca ] ; then 530 473 echo "Activate coupling to INCA, set type_trac=inca in run.def" 531 LMDZ_sedrun.def type_trac inca474 IGCM_comp_modifyDefFile blocker run.def type_trac inca 532 475 elif [ X${config_ListOfComponents_CHM} = Xreprobus ] ; then 533 476 echo "Activate coupling to REPROBUS, set type_trac=repr in run.def" 534 LMDZ_sedrun.def type_trac repr535 LMDZ_sedrun.def config_inca none477 IGCM_comp_modifyDefFile blocker run.def type_trac repr 478 IGCM_comp_modifyDefFile blocker run.def config_inca none 536 479 else 537 480 echo "No coupling to chemistry model, set type_trac=lmdz in run.def" 538 LMDZ_sedrun.def type_trac lmdz539 LMDZ_sedrun.def config_inca none481 IGCM_comp_modifyDefFile blocker run.def type_trac lmdz 482 IGCM_comp_modifyDefFile blocker run.def config_inca none 540 483 fi 541 484 … … 543 486 # config.def : Activate direct radiative effect if ok_ade=y 544 487 if [ ! X${lmdz_UserChoices_ok_ade} = X ]; then 545 LMDZ_sedconfig.def ok_ade ${lmdz_UserChoices_ok_ade}546 else 547 LMDZ_sedconfig.def ok_ade n488 IGCM_comp_modifyDefFile nonblocker config.def ok_ade ${lmdz_UserChoices_ok_ade} 489 else 490 IGCM_comp_modifyDefFile nonblocker config.def ok_ade n 548 491 fi 549 492 550 493 # config.def : Activate indirect radiative effect if ok_aie=y 551 494 if [ ! X${lmdz_UserChoices_ok_aie} = X ]; then 552 LMDZ_sedconfig.def ok_aie ${lmdz_UserChoices_ok_aie}553 else 554 LMDZ_sedconfig.def ok_aie n495 IGCM_comp_modifyDefFile nonblocker config.def ok_aie ${lmdz_UserChoices_ok_aie} 496 else 497 IGCM_comp_modifyDefFile nonblocker config.def ok_aie n 555 498 fi 556 499 557 500 # config.def : Activate online aerosol coupled model if aerosol_couple=y 558 501 if [ ! X${lmdz_UserChoices_aerosol_couple} = X ]; then 559 LMDZ_sedconfig.def aerosol_couple ${lmdz_UserChoices_aerosol_couple}560 else 561 LMDZ_sedconfig.def aerosol_couple n502 IGCM_comp_modifyDefFile nonblocker config.def aerosol_couple ${lmdz_UserChoices_aerosol_couple} 503 else 504 IGCM_comp_modifyDefFile nonblocker config.def aerosol_couple n 562 505 fi 563 506 564 507 # config.def : Activate reading of ozone in climatology if read_climoz=2 565 508 if [ ! X${lmdz_UserChoices_read_climoz} = X ]; then 566 LMDZ_sedconfig.def read_climoz ${lmdz_UserChoices_read_climoz}567 else 568 LMDZ_sedconfig.def read_climoz 0509 IGCM_comp_modifyDefFile nonblocker config.def read_climoz ${lmdz_UserChoices_read_climoz} 510 else 511 IGCM_comp_modifyDefFile nonblocker config.def read_climoz 0 569 512 fi 570 513 … … 573 516 # =5 => dust only =6 => all aerosol 574 517 if [ ! X${lmdz_UserChoices_flag_aerosol} = X ]; then 575 LMDZ_sedconfig.def flag_aerosol ${lmdz_UserChoices_flag_aerosol}576 else 577 LMDZ_sedconfig.def flag_aerosol 0518 IGCM_comp_modifyDefFile nonblocker config.def flag_aerosol ${lmdz_UserChoices_flag_aerosol} 519 else 520 IGCM_comp_modifyDefFile nonblocker config.def flag_aerosol 0 578 521 fi 579 522 580 523 # config.def : Activate calcul of Cloud droplet number concentration if ok_cdnc=y 581 524 if [ ! X${lmdz_UserChoices_ok_cdnc} = X ]; then 582 LMDZ_sedconfig.def ok_cdnc ${lmdz_UserChoices_ok_cdnc}583 else 584 LMDZ_sedconfig.def ok_cdnc n525 IGCM_comp_modifyDefFile nonblocker config.def ok_cdnc ${lmdz_UserChoices_ok_cdnc} 526 else 527 IGCM_comp_modifyDefFile nonblocker config.def ok_cdnc n 585 528 fi 586 529 587 530 # guide.def : Activate nudging if ok_guide=y set in lmdz.card 588 531 if [ ! X${lmdz_UserChoices_ok_guide} = X ] ; then 589 LMDZ_sedguide.def ok_guide ${lmdz_UserChoices_ok_guide}590 else 591 LMDZ_sedguide.def ok_guide n532 IGCM_comp_modifyDefFile nonblocker guide.def ok_guide ${lmdz_UserChoices_ok_guide} 533 else 534 IGCM_comp_modifyDefFile nonblocker guide.def ok_guide n 592 535 fi 593 536 … … 741 684 if [ ${lmdz_UserChoices_CARBON_CYCLE} = historical ] ; then 742 685 # Modify co2_ppm in config.def only for historical run 743 # If not historical run, keep co2_ppm value set earlier by LMDZ_sed744 LMDZ_sedconfig.def co2_ppm ${CO2_ppm}686 # If not historical run, keep co2_ppm value set earlier by IGCM_comp_modifyDefFile 687 IGCM_comp_modifyDefFile nonblocker config.def co2_ppm ${CO2_ppm} 745 688 fi 746 689 IGCM_debug_PopStack "ATM_Carbon_Update"
Note: See TracChangeset
for help on using the changeset viewer.