Working with WRF CHEM part63 WRF CoimbatoreNesting
2014-08-19
##Trail for WRF-CHEM, WRF simulation with domain for Coimbatore and one-way Nesting-Ndown.exe## 1. The trail is based on this page to run compiled WRF in serial mode to execute domain over Coimbatore. Trying the nested model run by Ndown.exe using one-way nesting.
###WPS: Ungrib###
- The WPS ungrib stage was carried out as per page,
- The gfs files downloaded used, average size around 45MB for each file. The data for period 00,03, 06 was kept under a folder gfs.
- The vtable was linked inside WPS folder by
ln -sf ungrib/Variable_Tables/Vtable.GFS Vtable
. The GFS files inside the gfs folder are linked with WPS folder by
./link_grib.csh /wrf/WRF341/coimbatore/gfs/
. Following files with links were created by the command inside WPS folder.GRIBFILE.AAA -> /home/swl-sacon-dst/wrf/WRF341/coimbatore/gfs/14060500.gfs.t00z.pgrb2f00 GRIBFILE.AAB -> /home/swl-sacon-dst/wrf/WRF341/coimbatore/gfs/14060500.gfs.t00z.pgrb2f03 GRIBFILE.AAC -> /home/swl-sacon-dst/wrf/WRF341/coimbatore/gfs/14060500.gfs.t00z.pgrb2f06
Edited the namelist.wps in WPS folder and the file becomes
&share max_dom = 4, start_date =
‘2014-06-0500:00:00’,‘2014-06-0500:00:00’,‘2014-06-0500:00:00’,‘2014-06-0500:00:00’ enddate = ‘2014-06-0506:00:00’,‘2014-06-0506:00:00’,‘2014-06-0506:00:00’,‘2014-06-0506:00:00’ intervalseconds = 10800, ioformgeogrid = 2, / &metgrid fgname = ‘FILE’ ioform_metgrid = 2, /
The ungrib.exe was run using this command
./ungrib.exe >& ungrib_data.log
, the log file says successful completion of the ungrib.
###WPS:Geogrid###
- This part of the tutorial based on the page
For the geogrid part of WPS, geogrid section from namelist.wps EMS run used. The namelist.wps becomes
&share max_dom = 4, start_date ='2014-06-05_00:00:00','2014-06-05_00:00:00','2014-06-05_00:00:00','2014-06-05_00:00:00' end_date =
‘2014-06-0506:00:00’,‘2014-06-0506:00:00’,‘2014-06-0506:00:00’,‘2014-06-0506:00:00’ intervalseconds = 10800, ioform_geogrid = 2, /
&geogrid parent_id = 1, 1, 2, 3 parent_grid_ratio = 1, 3, 3, 3 i_parent_start = 1, 26, 22, 22 j_parent_start = 1, 7, 15, 32 e_we = 90, 76, 97, 136 e_sn = 85, 73, 106, 157 geog_data_res = '10m', '5m', '30s', '30s' dx = 27000 dy = 27000 map_proj = 'lambert' ref_lat = 18.363 ref_lon = 78.925 truelat1 = 18.363 truelat2 = 18.363 stand_lon = 78.925 ref_x = 45 ref_y = 42.5 geog_data_path = '/home/hoopoe/ems/wrfems/data/geog' / &metgrid fg_name = 'FILE' io_form_metgrid = 2,
/ star/end date, maxdom, intervalseconds were edited to suite the coimbatore domian. The coimbatore domain was visualised using
ncdump -h
and it is as.
With this the geogrid was executed by
./geogrid.exe
and ended with successful completion and following files was created.geo_em.d01.nc geo_em.d02.nc geo_em.d03.nc geo_em.d04.nc
###WPS:Metgrid###
14. The part follows the page
15. For the metgrid part of WPS, as per the tutorial page, the content was checked for namelist.wps and kept as such of geogrid.exe namelist.
16. Then the metgrid was executed by ./metgrid.exe
and it ended with successful completion and creation of following nc files for domains 1 to 4 as per the tutorial page.
metem.d01.2014-06-0500:00:00.nc
metem.d01.2014-06-0503:00:00.nc
metem.d01.2014-06-0506:00:00.nc
metem.d02.2014-06-0500:00:00.nc
metem.d02.2014-06-0503:00:00.nc
metem.d02.2014-06-0506:00:00.nc
metem.d03.2014-06-0500:00:00.nc
metem.d03.2014-06-0503:00:00.nc
metem.d03.2014-06-0506:00:00.nc
metem.d04.2014-06-0500:00:00.nc
metem.d04.2014-06-0503:00:00.nc
metem.d04.2014-06-0506:00:00.nc
###WRF:real.exe for first domain 01###
- Based on the page
For making WRF run the folder content from
WRFV3_serial/test/em_real
was used as such and all the met files are linked inside the em_real folder using the commandln -sf /home/swl-sacon-dst/wrf/WRF341/coimbatore/WPS/met_em* .
For the real.exe part of WRF WITH NESTING NDOWN, following namelist.input was used based on WRF ems namelist.real and edited as per the tutorial page to suit the domain of Coimbatore case with first Do1 domain and the namelsit.input is this [file](
The namelist of wrf EMS was suited with tutorial page namelist.input and whatever variables not available in the namelist.input was removed and matched as much as with later. Changes or addition made specifically on variable was on &dynamics:basetemp, nonhydrostatic , on &bdy_control:specified, nested. The namelist.input based on WRF EMS with 230 lines was cut short into 109 lines with this editing.
Resultant [namelist] was used to run the first domain and it run with successful completion and creation of files
wrfinput_d01, wrfbdy_d01
With file size of 20.6MB, and 10.8 MB respectively.
###WRF:wrf.exe for DO1###
- Then run
./wrf.exe
and it was executed correctly and produced one file with file name ofwrfout_d01_2014-06-05_00:00:00
with file size of 1.2GB.
###WRF:ndown.exe:making temporary fine grid initial condition- Domain 02###
14. This part of trail is based on the page
15. The metfiles created in inital WPS was renamed to consider do2 as do1
20. For fresh real.exe to run, the namelist.input dO2 details used and all other details are nullified by making max_dom=1. The final namelist for domain 02 is this [file]
21. The real.exe got run and it produced two files
wrfinput_d01, wrfbdy_d01
, contrary to one file wrfinput_d01
as specified in the page.
###WRF:NDOWN.exe FOR DO2###
22. the file wrfinput_d01
was renamed into wrfndi_d02
and used the namelist.input as of coarse domain and changed into maxdom into 2 and the file is this namelist.inputDO1DO2. Then the ndown.exe was executed, and it ends in an error saying that.
FATAL CALLED FROM FILE: <stdin> LINE: 515
Nest start locations do not match: namelist.input vs gridded input file
-------------------------------------------
-------------- FATAL CALLED ---------------
FATAL CALLED FROM FILE: <stdin> LINE: 515
Nest start locations do not match: namelist.input vs gridded input file
- Edited namelist.input the file based on the error, the real.exe was redone with and run
./real.exe
and created new files ofwrfinput_d01, wrfbdy_d01
, in whichwrfinput_d01
was renamed intowrfndi_d02
. - Again
./ndown.exe
was executed and this time ends with an error of ————– FATAL CALLED ————— FATAL CALLED FROM FILE:LINE: 371 Found 2014-06-0503:00:54 before I found 2014-06-0503:00:00. ——————————————- In the former case, wrfoutput returned in residual timings such as this Timing for Writing wrfout_d01_2014-06-05_05:56:24 for domain 1: 0.50122 elapsed seconds
, the error is suspected to relate with this writing. So made a search to output the wrf in every hour rather than single file as produced in former wrf.exe for Coimbatore nesting. Found this page indicating the namelist input variable to be changed into make wrf output in every hour. As per the page the variables under &timecontrol such as historyinterval = 60, 60, [Outputs every hour] and framesperoutput = 1, 1, [Outputs one file per hour - desired for UPP] was edited in the namelist.input. Surprisingly the variables for framesperoutput was around 1000 in the former running namelist.input. So the namelist.input was edited and the file is this. Deleted the files from the earlier run and rerun the real.exe and wrf.exe for domain DO1. - The editing of namelist.input variable such as historyinterval and framesper_output are making wrf to output in per hour but it didn’t changed the problem of rounding the time in nearest hour ending, the problem faced by ndow.exe. Searched for this and found no information regarding this error. Followed the referred page namelist in which the time step is rounded to 180 seconds that way it produces wrf out put in integer hours. A related solution such as per the wrf ems namelist.real, the preferred method for choosing time step with 6x dx where dx is grid resolution in km is not able to follow. If it is given for 27 km resolution with time step of 6x27=162, it creates wrf output in residual timings for example, the first hour in wrfout*01:02:21.
- The wrf ouput created in integer hours moved further to nesting for second domain DO2, followed the
making temporary fine grid initial condition- Domain 02
, renamed the metem* files and edited the namelist.input for domain DO2 [the file](namelist.inputDO2v2). Run ./real.exe and it created the fileswrfinput_d01, wrfbdy_d01
, in whichwrfinput_d01
was renamed into wrfndid02 andwrfbdy_d01
was renamed into wrfbdyd01realexe. The namelist was edited for ndown.exe and used this file as namelist.input. This time./ndown.exe
was run with success and created two fileswrfinput_d02, wrfbdy_d02
with file size of 14.5MB and 27.5MB.
###WRF:wrf.exe for DO2###
- Again changed the namelist.input for considering only the DO2 and so the namelist.input file used in the step of last ./real.exe, namelist.inputDO2v2 was used as such. The wrfoutput also renamed and last ndown.exe output was renamed into DO1. Then ./wrf.exe was executed and it run with SUCCESS COMPLETE WRF and produces the wrfoutput files for DO2.
###WRF:ndown.exe:making temporary fine grid initial condition- Domain 03###
15. The metfiles created in initial WPS was renamed to consider do3 as do1
20. For fresh real.exe to run, the namelist.input dO3 details kept as such and all other details useless by making maxdom=1. The final namelist for domain 03 is this [file](CBEnamelist.inputDO3v1)
21. The real.exe was run and it produced two files
wrfinput_d01, wrfbdy_d01
, with file size of 25.8 MB and 12.5 MB.
###WRF:NDOWN.exe FOR DO3###
22. the file wrfinput_d01
was renamed into wrfndi_d02
and used the namelist.input as of domain 2 and 3. The maxdom is changed into 2 and namelist used is this [file](CBEnamelist.inputDO2DO3v1). One change was made on the namelist that the variable interval_seconds =10800
was changed into interval_seconds =3600
, considering hourly output of domain DO1. The time step also edited with resolution of coarser domain that is DO3 in this case. The ndown.exe was executed and it ends SUCCESS COMPLETE NDOWN_EM INIT
. It produced two files wrfinput_d02, wrfbdy
.
###WRF:wrf.exe for DO3###
- Again changed the namelist.input for considering only the DO3 and so the namelist.input file used in the step of last ./real.exe, CBEnamelist.inputDO3_v1 was used as such. The wrfoutput also renamed and last ndown.exe output was renamed from
wrfinput_d02, wrfbdy_d02
intowrfinput_d01, wrfbdy_d01
. Then ./wrf.exe was executed and it run with SUCCESS COMPLETE WRF and produces the wrfoutput for DO3.
###WRF:ndown.exe:making temporary fine grid initial condition- Domain 04###
15. The metfiles created in initial WPS was renamed to consider do4 as do1
20. For fresh real.exe to run, the namelist.input dO4 details kept as such and all other details useless by making maxdom=1. The final namelist for domain 04 is this [file](CBEnamelist.input_DO4 _v1)
21. The real.exe was run and it produced two files
wrfinput_d01, wrfbdy_d01
, with file size of 58.0 MB and 18.1 MB.
####WRF:NDOWN.exe FOR DO4####
22. the file wrfinput_d01
was renamed into wrfndi_d02
and used the namelist.input as of domain 3 and 4. The maxdom is changed into 2 and namelist used is this [file](CBEnamelist.inputDO3DO4v1). Change made on the namelist that the variable interval_seconds =10800
was changed into interval_seconds =3600
, considering the hourly output of domain DO1. Then the ndown.exe was executed and it ends SUCCESS COMPLETE NDOWN_EM INIT
. It produced two files wrfinput_d02, wrfbdy_d02
with file size of 58.0 MB and 54.4MB.
###WRF:wrf.exe for DO4###
- Again changed the namelist.input for considering only the DO4 and so the namelist.input file used in the step of last ./real.exe, CBEnamelist.inputDO4_v1 was used as such. The wrfoutput of domain DO3 also renamed and last ndown.exe output was renamed from
wrfinput_d02, wrfbdy_d02
intowrfinput_d01, wrfbdy_d01
. Then ./wrf.exe was executed and it run with SUCCESS COMPLETE WRF and produces the wrfoutput for DO3. For creating one hour of output, it took 40 minutes so DO4 will tke 2.30 hours to complete. Along with other domains, it can conclude it took 5 hours to run 6-hour simulation for four nested domain. The overall nesting process is depicted in figure.