Ignore:
Timestamp:
08/18/11 17:41:19 (11 years ago)
Author:
jgipsl
Message:

Modifications in working configuration :

Modifications in lmdz.card and lmdz.driver

  • GHG forcing files should now be copied in files with standard names such as CO2.txt, CH4.txt, N2O.txt, CFC11.txt and CFC12.txt. Now the

lmdz.driver will update the GHG parameters in physiq.def as soon as one
of theses files are added in lmdz.card.

  • removed CO2_1765_2005.txt from Chistorical/COMP/lmdz.card, the file is not used in this experience

Modifications in pisces.driver and pisces.card

  • add option CARBON_CYCLE=y to be set in pisces.card section UserChoices? for experience Chistorical and CpiControl?. With this option, co2 will

be read from co2.log file as before.

  • modified pisces.driver to read co2 from file CO2.txt if existing. As done in lmdz.driver
  • all pisces.driver are now the same
Location:
CONFIG/IPSLCM/IPSLCM5-2
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • CONFIG/IPSLCM/IPSLCM5-2/Chistorical/COMP/lmdz.card

    r1507 r1535  
    4343[BoundaryFiles] 
    4444List=       () 
    45 ListNonDel= (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/SOLARANDVOLCANOES_1610_2008.txt, .),\ 
    46             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CO2_1765_2005.txt, .),\ 
    47             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CH4_1765_2005.txt, .),\ 
    48             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/N2O_1765_2005.txt, .),\ 
    49             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC11_1765_2005.txt, .),\ 
    50             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC12_1765_2005.txt, .),\ 
     45ListNonDel= (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/SOLARANDVOLCANOES_1610_2008.txt, SOLARANDVOLCANOES.txt),\ 
     46            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CH4_1765_2005.txt, CH4.txt),\ 
     47            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/N2O_1765_2005.txt, N2O.txt),\ 
     48            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC11_1765_2005.txt, CFC11.txt),\ 
     49            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC12_1765_2005.txt, CFC12.txt),\ 
    5150            (${R_BC}/ATM/${config_UserChoices_TagName}/${RESOL_ATM}/AR5/HISTORIQUE/aerosols_11YearsClim_1855_v3.nc, aerosols.nat.nc) 
    5251 
  • CONFIG/IPSLCM/IPSLCM5-2/Chistorical/COMP/lmdz.driver

    r1316 r1535  
    153153    [ ${CumulPeriod} -gt 1 ] && ( IGCM_sys_Get ${R_OUT_ATM_D}/${config_UserChoices_JobName}_Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat_${RefPeriod} Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ; IGCM_sys_Chmod u+w Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ) 
    154154 
    155     ##-- GHG forcing for the current year 
    156     IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES_1610_2008.txt | awk -F= '{print $2}'` 
    157 #    IPCC_CO2=`grep Annee_${year} CO2_1765_2005.txt | awk -F= '{print $2}'` 
    158     IPCC_CH4=`grep Annee_${year} CH4_1765_2005.txt | awk -F= '{print $2}'` 
    159     IPCC_N2O=`grep Annee_${year} N2O_1765_2005.txt | awk -F= '{print $2}'` 
    160     IPCC_CFC11=`grep Annee_${year} CFC11_1765_2005.txt | awk -F= '{print $2}'` 
    161     IPCC_CFC12=`grep Annee_${year} CFC12_1765_2005.txt | awk -F= '{print $2}'` 
     155    ##-- GHG forcing : 
     156    ##   If forcing file exist in run directory, read values for the current year and modify physiq.def 
     157    if [ -f SOLARANDVOLCANOES.txt ] ; then 
     158        IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 
     159        LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
     160    fi 
     161    if [ -f CO2.txt ] ; then 
     162        IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     163        LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
     164    fi 
     165    if [ -f CH4.txt ] ; then 
     166        IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 
     167        LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
     168    fi 
     169    if [ -f N2O.txt ] ; then 
     170        IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 
     171        LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
     172    fi 
     173    if [ -f CFC11.txt ] ; then 
     174        IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 
     175        LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
     176    fi 
     177    if [ -f CFC12.txt ] ; then 
     178        IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 
     179        LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
     180    fi 
    162181 
    163182    if ( ${FirstInitialize} && [ X"${config_ATM_Restart}" = X"n" ]) ; then 
     
    243262    LMDZ_sed physiq.def ok_hfCOSP   ${LMDZ_COSP_hf} 
    244263    LMDZ_sed physiq.def ok_histNMC  "${LMDZ_NMC_monthly}, ${LMDZ_NMC_daily}, ${LMDZ_NMC_hf}" 
    245     LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
    246 #    LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
    247264    LMDZ_sed physiq.def co2_ppm     ${CO2_ppm} 
    248     LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
    249     LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
    250     LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
    251     LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
    252265 
    253266    ## gcm.def parameters : no change since gcm.def_${RESOL_ATM_3D} is used and already modified 
     
    348361    # Formula 
    349362    CO2_ppm=$( echo "${CO2_ppm_prec} + (${fCO2_ff} + ${CO2MBG} + ${CO2SBG}) / 2.12" | bc -l ) 
    350     echo "New CO2  :" ${CO2_ppm}  
     363    echo "New CO2  :" ${CO2_ppm} 
    351364 
    352365    # Save CO2 values in ExeCpuLog variable contents 5 fields 
  • CONFIG/IPSLCM/IPSLCM5-2/Chistorical/COMP/pisces.card

    r1437 r1535  
    44[UserChoices] 
    55DBIO_ENABLE=y 
     6CARBON_CYCLE=y 
    67 
    78[InitialStateFiles] 
  • CONFIG/IPSLCM/IPSLCM5-2/Chistorical/COMP/pisces.driver

    r1437 r1535  
    1010    grep "^ *$1 *=" $2 | sed -e "s% *\!.*%%" 
    1111} 
    12  
    1312 
    1413    ##--Variables used by MBG -- 
     
    7675    IGCM_sys_Mv iodef.xml.tmp iodef.xml 
    7776 
    78     ##-- GHG forcing for the current year. Normally constant 
    79     PathCO2log=${SUBMIT_DIR} 
    80     PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
    81     IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     77    ##-- CO2 forcing : update atcco2 value in namelist_pisces for some cases 
     78    if [ "${piseces_UserChoices_CARBON_CYCLE}" = "y" ]; then 
     79        # Special case for carbon cycle 
     80        # Activate this case by putting CARBON_CYCLE=y in pisces.card section UserChoices 
     81        echo 'Update atcco2 in namelist_pisces with value from file co2.log' 
     82        PathCO2log=${SUBMIT_DIR} 
     83        PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
     84        IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     85        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     86            namelist_pisces > namelist_pisces.tmp 
     87        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     88    elif [ -f CO2.txt ] ; then 
     89        # This case is activated if the file CO2.txt is found in run directory, add file in BoundaryFiles in pisces.card or lmdz.card 
     90        echo 'Update atcco2 in namelist_pisces with annual value from file CO2.txt' 
     91        IPCC_PIS_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     92        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     93            namelist_pisces > namelist_pisces.tmp 
     94        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     95    fi 
    8296 
    8397    ##-- Update namelist_top and namelist_pisces  
     
    89103    IGCM_sys_Mv namelist_top.tmp namelist_top 
    90104 
    91     sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"                \ 
    92         -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
     105    sed -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
    93106        namelist_pisces > namelist_pisces.tmp 
    94107 
    95     IGCM_sys_Mv namelist_pisces.tmp  namelist_pisces 
     108    IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
    96109 
    97110 
  • CONFIG/IPSLCM/IPSLCM5-2/CpiControl/COMP/lmdz.driver

    r1316 r1535  
    138138    [ ${CumulPeriod} -gt 1 ] && ( IGCM_sys_Get ${R_OUT_ATM_D}/${config_UserChoices_JobName}_Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat_${RefPeriod} Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ; IGCM_sys_Chmod u+w Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ) 
    139139 
    140      ##-- GHG forcing for the current year 
     140 
     141    ##-- GHG forcing : 
     142    ##   If forcing file exist in run directory, read values for the current year and modify physiq.def 
     143    if [ -f SOLARANDVOLCANOES.txt ] ; then 
     144        IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 
     145        LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
     146    fi 
     147    if [ -f CO2.txt ] ; then 
     148        IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     149        LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
     150    fi 
     151    if [ -f CH4.txt ] ; then 
     152        IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 
     153        LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
     154    fi 
     155    if [ -f N2O.txt ] ; then 
     156        IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 
     157        LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
     158    fi 
     159    if [ -f CFC11.txt ] ; then 
     160        IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 
     161        LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
     162    fi 
     163    if [ -f CFC12.txt ] ; then 
     164        IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 
     165        LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
     166    fi 
    141167 
    142168    if ( ${FirstInitialize} ) ; then 
  • CONFIG/IPSLCM/IPSLCM5-2/CpiControl/COMP/pisces.card

    r1437 r1535  
    44[UserChoices] 
    55DBIO_ENABLE=y 
     6CARBON_CYCLE=y 
    67 
    78[InitialStateFiles] 
  • CONFIG/IPSLCM/IPSLCM5-2/CpiControl/COMP/pisces.driver

    r1437 r1535  
    1010    grep "^ *$1 *=" $2 | sed -e "s% *\!.*%%" 
    1111} 
    12  
    13     ##--Variables used by OPA -- 
    14  
    1512 
    1613    ##--Variables used by MBG -- 
     
    7875    IGCM_sys_Mv iodef.xml.tmp iodef.xml 
    7976 
    80     ##-- GHG forcing for the current year. Normally constant 
    81     PathCO2log=${SUBMIT_DIR} 
    82     PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
    83     IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     77    ##-- CO2 forcing : update atcco2 value in namelist_pisces for some cases 
     78    if [ "${piseces_UserChoices_CARBON_CYCLE}" = "y" ]; then 
     79        # Special case for carbon cycle 
     80        # Activate this case by putting CARBON_CYCLE=y in pisces.card section UserChoices 
     81        echo 'Update atcco2 in namelist_pisces with value from file co2.log' 
     82        PathCO2log=${SUBMIT_DIR} 
     83        PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
     84        IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     85        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     86            namelist_pisces > namelist_pisces.tmp 
     87        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     88    elif [ -f CO2.txt ] ; then 
     89        # This case is activated if the file CO2.txt is found in run directory, add file in BoundaryFiles in pisces.card or lmdz.card 
     90        echo 'Update atcco2 in namelist_pisces with annual value from file CO2.txt' 
     91        IPCC_PIS_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     92        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     93            namelist_pisces > namelist_pisces.tmp 
     94        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     95    fi 
    8496 
    8597    ##-- Update namelist_top and namelist_pisces  
     
    91103    IGCM_sys_Mv namelist_top.tmp namelist_top 
    92104 
    93     sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"                \ 
    94         -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
     105    sed -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
    95106        namelist_pisces > namelist_pisces.tmp 
    96107 
  • CONFIG/IPSLCM/IPSLCM5-2/EXP00/COMP/lmdz.driver

    r1172 r1535  
    134134 
    135135    [ ${CumulPeriod} -gt 1 ] && ( IGCM_sys_Get ${R_OUT_ATM_D}/${config_UserChoices_JobName}_Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat_${RefPeriod} Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ; IGCM_sys_Chmod u+w Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ) 
     136 
     137    ##-- GHG forcing : 
     138    ##   If forcing file exist in run directory, read values for the current year and modify physiq.def 
     139    if [ -f SOLARANDVOLCANOES.txt ] ; then 
     140        IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 
     141        LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
     142    fi 
     143    if [ -f CO2.txt ] ; then 
     144        IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     145        LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
     146    fi 
     147    if [ -f CH4.txt ] ; then 
     148        IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 
     149        LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
     150    fi 
     151    if [ -f N2O.txt ] ; then 
     152        IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 
     153        LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
     154    fi 
     155    if [ -f CFC11.txt ] ; then 
     156        IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 
     157        LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
     158    fi 
     159    if [ -f CFC12.txt ] ; then 
     160        IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 
     161        LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
     162    fi 
    136163 
    137164    ## physiq.def parameters modified from initial physiq_L${RESOL_ATM_Z} 
  • CONFIG/IPSLCM/IPSLCM5-2/EXP00/COMP/pisces.driver

    r1437 r1535  
    1111} 
    1212 
    13     ##--Variables used by OPA -- 
    14  
    15  
    1613    ##--Variables used by MBG -- 
    1714 
     
    2320    PAT_TOP_LRSTTR=$( supergrep ln_rsttr          ${SUBMIT_DIR}/PARAM/namelist_top_${RESOL_OCE} ) 
    2421    PAT_TOP_NRSTTR=$( supergrep nrsttr            ${SUBMIT_DIR}/PARAM/namelist_top_${RESOL_OCE} ) 
     22    PAT_PIS_ATCCO2=$( supergrep atcco2            ${SUBMIT_DIR}/PARAM/namelist_pisces_${RESOL_OCE} ) 
    2523    PAT_PIS_LRIVER=$( supergrep ln_river          ${SUBMIT_DIR}/PARAM/namelist_pisces_${RESOL_OCE} ) 
    2624 
     
    7775    IGCM_sys_Mv iodef.xml.tmp iodef.xml 
    7876 
     77    ##-- CO2 forcing : update atcco2 value in namelist_pisces for some cases 
     78    if [ "${piseces_UserChoices_CARBON_CYCLE}" = "y" ]; then 
     79        # Special case for carbon cycle 
     80        # Activate this case by putting CARBON_CYCLE=y in pisces.card section UserChoices 
     81        echo 'Update atcco2 in namelist_pisces with value from file co2.log' 
     82        PathCO2log=${SUBMIT_DIR} 
     83        PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
     84        IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     85        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     86            namelist_pisces > namelist_pisces.tmp 
     87        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     88    elif [ -f CO2.txt ] ; then 
     89        # This case is activated if the file CO2.txt is found in run directory, add file in BoundaryFiles in pisces.card or lmdz.card 
     90        echo 'Update atcco2 in namelist_pisces with annual value from file CO2.txt' 
     91        IPCC_PIS_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     92        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     93            namelist_pisces > namelist_pisces.tmp 
     94        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     95    fi 
     96 
    7997    ##-- Update namelist_top and namelist_pisces  
    8098 
  • CONFIG/IPSLCM/IPSLCM5-2/historical/COMP/lmdz.card

    r1507 r1535  
    4141[BoundaryFiles] 
    4242List=       () 
    43 ListNonDel= (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/SOLARANDVOLCANOES_1610_2008.txt, .),\ 
    44             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CO2_1765_2005.txt, .),\ 
    45             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CH4_1765_2005.txt, .),\ 
    46             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/N2O_1765_2005.txt, .),\ 
    47             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC11_1765_2005.txt, .),\ 
    48             (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC12_1765_2005.txt, .),\ 
     43ListNonDel= (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/SOLARANDVOLCANOES_1610_2008.txt, SOLARANDVOLCANOES.txt),\ 
     44            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CO2_1765_2005.txt, CO2.txt),\ 
     45            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CH4_1765_2005.txt, CH4.txt),\ 
     46            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/N2O_1765_2005.txt, N2O.txt),\ 
     47            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC11_1765_2005.txt, CFC11.txt),\ 
     48            (${R_BC}/ATM/${config_UserChoices_TagName}/IPCC_AR5/HISTORIQUE/CFC12_1765_2005.txt, CFC12.txt),\ 
    4949            (${R_BC}/ATM/${config_UserChoices_TagName}/${RESOL_ATM}/AR5/HISTORIQUE/aerosols_11YearsClim_1855_v3.nc, aerosols.nat.nc) 
    5050 
  • CONFIG/IPSLCM/IPSLCM5-2/historical/COMP/lmdz.driver

    r1172 r1535  
    149149    [ ${CumulPeriod} -gt 1 ] && ( IGCM_sys_Get ${R_OUT_ATM_D}/${config_UserChoices_JobName}_Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat_${RefPeriod} Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ; IGCM_sys_Chmod u+w Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ) 
    150150 
    151     ##-- GHG forcing for the current year 
    152     IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES_1610_2008.txt | awk -F= '{print $2}'` 
    153     IPCC_CO2=`grep Annee_${year} CO2_1765_2005.txt | awk -F= '{print $2}'` 
    154     IPCC_CH4=`grep Annee_${year} CH4_1765_2005.txt | awk -F= '{print $2}'` 
    155     IPCC_N2O=`grep Annee_${year} N2O_1765_2005.txt | awk -F= '{print $2}'` 
    156     IPCC_CFC11=`grep Annee_${year} CFC11_1765_2005.txt | awk -F= '{print $2}'` 
    157     IPCC_CFC12=`grep Annee_${year} CFC12_1765_2005.txt | awk -F= '{print $2}'` 
     151    ##-- GHG forcing : 
     152    ##   If forcing file exist in run directory, read values for the current year and modify physiq.def 
     153    if [ -f SOLARANDVOLCANOES.txt ] ; then 
     154        IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 
     155        LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
     156    fi 
     157    if [ -f CO2.txt ] ; then 
     158        IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     159        LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
     160    fi 
     161    if [ -f CH4.txt ] ; then 
     162        IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 
     163        LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
     164    fi 
     165    if [ -f N2O.txt ] ; then 
     166        IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 
     167        LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
     168    fi 
     169    if [ -f CFC11.txt ] ; then 
     170        IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 
     171        LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
     172    fi 
     173    if [ -f CFC12.txt ] ; then 
     174        IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 
     175        LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
     176    fi 
    158177 
    159178    ##-- For historical daily cosp must be output during 1979-2005 period 
     
    173192    LMDZ_sed physiq.def ok_hfCOSP   ${LMDZ_COSP_hf} 
    174193    LMDZ_sed physiq.def ok_histNMC  "${LMDZ_NMC_monthly}, ${LMDZ_NMC_daily}, ${LMDZ_NMC_hf}" 
    175     LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
    176     LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
    177     LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
    178     LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
    179     LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
    180     LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
    181194 
    182195    ## gcm.def parameters : no change since gcm.def_${RESOL_ATM_3D} is used and already modified 
  • CONFIG/IPSLCM/IPSLCM5-2/historical/COMP/pisces.driver

    r1437 r1535  
    7575    IGCM_sys_Mv iodef.xml.tmp iodef.xml 
    7676 
    77     ##-- GHG forcing for the current year 
    78     IPCC_PIS_CO2=`grep Annee_${year} CO2_1765_2005.txt | awk -F= '{print $2}'` 
     77    ##-- CO2 forcing : update atcco2 value in namelist_pisces for some cases 
     78    if [ "${piseces_UserChoices_CARBON_CYCLE}" = "y" ]; then 
     79        # Special case for carbon cycle 
     80        # Activate this case by putting CARBON_CYCLE=y in pisces.card section UserChoices 
     81        echo 'Update atcco2 in namelist_pisces with value from file co2.log' 
     82        PathCO2log=${SUBMIT_DIR} 
     83        PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
     84        IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     85        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     86            namelist_pisces > namelist_pisces.tmp 
     87        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     88    elif [ -f CO2.txt ] ; then 
     89        # This case is activated if the file CO2.txt is found in run directory, add file in BoundaryFiles in pisces.card or lmdz.card 
     90        echo 'Update atcco2 in namelist_pisces with annual value from file CO2.txt' 
     91        IPCC_PIS_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     92        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     93            namelist_pisces > namelist_pisces.tmp 
     94        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     95    fi 
    7996 
    8097    ##-- Update namelist_top and namelist_pisces  
     
    86103    IGCM_sys_Mv namelist_top.tmp namelist_top 
    87104 
    88     sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"                \ 
    89         -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
     105    sed -e "s%${PAT_PIS_LRIVER}%          ln_river=${PISCES_LRIVER}%"                \ 
    90106        namelist_pisces > namelist_pisces.tmp 
    91107 
  • CONFIG/IPSLCM/IPSLCM5-2/piControl/COMP/lmdz.driver

    r1172 r1535  
    134134 
    135135    [ ${CumulPeriod} -gt 1 ] && ( IGCM_sys_Get ${R_OUT_ATM_D}/${config_UserChoices_JobName}_Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat_${RefPeriod} Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ; IGCM_sys_Chmod u+w Bands_${RESOL_ATM_3D}_${NUM_PROC_ATM}prc.dat ) 
     136 
     137    ##-- GHG forcing : 
     138    ##   If forcing file exist in run directory, read values for the current year and modify physiq.def 
     139    if [ -f SOLARANDVOLCANOES.txt ] ; then 
     140        IPCC_SOLAR=`grep Annee_${year} SOLARANDVOLCANOES.txt | awk -F= '{print $2}'` 
     141        LMDZ_sed physiq.def solaire     ${IPCC_SOLAR} 
     142    fi 
     143    if [ -f CO2.txt ] ; then 
     144        IPCC_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     145        LMDZ_sed physiq.def co2_ppm     ${IPCC_CO2} 
     146    fi 
     147    if [ -f CH4.txt ] ; then 
     148        IPCC_CH4=`grep Annee_${year} CH4.txt | awk -F= '{print $2}'` 
     149        LMDZ_sed physiq.def CH4_ppb     ${IPCC_CH4} 
     150    fi 
     151    if [ -f N2O.txt ] ; then 
     152        IPCC_N2O=`grep Annee_${year} N2O.txt | awk -F= '{print $2}'` 
     153        LMDZ_sed physiq.def N2O_ppb     ${IPCC_N2O} 
     154    fi 
     155    if [ -f CFC11.txt ] ; then 
     156        IPCC_CFC11=`grep Annee_${year} CFC11.txt | awk -F= '{print $2}'` 
     157        LMDZ_sed physiq.def CFC11_ppt   ${IPCC_CFC11} 
     158    fi 
     159    if [ -f CFC12.txt ] ; then 
     160        IPCC_CFC12=`grep Annee_${year} CFC12.txt | awk -F= '{print $2}'` 
     161        LMDZ_sed physiq.def CFC12_ppt   ${IPCC_CFC12} 
     162    fi 
    136163 
    137164    ## physiq.def parameters modified from initial physiq_L${RESOL_ATM_Z} 
  • CONFIG/IPSLCM/IPSLCM5-2/piControl/COMP/pisces.driver

    r1437 r1535  
    1111} 
    1212 
    13     ##--Variables used by OPA -- 
    14  
    15  
    1613    ##--Variables used by MBG -- 
    1714 
     
    2320    PAT_TOP_LRSTTR=$( supergrep ln_rsttr          ${SUBMIT_DIR}/PARAM/namelist_top_${RESOL_OCE} ) 
    2421    PAT_TOP_NRSTTR=$( supergrep nrsttr            ${SUBMIT_DIR}/PARAM/namelist_top_${RESOL_OCE} ) 
     22    PAT_PIS_ATCCO2=$( supergrep atcco2            ${SUBMIT_DIR}/PARAM/namelist_pisces_${RESOL_OCE} ) 
    2523    PAT_PIS_LRIVER=$( supergrep ln_river          ${SUBMIT_DIR}/PARAM/namelist_pisces_${RESOL_OCE} ) 
    2624 
     
    7775    IGCM_sys_Mv iodef.xml.tmp iodef.xml 
    7876 
     77    ##-- CO2 forcing : update atcco2 value in namelist_pisces for some cases 
     78    if [ "${piseces_UserChoices_CARBON_CYCLE}" = "y" ]; then 
     79        # Special case for carbon cycle 
     80        # Activate this case by putting CARBON_CYCLE=y in pisces.card section UserChoices 
     81        echo 'Update atcco2 in namelist_pisces with value from file co2.log' 
     82        PathCO2log=${SUBMIT_DIR} 
     83        PreviousLinelog=$( tail -1 ${PathCO2log}/co2.log ) 
     84        IPCC_PIS_CO2=$( echo "${PreviousLinelog[*]}" | gawk -F '|' '{gsub(" ",""); print $4}' ) 
     85        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     86            namelist_pisces > namelist_pisces.tmp 
     87        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     88    elif [ -f CO2.txt ] ; then 
     89        # This case is activated if the file CO2.txt is found in run directory, add file in BoundaryFiles in pisces.card or lmdz.card 
     90        echo 'Update atcco2 in namelist_pisces with annual value from file CO2.txt' 
     91        IPCC_PIS_CO2=`grep Annee_${year} CO2.txt | awk -F= '{print $2}'` 
     92        sed -e "s%${PAT_PIS_ATCCO2}%          atcco2=${IPCC_PIS_CO2}%"             \ 
     93            namelist_pisces > namelist_pisces.tmp 
     94        IGCM_sys_Mv namelist_pisces.tmp namelist_pisces 
     95    fi 
     96 
    7997    ##-- Update namelist_top and namelist_pisces  
    8098 
Note: See TracChangeset for help on using the changeset viewer.