Changeset 3928
- Timestamp:
- 06/21/18 09:35:33 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TOOLS/CMIP6_FORCING/GHG/extract_scenario_v.1.2.0.sh
r3926 r3928 33 33 do 34 34 35 rep=${scenario}'/' 36 35 37 if [ ${scenario} == 'ssp119' ] ; then prefixe='IMAGE' ; fi 36 38 if [ ${scenario} == 'ssp126' ] ; then prefixe='IMAGE' ; fi … … 51 53 if [ ${scenario} == 'ssp585' ] ; then suffixe='' ; fi 52 54 55 if [ ! -d ${dirout}${rep} ] ; then mkdir -p ${dirout}${rep} ; fi 53 56 54 57 #--N2O we leave unit to ppb … … 60 63 rm -f tmp.txt ${dirout}${GHG}_CMIP6_${scenario}_2015_2500.txt 61 64 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 62 paste years.txt tmp.txt > ${dirout}${ GHG}_CMIP6_${scenario}_2015_2500.txt65 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_CMIP6_2015_2500.txt 63 66 64 67 #--CH4 here we leave unit in ppb … … 70 73 rm -f tmp.txt ${dirout}${GHG}_CMIP6_${scenario}_2015_2500.txt 71 74 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 72 paste years.txt tmp.txt > ${dirout}${ GHG}_CMIP6_${scenario}_2015_2500.txt75 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_CMIP6_2015_2500.txt 73 76 74 77 #--CO2 here we leave unit in ppm … … 80 83 rm -f tmp.txt ${dirout}${GHG}_CMIP6_${scenario}_2015_2500.txt 81 84 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 82 paste years.txt tmp.txt > ${dirout}${ GHG}_CMIP6_${scenario}_2015_2500.txt85 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_CMIP6_2015_2500.txt 83 86 84 87 #--CFC11eq we leave in pptv … … 91 94 rm -f tmp.txt ${dirout}${GHG}_${scenario}_2015_2500.txt 92 95 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 93 paste years.txt tmp.txt > ${dirout}${ GHG}_${scenario}_2015_2500.txt96 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_2015_2500.txt 94 97 95 98 #--CFC12eq we leave in pptv … … 101 104 rm -f tmp.txt ${dirout}${GHG}_${scenario}_2015_2500.txt ${dirout}/${GHG}_CMIP6_${scenario}_2015_2500.txt 102 105 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 103 paste years.txt tmp.txt > ${dirout}${ GHG}_${scenario}_2015_2500.txt106 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_2015_2500.txt 104 107 #--we will use CFC12eq for CMIP6 105 cp ${dirout} /${GHG}_${scenario}_2015_2500.txt ${dirout}/${GHG}_CMIP6_${scenario}_2015_2500.txt108 cp ${dirout}${rep}${GHG}_2015_2500.txt ${dirout}${rep}${GHG}_CMIP6_2015_2500.txt 106 109 107 110 #--CFC11 we leave in pptv … … 114 117 rm -f tmp.txt ${dirout}${GHG}_${scenario}_2015_2500.txt 115 118 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 116 paste years.txt tmp.txt > ${dirout}${ GHG}_${scenario}_2015_2500.txt119 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_2015_2500.txt 117 120 118 121 #--CFC12 we leave in pptv … … 125 128 rm -f tmp.txt ${dirout}${GHG}_${scenario}_2015_2500.txt 126 129 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 127 paste years.txt tmp.txt > ${dirout}${ GHG}_${scenario}_2015_2500.txt130 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_2015_2500.txt 128 131 129 132 #--HFC134aeq we leave in pptv … … 135 138 rm -f tmp.txt ${dirout}${GHG}_${scenario}_2015_2500.txt ${dirout}/CFC11eq_CMIP6_${scenario}_2015_2500.txt 136 139 cdo outputf,%12.4e,3 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 137 paste years.txt tmp.txt > ${dirout}${ GHG}_${scenario}_2015_2500.txt140 paste years.txt tmp.txt > ${dirout}${rep}${GHG}_2015_2500.txt 138 141 #--HFC134a-eq converted to CFC11-eq for CMIP6 139 142 #--by multiplying by (0.0100/62.7)/(0.062/238)=0.6122344 140 cdo outputf,%12.4e,3 -mulc,0.6122344 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin} /${file} | awk '{print $1}' > tmp.txt141 paste years.txt tmp.txt > ${dirout} CFC11eq_CMIP6_${scenario}_2015_2500.txt143 cdo outputf,%12.4e,3 -mulc,0.6122344 -selvar,'mole_fraction_of_'${namevar}'_in_air' ${dirin}${file} | awk '{print $1}' > tmp.txt 144 paste years.txt tmp.txt > ${dirout}${rep}CFC11eq_CMIP6_2015_2500.txt 142 145 143 146 done
Note: See TracChangeset
for help on using the changeset viewer.