Piggy_Packages V2026.1 帮助文档(六)WRF全球模式

张开发
2026/5/31 16:59:20 15 分钟阅读
Piggy_Packages V2026.1 帮助文档(六)WRF全球模式
不少初学者会有这样一个疑问为什么WRF的模拟时间不能超过GRIB初始场资料的时间呢这是因为我们平常运行的是区域模式WRF不知道区域外面发生了什么因此需要由范围更大的初始场资料为区域模式提供边界条件。那么WRF可以直接运行全球模式吗全球模式还需要边界条件吗这一节我们就来尝试下用WRF运行全球模式Note尽管WRF具备运行全球模式的能力但是官方并不推荐使用WRF来运行全球模式更推荐的是MPAS模式。首先我们回到Home目录创建一个名称为Case4的目录并进入。将WPS、WRF-Real拷贝过来。cd mkdir -p Case4 cd Case4 cp /pp_model/WRF-4.7.1/WRF-Real . cp /pp_model/WRF-4.7.1/WPS .进入WPS目录编辑namelist.wpscd WPS open -e namelist.wps把以下内容贴进去替换原始内容sharewrf_core ARW,max_dom 1,start_date 2026-03-31_00:00:00,end_date 2026-03-31_00:00:00,interval_seconds 10800/geogridparent_id 1,parent_grid_ratio 1,i_parent_start 1,j_parent_start 1,e_we 145,e_sn 73,geog_data_res lowres,map_proj lat-lon,stand_lon 0.pole_lat 90.0pole_lon 0.0geog_data_path /pp_model/WRF-4.7.1/WPS_GEOG/ungribout_format WPS,prefix FILE,/metgridfg_name FILE/查看区域配置plotgrids运行WPS三件套mpirun -np 4 ./geogrid.exe ./link_grib.csh ~/Case1/FNL/fnl_20260331_00_00.grib2 ln -s ungrib/Variable_Tables/Vtable.GFS Vtable ./ungrib.exe mpirun -np 4 ./metgrid.exe运行完成后会生成met_em.d01.2026-03-31_00:00:00.nc我们可以可视化查看它Panoply met_em.d01.2026-03-31_00:00:00.nc我们需要记录下来一个关键数值geogrid生成的DX、DY分别是多少稍后需要在WRF中配置。ncdump -h geo_em.d01.nc | grep -E :DX |:DY 执行后将会显示:DX 277943.7f ;:DY 277943.7f ;然后我们切换到WRF目录编辑配置文件。cd ../WRF-Real/run open -e namelist.input把以下内容贴进去替换原始内容time_controlrun_days 0,run_hours 1,run_minutes 0,run_seconds 0,start_year 2026,start_month 03,start_day 31,start_hour 00,end_year 2026,end_month 03,end_day 31,end_hour 00,interval_seconds 600input_from_file .true.,history_interval 10,frames_per_outfile 1,restart .false.,restart_interval 7200,io_form_history 2io_form_restart 2io_form_input 2io_form_boundary 2/domainstime_step 120,time_step_fract_num 0,time_step_fract_den 1,max_dom 1,e_we 145,e_sn 73,dx 277943.7,dy 277943.7,e_vert 50,dzbot 30.dzstretch_s 1.11dzstretch_u 1.10p_top_requested 5000,num_metgrid_levels 34,num_metgrid_soil_levels 4,grid_id 1,parent_id 0,i_parent_start 1,j_parent_start 1,parent_grid_ratio 1,parent_time_step_ratio 1,feedback 1,smooth_option 0,/physicsphysics_suite CONUSmp_physics -1, -1,cu_physics -1, -1,ra_lw_physics -1, -1,ra_sw_physics -1, -1,bl_pbl_physics -1, -1,sf_sfclay_physics -1, -1,sf_surface_physics -1, -1,radt 15, 15,bldt 0, 0,cudt 0, 0,icloud 1,num_land_cat 21,sf_urban_physics 0, 0,fractional_seaice 1,/fdda/dynamicshybrid_opt 2,w_damping 0,diff_opt 2, 2,km_opt 4, 4,diff_6th_opt 0, 0,diff_6th_factor 0.12, 0.12,base_temp 290.damp_opt 3,zdamp 5000., 5000.,dampcoef 0.2, 0.2,khdif 0, 0,kvdif 0, 0,non_hydrostatic .true., .true.,moist_adv_opt 1, 1,scalar_adv_opt 1, 1,gwd_opt 0, 0,fft_filter_lat 45.,/bdy_controlspecified .false.,periodic_x .true.,polar .true.,/grib2/namelist_quiltnio_tasks_per_group 0,nio_groups 1,/然后我们来运行real.exe和wrf.exeln -s ../../WPS/met_em.d01.2026-03-31_00:00:00.nc . mpirun -np 4 ./real.exe mpirun -np 4 ./wrf.exe全球模式的运行时间较长我们可以实时查看模拟进度。新开一个终端窗口输入tail -f ~/Case4/WRF-Real/run/rsl.out.0000注意这里我们只运行了1小时的预报你可以修改namelist中的run_hours来控制预报时常理论上它可以无限运行下去。

更多文章