California Central Valley (Experiment 6) ATM 419 Spring 2016 Fovell 1
Links/sources WRF namelist.input description and options MET User's Guide (v.5.0) NCAR’s Research Data Archive: rda.ucar.edu 2
Case overview We will make a 3-day simulation during December 2005 in a 2-domain configuration centered over California. Verification period will be the last 2 days of the 3-day run. First day ignored as “spin-up”. Verification domain will be the California Central Valley (CV) using observations from ASOS/AWOS obtained from MADIS. The success metric will be CV-averaged mean absolute error (MAE), summed over those 49 hours as verified against the dataset I provide. The smallest total will "win". 3
New aspects of this experiment Use the NARR reanalysis for initialization Verify against observations confined to a portion of the model domain Verify against a fraction of the forecast time period Optionally, manipulate vertical model levels The “default WRF” setup performs quite poorly 4
Domain setup Experiment setup details in CV_experiment_details.docx Edit namelist.wps as required Do domain setup Check your domain 5
Using NARR reanalysis NARR requires its own Vtable for ungrib and also a fixed-fields file to be provided for the metgrid step. See details document. NARR data are available every 3 hours (10800 sec) NARR files named like: –merged_AWIP D merged_AWIP RS.clm merged_AWIP RS.flx merged_AWIP RS.pbl merged_AWIP RS.sfc – Actually need only the 3D, flx, and sfc files –link_grib.csh /network/rit/lab/atm419lab/NARR/200512/merged* 6
In namelist.wps &ungrib out_format = 'WPS', prefix = ’NARR', / &metgrid constants_name = ’/network/rit/lab/atm419lab/NARR/FIXED_NARR', fg_name = ’NARR', io_form_metgrid = 2, / 7 Specifying the ‘ prefix ’ and ‘ fg_name ’ as “NARR” is not necessary but is convenient if you decide to use alternate or combined data sources. If you are not using NARR, you must remove the constants_name reference. (Move the line after the / to ‘deactivate’ it.)
WPS and WRF Link to the NARR files and get your NARR Vtable Perform ungrib.exe, metgrid.exe as usual Check on num_metgrid_levels Edit namelist.input as required for default run setup (see also next slide) – We will run for 3 days, using 2 domains – Make sure domain particulars match namelist.wps Do real.exe via batch script submit_wrf Create your default run RUN01 8
Edit namelist.input Make sure run_days = 3 and start/end times are correct Make sure domain details match namelist.wps Make sure num_metgrid_levels is correct Model setup: – time_step = 120 sec – 51 vertical levels – p_top_requested = – Microphysics option 2 – LW and SW 4, with 10 min time step (radt) – YSU PBL w/ sf_sfclay_physics = 1 – Noah LSM – Cumulus scheme #1 (K-F), on in both domains, with 5 min time step (cudt) – Turn the 6 th order diffusion on in both domains, with diff_6th_factor = 0.12 for both (diff_6 th _opt = 1, 1) – Use dampcoef = 0.01 for both domains – Moisture and other scalar advection option 2 in both domains 9
Dampers often used in real-data WRF 10 w_damping = 1, diff_opt = 1,1, km_opt = 4,4, diff_6th_opt = 1, 1, diff_6th_factor = 0.12, 0.12, damp_opt = 3, zdamp = 5000., 5000., dampcoef = 0.01, 0.01, w_damping = 1 suppresses some “anomalously large” vertical motions. Coefficients are hard-coded in share/module_model_constants.F diff_6 th _opt = 1 or 2 provides 6 th order smoothing. Here, option 1 is used, which is not positive definite. damp_opt = 3 provides upper-level Rayleigh damping. Coefficient dampcoef is damping rate (1/s). Applied over depth zdamp below model top. Typical values are up to 0.2 for real-data runs. Here, dampcoef is much smaller than typically used.
Other dampers (leave these alone) epssm = damps vertically-propagating sound waves emdiv = damps the external mode If absent from namelist.input, default values are employed 11
Advection options 12 moist_adv_opt = 2, 2, scalar_adv_opt = 2, 2, These can be used to make advection of moisture and other scalars either positive definite (1) or monotonic (2). Raw advection Positive definite Monotonic (pos. def. + no oscillations)
Diffusion options In a moderate resolution real-data WRF run (such as ours), there are two kinds of “meteorological diffusion”: horizontal and vertical – Vertical diffusion is handled by the PBL scheme, even for free atmosphere above the PBL – Horizontal diffusion is handled by diff_opt, km_opt namelist options km_opt = 4 computes strictly horizontal diffusion (the only option when a PBL scheme is employed) –km_opt = 1 applies constant diffusion (undesirable) –km_opt = 2 or 3 does 3D turbulent diffusion (inconsistent with PBL scheme) diff_opt = 1 does diffusion along model surfaces, while diff_opt = 2 does diffusion in physical space (see next slide). diff_opt = 0 shuts it off. –diff_opt = 2 used to blow up in complex terrain. Now it “shuts itself off”. Standard setup for these runs: diff_opt = 1, km_opt = 4. 13
14 diff_opt = 1 diff_opt = 2 Horizontal diffusion is along model surfaces (if model levels sloped, diffusion isn’t really horizontal) Diffusion is in physical space (even if model surfaces are sloped)
Verification Review of steps – Create an analysis directory (like RUN01 ) – Create subdirectories RUN01/postprd and RUN01/wrfprd – Move your wrfout * files into RUN01/wrfprd – Make sure you have edited copies of run_unipost and MET_run_ASCII2_ASOS.sh in the analysis directory ( RUN01 ). See upcoming slides. 15
run_unipost export startdate= export fhr=24 export lastfhr=72 export incrementhr=01 for domain in d02 Our simulation starts on at 00Z but our verification period will start 24 hours later. Our verification will focus on D2. 16
MET analysis domains Statistics will be generated for 2 areas in D2: the FULL domain and the CV subdomain, described in the file CV_large.poly –CV_large.poly is a polygon outlining the CV interior (see next slide) MET_run_ASCII2_ASOS.sh points to a configuration file called PointStatConfig.NODUP.ATM419.CV (see upcoming slides) 17
CV_large Contents of CV_large.poly 18
PointStatConfig.NODUP.ATM419.CV 1/4 19 // // Forecast and observation fields to be verified // // repeated wind twice for forecast,. third wind is L1 vs gust fcst = { wind_thresh = [ NA ]; message_type = [ "ADPSFC" ]; field = [ { name = "TMP"; level = [ "Z2" ]; cat_thresh = [ >0 ]; }, { name = "WIND"; level = [ "Z10" ]; cat_thresh = [ >=0 ]; }, [etc.] This section of the configuration file declares the forecast fields to be verified Temperature at 2-m Wind speed at 10-m For information only. You do not need to edit this file.
PointStatConfig.NODUP.ATM419.CV 2/4 20 obs = { wind_thresh = [ NA ]; message_type = [ "ADPSFC" ]; field = [ { name = "TMP"; level = [ "Z2" ]; cat_thresh = [ >0 ]; }, { name = "WIND"; level = [ "Z10" ]; cat_thresh = [ >=0 ]; }, [etc.] This section of the configuration file declares the observation fields to be verified. They must match up 1:1 with declared forecast fields. For information only. You do not need to edit this file.
PointStatConfig.NODUP.ATM419.CV 3/4 21 // // Verification masking regions // mask = { grid = [ "FULL" ]; poly = ["/network/rit/home/rf518462/METV5/CV_large.poly"]; sid = ""; }; The CV area is described in the polygon file called CV_large.poly. See next slide. For information only. You do not need to edit this file.
PointStatConfig.NODUP.ATM419.CV 4/4 22 // // Point observation time window // obs_window = { beg = -1800; end = 1800; } // // Interpolation methods // interp = { vld_thresh = 1.0; type = [ { method = UW_MEAN; width = 1; } ]; }; duplicate_flag = SINGLE; Other selections that could be reconsidered. Obs time can be up to 30 min (1800 sec) before or after the forecast time SINGLE here means only one obs per station is permitted at the given forecast time. (MET selects closest time match.) Interpolation method is unweighted mean
MET_run_ASCII2_ASOS.sh Date_base= Date_hour=00 domain=2 MYHOME=/network/rit/home/rf MET_base=$MYHOME/METV5 OBS_base=/network/rit/lab/atm419lab/MADIS/MADIS_ RUN_base=$PWD/postprd Grey = do not change. Although verification period starts on 6 th, this should be configured as shown here. 23
Running MET Steps (after editing files) – Execute srun bash run_unipost – Execute srun sh MET_run_ASCII2_ASOS.sh – Execute plot_met_CV.sh to get statistics for T, Td and RH The plot_met_CV.sh script has been altered to report either statistics averaged over stations throughout D2 (“FULL”) or those in the CV (“CV_large”). We will verify against CV_large. – Options for this script have changed somewhat. – See next slide. If your analysis was set up correctly, the first analysis time reported should be _0000. We are skipping Dec 5 th. 24
sh plot_met_CV.sh _ FULL TMPf TMPo N 40 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ FULL TMPf TMPo N 40 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ FULL TMPf TMPo N 41 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ FULL TMPf TMPo N 39 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o sh plot_met_CV.sh _ CV_large TMPf TMPo N 20 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ CV_large TMPf TMPo N 19 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ CV_large TMPf TMPo N 20 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o _ CV_large TMPf TMPo N 21 MAE BCRMSE MSE BIAS STDf STDo LVL Z2f Z2o Note that option 2 reports TMP for domain “FULL”, which has about 40 stations. Note that option 3 reports TMP for domain “CV_large”, which has about 20 stations. This is what we want. 25
sh plot_met_CV.sh 3 sh plot_met_CV.sh 9 sh plot_met_CV.sh 11 TMP for CV_large DPT for CV_large RH for CV_large 26 For RH in CV_large, MAE sum = for hours Low RH results from a warm bias in T and a dry bias in Td, especially at night.
Experiment 6: Improve the CV RH forecast 27
Experiment 6 For Experiment 6, your task is to improve the RH forecast for the CV Our default run RUN01 has a pretty standard setup, but fails to capture CV RH well, especially at night. WRF model provides many, many options. Not all options make sense for this application, and not all options “play nice” together. The pervasive question: are we getting the right answer for the right reason? 28
Notes There are many namelist and physics options. Not all work with all physics combinations. Some are not well-tested. Some may force smaller time steps. The LES options should be ignored, as they require much, much finer grid spacing. slope_rad and topo_shading modify solar radiation on terrain slopes, but usually used when spatial resolution is higher than in our domains. iz0tlnd = 1 enhances surface evaporation in more heavily vegetated areas. icloud = 1, 2 alters how SW radiation interacts with clouds. icloud = 0 makes clouds transparent to radiation. sf_urban_physics controls some aspects of urbanized areas in the domain. The isfflx flag can deactivate surface fluxes in some physics combinations. Similarly, ifsnow can activate/deactivate snow effects with sf_surface_physics = 1. ysu_topdown_pblmix = 1 attempts to modify YSU to work better in foggy boundary layers. Only works with YSU PBL. topo_wind = 1 attempts to adjust near-surface winds for unresolved topography. Only works with YSU PBL. For cumulus schemes other than K-F ( cu_physics = 1), cudt should be 0. 29
30 The success metric will be CV-averaged MAE, summed over those 49 hours as verified against the dataset I provide. The smallest total will "win". Rules: You cannot change the time period being simulated. Your simulations must start on , and run for 3 days. You cannot change the verifying data, region or time period. The data are from ASOS/AWOS stations, the region is the CV, and time period is the two day interval between and You cannot use any data assimilation or nudging. You have to use the domain I provided (2 nested domains, resolution, location). You cannot change the resolution, or add a 3rd nest. You must use the WRF model executable and the PointStatConfig file I have provided. However: You CAN alter model physics options. See WRF namelist page for scads of available options. You CAN alter the initialization data source, in any way you wish. This includes a different reanalysis altogether and/or different atmospheric and soil moisture sources. You CAN change the number of vertical levels, and use the eta_levels namelist option to manipulate them as you wish. (See following slides for additional information.) You CAN change the length of time steps, for the model and/or for the radiation and cumulus schemes. However, please leave bldt = 0.
Recording your results Google spreadsheet 31 Create a unique simulation name with your surname. Add your summed MAE to the spreadsheet. Record your numbers even if the run wasn’t very good. Save your notes and outputs as I may ask to see them. See “RUN01 results” tab for output from plot_met_CV for T, Td and RH for RUN01
Altering vertical levels 32 ncdump –v ZNW wrfinput_d01 ZNW = 1, 0.993, 0.983, 0.97, 0.954, 0.934, 0.909, 0.88, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , 0 ; If you specify 51 vertical levels in the namelist.input, real.exe creates 51 “eta” or “sigma” levels, representing a nondimensional vertical coordinate stored as ZNW in wrfinput_d01. Use ncdump to reveal the eta values. They always start at 1, and end with 0. You can manually declare these levels in namelist.input ’s &domains section. You should get the same result from real.exe, to within roundoff error. eta_levels = 1, 0.993, 0.983, 0.97, 0.954, 0.934, 0.909, 0.88, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , 0,
“Eta” or “sigma: coordinate 33 WRF Dynamics and numerics tutorial document p h = hydrostatic pressure p h s = hydrostatic pressure at surface p h t = hydrostatic pressure at model top = held constant
34 ncks -C -H -d south_north,1 -d west_east,1 -v PHB wrfinput_d01 Time[0] bottom_top_stag[0] south_north[1] west_east[1] PHB[70]=0 Time[0] bottom_top_stag[1] south_north[1] west_east[1] PHB[4831]= Time[0] bottom_top_stag[2] south_north[1] west_east[1] PHB[9592]= Time[0] bottom_top_stag[3] south_north[1] west_east[1] PHB[14353]= Time[0] bottom_top_stag[4] south_north[1] west_east[1] PHB[19114]= Time[0] bottom_top_stag[5] south_north[1] west_east[1] PHB[23875]= Time[0] bottom_top_stag[6] south_north[1] west_east[1] PHB[28636]= Time[0] bottom_top_stag[7] south_north[1] west_east[1] PHB[33397]= Time[0] bottom_top_stag[8] south_north[1] west_east[1] PHB[38158]= Time[0] bottom_top_stag[9] south_north[1] west_east[1] PHB[42919]= Time[0] bottom_top_stag[10] south_north[1] west_east[1] PHB[47680]= Time[0] bottom_top_stag[11] south_north[1] west_east[1] PHB[52441]=16540 Time[0] bottom_top_stag[12] south_north[1] west_east[1] PHB[57202]= Time[0] bottom_top_stag[13] south_north[1] west_east[1] PHB[61963]= Time[0] bottom_top_stag[14] south_north[1] west_east[1] PHB[66724]= Time[0] bottom_top_stag[15] south_north[1] west_east[1] PHB[71485]= Time[0] bottom_top_stag[16] south_north[1] west_east[1] PHB[76246]= Time[0] bottom_top_stag[17] south_north[1] west_east[1] PHB[81007]= Time[0] bottom_top_stag[18] south_north[1] west_east[1] PHB[85768]=41466 Time[0] bottom_top_stag[19] south_north[1] west_east[1] PHB[90529]= Time[0] bottom_top_stag[20] south_north[1] west_east[1] PHB[95290]= Time[0] bottom_top_stag[21] south_north[1] west_east[1] PHB[100051]= Time[0] bottom_top_stag[22] south_north[1] west_east[1] PHB[104812]= Time[0] bottom_top_stag[23] south_north[1] west_east[1] PHB[109573]= Time[0] bottom_top_stag[24] south_north[1] west_east[1] PHB[114334]= Time[0] bottom_top_stag[25] south_north[1] west_east[1] PHB[119095]= Time[0] bottom_top_stag[26] south_north[1] west_east[1] PHB[123856]= Time[0] bottom_top_stag[27] south_north[1] west_east[1] PHB[128617]= Time[0] bottom_top_stag[28] south_north[1] west_east[1] PHB[133378]= Time[0] bottom_top_stag[29] south_north[1] west_east[1] PHB[138139]= Time[0] bottom_top_stag[30] south_north[1] west_east[1] PHB[142900]= Time[0] bottom_top_stag[31] south_north[1] west_east[1] PHB[147661]= Time[0] bottom_top_stag[32] south_north[1] west_east[1] PHB[152422]= Time[0] bottom_top_stag[33] south_north[1] west_east[1] PHB[157183]=94881 Time[0] bottom_top_stag[34] south_north[1] west_east[1] PHB[161944]= Time[0] bottom_top_stag[35] south_north[1] west_east[1] PHB[166705]= Time[0] bottom_top_stag[36] south_north[1] west_east[1] PHB[171466]= Time[0] bottom_top_stag[37] south_north[1] west_east[1] PHB[176227]= Time[0] bottom_top_stag[38] south_north[1] west_east[1] PHB[180988]= Time[0] bottom_top_stag[39] south_north[1] west_east[1] PHB[185749]= Time[0] bottom_top_stag[40] south_north[1] west_east[1] PHB[190510]= Time[0] bottom_top_stag[41] south_north[1] west_east[1] PHB[195271]= Time[0] bottom_top_stag[42] south_north[1] west_east[1] PHB[200032]= Time[0] bottom_top_stag[43] south_north[1] west_east[1] PHB[204793]= Time[0] bottom_top_stag[44] south_north[1] west_east[1] PHB[209554]= Time[0] bottom_top_stag[45] south_north[1] west_east[1] PHB[214315]= Time[0] bottom_top_stag[46] south_north[1] west_east[1] PHB[219076]= Time[0] bottom_top_stag[47] south_north[1] west_east[1] PHB[223837]= Time[0] bottom_top_stag[48] south_north[1] west_east[1] PHB[228598]= Time[0] bottom_top_stag[49] south_north[1] west_east[1] PHB[233359]= Time[0] bottom_top_stag[50] south_north[1] west_east[1] PHB[238120]= PHB is base state geopotential height. Divide by for height above MSL. Here, PHB for grid point (1,1) is shown. As this is over water, the height is also height AGL. These heights are for the W locations, which start at the surface.
35 Default vertical levels from real.exe …results in 8 levels within lowest 1 km AGL First W level above ground at ~ 54 m so first scalar level at about 27 m If you increase or decrease the number of levels, these heights change… … but real.exe tries to keep the lowest 8 W levels at same heights (see next slide)
Model levels for e_vert = 51 and Model levelW height (51 levels), in meters W height (31 levels), in meters If you want to increase vertical resolution near the surface, this is NOT accomplished by increasing the number of model levels! Specify eta_levels instead. Note both vertical grids have same lowest 8 model levels!
Some other WRF initialization datasets ERA-Interim (6 hourly files) –/network/rit/lab/atm419lab/ERAI/200512/ – Requires Vtable.ERA-interim.pl CFSR (Climate Forecast System Reanalysis, v. 1; also 6 hourly) –/network/rit/lab/atm419lab/CFSR/ pgb* = atmospheric data on pressure levels flx* = surface data – Requires doing atmospheric and surface ungrib tasks separately, using different Vtables – Vtables: Vtable.CFSR_press_pgbh06, Vtable.CFSR_sfc_flxf06 – Set different prefixes (such as CFSR, CFSR_SFC) for the 2 ungrib runs, then combine them for metgrid: fg_name = 'CFSR','CFSR_SFC', 37