WRFCHEM CBE A1
2014-09-08
###WRF CHEM for Coimbatore A1 using ndown.exe###
####WPS#### 1. The WPS components geogrid.exe, ungrib.exe and metgrid.exe was from the output of last run on detailed in this
####real.exe#### 1. Real.exe also from the last run output. The output comprised of files namely wrfbdyd01, wrfinputd01, wrfinputd02, wrfinputd03, wrfinputd04 were used as such for convertemiss.exe run.
####PrepChemSrc.exe####
1. It was executed as per the tutorial and PrepChemSrc.exe was executed by following point 3 in that tutorial.
2. The input file for PrepChemSrc.exe named as PrepChemSrc.inp is edited following namelist.wps last run based on emissioninventoryguide, it has option for nesting also by choosing number of grids and for CBE case by entering four grids. The used inp file is this. After editing inp file PrepChemSrc.exe was run by ./Prep_Chem_Src.exe
command in its bin folder. It run successfully as specified in the tutorial and it created seven files with three bin files for each grid as per the tutorial. Earlier attempt failed by an un recognized error message and it was then resolved by editing a mistake in the inp file with two dots in variables such as POLELAT
.
3. The created bin files are linked inside the emreal folder of wrf serial compile is made by the commands as per the [emissioninventoryguide](http://ruc.noaa.gov/wrf/WG11/Emissionguide.pdf). But the command creates broken link, the command has to changed as per below and executed from real_em folder
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-ab.bin emissopt3_d01
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-bb.bin emissfire_d01
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-gocartBG.bin wrf_gocart_backg_d01
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-ab.bin emissopt3_d02
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-bb.bin emissfire_d02
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-gocartBG.bin wrf_gocart_backg_d02
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-ab.bin emissopt3_d03
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-bb.bin emissfire_d03
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-gocartBG.bin wrf_gocart_backg_d03
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-ab.bin emissopt3_d04
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-bb.bin emissfire_d04
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-gocartBG.bin wrf_gocart_backg_d04
As different from emissguide wrfgocartbackg was given domain identifier for maintaining convention of executing convertemiss.exe as wrfgocartbackg_d01.
####convertemiss.exe####
1. Nesting is not enabled with convertemiss.exe as per this. So each nesting has to be run by changing the namelist.input and considering as single domain. So the namelist.input used in last DUSTONLY simulation was edited based on emissioninventoryguide page number 8 and 9. The namelist was renamed as namelist.input_CE_do1
for distinguishing domains. File name for wrfgocartbackg_d01 was renamed into wrfgocartbackg and then executed convertemiss.exe by ./convert_emiss.exe
1. Convert_emiss.exe run for sometime end abruptly with following lines,
Number of fire emissions: 37
FIRE EMISSIONS INPUT FILE TIME PERIOD (GMT): -1 TO 0
NOW OPEN FILE FOR WRITE: wrffirechemi_d01
FIRE EMISSIONS OUTPUT file name: wrffirechemi_d01
EMISSIONS CONVERSION : end of program
but it created three files as specified in the tutorial. It was rechecked with m2lab ncview and made sure that some emission inventory are there. Some doubts in fire emiss other than all are normal, firechemi all variables are blank it seems.
####real.exe#### 1. After convertemiss.exe again real.exe was executed with the same namelist.input and end with succeful completion and creation of wrfinput and wrfbdy files. ####wrf.exe for D01#### 1. With this the wrf.exe was run using this [namelist](namelist.inputCE_d01) and it ends with error saying that
FATAL CALLED FROM FILE: <stdin> LINE: 826
... Could not find matching time in input file wrfchemi_gocart_bg_d01
-------------------------------------------
this error problem was latter solved by correcting the namelist as per the earlier emission inventory tutorial namelist. the used namelsit was this and all former steps real.exe, convert_emiss.exe, and rea.exe was rerun for requiered input files for wrf.exe . Using that namelist solved the last error on wrf.exe but it ends with new error as below
Timing for processing lateral boundary for domain 1: 0.14533 elapsed seconds
WRF TILE 1 IS 1 IE 90 JS 1 JE 85
WRF NUMBER OF TILES = 1
1 40
Segmentation fault (core dumped)
- The error segmentation fault seems to be a error due to large domain size as compared to last successful emission inventory tutorial. So the domain two of the current namelist is executed to check the last assumption.
Made soft link for prepchemsrc outputs for grid 2 that is for domain 2.
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-ab.bin emissopt3_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-bb.bin emissfire_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-gocartBG.bin wrf_gocart_backg
Edited namelist for moving the second domain as main first domain and run real.exe and it ends with error indicating mismatch with metem domain size. So the domain 2 metem file was soft linked and its name was changed as of domain one
ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d02.2014-06-05_03:00:00.nc . ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d02.2014-06-05_06:00:00.nc .
Then run the real.exe with this namelist making chemopt=0 and resolution into 9000 as of metem file. it ran and created input and bdy file, with this convertemiss.exe was run with this [namelist](namelist.inputCE_03), using real.exe namelist ends in creation of only wrfchemi no other chemi files. But used this namelist, it created all chemi files.
Reused the last used namelist and edited chem_opt=301 and run real.exe, it created bdy and input file, then wrf.exe it worked without memroy error, making certain thaat problem is with large domain running wrf.exe.
Based on this page, it is expected that the error might be due to difference in namelist.input, so the current namelist.input was edited to consider this by comapring it with emissTut namelist. The edited namelist was this. But running wrf.exe return error of
FATAL CALLED FROM FILE: <stdin> LINE: 780 input_wrf.F: SIZE MISMATCH: namelist ide,jde,kde= 90 85 31 ; input data ide,jde,kde= 90 85 36 -------------------------------------------
Indicating staring from real.exe has to run again.
Emiss files are linked by this command
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-ab.bin emissopt3_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-bb.bin emissfire_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g1-gocartBG.bin wrf_gocart_backg
Used this namelist for real.exe and this namelist for convert_emiss.exe. It created input and bdy condition files without any error. 1. With namelist wrf.exe was run and it was running without any error, it took 3:15 hours to simulated do1 for 6 hours.
####Ndown for DO2#### 1. Pre step for Ndown.exe is to have wrfinput file named as wrfndid02 for domain 02. So has to run the real.exe with all emiss input file and create wrfinput01 and wrfbdy01. For this the namelist was edited and used this [namelist](namelist.inputD02). The prepchemsrc link was made and run real.exe.
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-ab.bin emissopt3_d01
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-bb.bin emissfire_d01
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g2-gocartBG.bin wrf_gocart_backg
- Then executed real.exe with chemopt=0 in the namelist.input for wrfinputd01 and wrfbdy_d01, the metfiles for doiman d02 was changed into d01 for this. It created files as required.
- These files are used for running convertemiss.exe, by using this [namelist.input](namelist.inputCED02) file for specifically to create three chmei files created by the program. This resulted in creation of required files such as wrffirechemid01, wrfchemigocartbgd01 and wrfchemid01.
- Then executed the real.exe using this namelist.input and it created two files of wrfinputd01 and wrfbdyd01 with files size 59.4MB and 54.6MB respectively. The files were renamed into wrfndid02 and wrfbdyd01_D02 respectively.
- Using maxdom=2 [namelist](namelist.inputNdownD01D02) for d01 and do2, then executed the ndown.exe. It created two files namely wrfinputd02 and wrfbdyd02 with files size of 15.7MB and 7.9MB respectively. The files makes to worry about the correctness of this procedure, since the input files are 50MB in range.
- Then executed the wrf.exe using this namelist.input. it was succeffully intiatied. But forget to rename the wrf output of domain 01, the 00:00:00 file was replaced. It took 1 hour 20 minutes to run a single hour simulation. Considering this huge time requirement, the files are transfered to parallel compiled wrf and executed with 3 cores by tis command
mpirun -np 3 -host localhost ./wrf.exe
, it considerably reduced the simulation time from 1 hour 20 minutes to 14 minutes for single hour simulation, this stands as astonishing achievement of parallel programming experienced by me.
####Ndown for DO3#### 1. Edited the last used namelist for single domain D02 for current domain D03. Changed chemopt=301 into chemopt=0 and renamed the metfiles into d01 domain from d03 and made link for non available time metfiles as follows
ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d03.2014-06-05_03:00:00.nc .
ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d03.2014-06-05_06:00:00.nc .
- Then executed real.exe and created wrfinputd01 and wrfbdyd01 with file size of 31MB and 11MB respectively.
The prepchemsrc files are linked by
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-ab.bin emissopt3_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-bb.bin emissfire_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g3-gocartBG.bin wrf_gocart_backg
These files are used for running convertemiss.exe, by using this [namelist.input](namelist.inputCED03) file for specifically to create three chmei files created by the program. This resulted in creation of required files such as wrffirechemid01, wrfchemigocartbgd01 and wrfchemid01.
Then executed the real.exe using this namelist.input with chemopt=301 and it created two files of wrfinputd01 and wrfbdyd01 with files size 110MB and 75MB respectively. The files were renamed into wrfndid03 and wrfbdyd01D03 respectively.
Using maxdom=2 [namelist](namelist.inputNdownD02D03 ) for d02 and do3, then executed the ndown.exe. It created two files namely wrfinputd02 and wrfbdyd02 with files size of 29MB and 10MB respectively.
Then executed the wrf.exe using this namelist.input by changing chemopt into 301 and changing into wrfinputd01, wrfbdy_d01. it was successfully initiated. It took whooping 8 hours to simulate (from 11:43PM to 7:45 PM) with 3 core parallel processing for a six hour simulation. it create 112MB files for each hour wrfoutput.
####Ndown for DO4#### 1. Edited the last used namelist for single domain D03 for current domain D04. Changed chemopt=301 into chemopt=0 and renamed the metfiles into d01 domain from d03 and made link for non available time metfiles as follows
ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d04.2014-06-05_03:00:00.nc .
ln -sf /home/swl-sacon-dst/wrf/WRF341/WRF_CHEM_trails/CBE_dustonly/WPS/met_em.d04.2014-06-05_06:00:00.nc .
- Then executed real.exe and created wrfinputd01 and wrfbdyd01 with file size of 64.6MB and 15.6MB respectively.
The prepchemsrc files are linked by
ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-ab.bin emissopt3_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-bb.bin emissfire_d01 ln -sf /home/swl-sacon-dst/wrf/WRF341/PREP-CHEM-SRC-1.4_1/bin/FIRE-RRCH-T-2014-06-05-000000-g4-gocartBG.bin wrf_gocart_backg
These files are used for running convertemiss.exe, by using this [namelist.input](namelist.inputCED04) file for specifically to create three chmei files created by the program. This resulted in creation of required files such as wrffirechemid01, wrfchemigocartbgd01 and wrfchemid01.
- Then executed the real.exe using this namelist.input with chemopt=301 and it created two files of wrfinputd01 and wrfbdyd01 with files size 231MB and 107MB respectively. The files were renamed into wrfndid02 and wrfbdyd01D03 respectively.
- Then executed the real.exe using this namelist.input with chemopt=301 and it created two files of wrfinputd01 and wrfbdyd01 with files size 231MB and 107MB respectively. The files were renamed into wrfndid02 and wrfbdyd01D03 respectively.
Using maxdom=2 [namelist](namelist.inputNdownD02D03 ) for d02 and do3, then executed the ndown.exe. It created two files namely wrfinputd02 and wrfbdyd02 with files size of 61MB and 15MB respectively.
Then executed the wrf.exe using this namelist.input by changing chemopt into 301 and changing into wrfinputd01, wrfbdyd01. Files such as wrfinputd01, wrfbdyd01, wrffirechemid01, wrfchemigocartbgd01, wrfchemid01 and namelist was copied inside parallel compiled wrf test/em_real folder