Skip to content

Commit

Permalink
Add PM2.5 DA for RRFS-SD
Browse files Browse the repository at this point in the history
  • Loading branch information
hongli-wang committed Dec 2, 2022
1 parent d71623d commit cc8eafb
Show file tree
Hide file tree
Showing 11 changed files with 712 additions and 3 deletions.
65 changes: 65 additions & 0 deletions fix/gsi/anavinfo.rrfs_sd
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
met_guess::
!var level crtm_use desc orig_name
ps 1 -1 surface_pressure ps
z 1 -1 geopotential_height phis
u 65 2 zonal_wind u
v 65 2 meridional_wind v
tv 65 2 virtual_temperature tv
q 65 2 specific_humidity sphu
oz 65 2 ozone ozone
delp 65 -1 fv3 del pressure delp
::

state_derivatives::
!var level src
ps 1 met_guess
u 65 met_guess
v 65 met_guess
tv 65 met_guess
q 65 met_guess
oz 65 met_guess
cw 65 met_guess
prse 66 met_guess
::

state_tendencies::
!var levels source
u 65 met_guess
v 65 met_guess
tv 65 met_guess
q 65 met_guess
oz 65 met_guess
prse 66 met_guess
::

state_vector::
!var level itracer source funcof
u 65 0 met_guess u
v 65 0 met_guess v
tv 65 0 met_guess tv
tsen 65 0 met_guess tv,q
q 65 1 met_guess q
oz 65 1 met_guess oz
prse 66 0 met_guess prse
ps 1 0 met_guess prse
smoke 65 1 chem_guess smoke
dust 65 1 chem_guess dust
::

control_vector::
!var level itracer as/tsfc_sdv an_amp0 source funcof
sf 65 0 0.90 -1.0 state u,v
vp 65 0 0.90 -1.0 state u,v
ps 1 0 1.00 -1.0 state prse
t 65 0 1.40 -1.0 state tv
q 65 1 0.80 -1.0 state q
smoke 65 1 1.00 -1.0 state smoke
dust 65 1 1.00 -1.0 state dust
::

chem_guess::
!var level itracer crtm_use type orig_name
smoke 65 1 12 smoke smoke
dust 65 1 12 dust dust
pm2_5 65 1 10 pm2_5 pm2_5
::
234 changes: 234 additions & 0 deletions fix/gsi/convinfo.rrfs_sd

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions fix/gsi/gsiparm.anl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ gsi_namelist="
/
OBS_INPUT::
! dfile dtype dplat dsis dval dthin dsfcalc
pm25bufr pm2_5 null TEOM 1.0 0 0
dbzobs.nc dbz null dbz 1.0 0 0
prepbufr ps null ps 1.0 0 0
prepbufr t null t 1.0 0 0
Expand Down Expand Up @@ -188,8 +189,8 @@ OBS_INPUT::
build_cloud_frac_p=0.50,
clear_cloud_frac_p=0.10,
iclean_hydro_withRef_allcol=1,
i_use_2mQ4B=2,
i_use_2mT4B=1,
i_use_2mQ4B=${ii_use_2mq4b},
i_use_2mT4B=${ii_use_2mt4b},
i_gsdcldanal_type=0,
i_gsdsfc_uselist=1,
i_lightpcp=1,
Expand All @@ -198,6 +199,8 @@ OBS_INPUT::
i_gsdqc=2,
/
&CHEM
laeroana_fv3smoke=.true.,
berror_fv3_cmaq_regional = .true.,
/
&NST
/
Expand Down
75 changes: 75 additions & 0 deletions scripts/exregional_run_analysis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,8 @@ niter2=50
lread_obs_save=.false.
lread_obs_skip=.false.
if_model_dbz=.false.
ii_use_2mq4b=2
ii_use_2mt4b=1

# Determine if hybrid option is available
memname='atmf009'
Expand Down Expand Up @@ -484,6 +486,12 @@ else

fi


if [ ${ob_type} == "AERO" ]; then
obs_files_source[0]=${OBSPATH_PM}/${YYYYMMDD}/pm25.airnow.${YYYYMMDD}${HH}.bufr
obs_files_target[0]=pm25bufr
fi

fi

#
Expand Down Expand Up @@ -616,6 +624,25 @@ HYBENSINFO=${FIX_GSI}/${HYBENSINFO_FN}
OBERROR=${FIX_GSI}/${OBERROR_FN}
BERROR=${FIX_GSI}/${BERROR_FN}


if [[ ${gsi_type} == "ANALYSIS" && ${ob_type} == "AERO" ]]; then
ANAVINFO=${FIX_GSI}/${ANAVINFO_SD_FN}
CONVINFO=${FIX_GSI}/${CONVINFO_SD_FN}
BERROR=${FIX_GSI}/${BERROR_SD_FN}
miter=1
niter1=100
niter2=0
ifhyb=.false.
ifsd_da=.true.
l_hyb_ens=.false.
nummem=0
beta1_inv=0.0
ii_use_2mq4b=0
ii_use_2mt4b=0
netcdf_diag=.true.
binary_diag=.false.
fi

SATINFO=${FIX_GSI}/global_satinfo.txt
OZINFO=${FIX_GSI}/global_ozinfo.txt
PCPINFO=${FIX_GSI}/global_pcpinfo.txt
Expand Down Expand Up @@ -805,6 +832,14 @@ cat << EOF > gsiparm.anl
$gsi_namelist
EOF

if [[ ${gsi_type} == "ANALYSIS" && ${ob_type} != "AERO" ]]; then
# base_e GSI can't handle the below two parameter for RRFS-SD DA. So delete them.
mv gsiparm.anl gsiparm.anl.sd
sed '/laeroana_fv3smoke/d' gsiparm.anl.sd > gsiparm.anl.1
sed '/berror_fv3_cmaq_regional/d' gsiparm.anl.1 > gsiparm.anl
rm -fr gsiparm.anl.sd gsiparm.anl.1
fi

#
#-----------------------------------------------------------------------
#
Expand All @@ -814,6 +849,11 @@ EOF
#
gsi_exec="${EXECDIR}/gsi.x"

if [[ ${gsi_type} == "ANALYSIS" && ${ob_type} == "AERO" ]]; then
gsi_exec="${EXECDIR}/gsi.x.sd"
fi


if [ -f $gsi_exec ]; then
print_info_msg "$VERBOSE" "
Copying the GSI executable to the run directory..."
Expand Down Expand Up @@ -842,6 +882,40 @@ fi
#-----------------------------------------------------------------------
#
# comment out for testing
if [[ ${gsi_type} == "ANALYSIS" && ${ob_type} == "AERO" ]]; then

if [ ${BKTYPE} -eq 1 ]; then
print_info_msg "$VERBOSE" "
Coldstart skip GSI SD DA"
else
# backup background
if [ "${IO_LAYOUT_Y}" == "1" ]; then
cp -fr ${bkpath}/fv_tracer.res.tile1.nc ${bkpath}/fv_tracer.res.tile1.nc.org
else
for ii in ${list_iolayout}
do
iii=`printf %4.4i $ii`
cp -fr ${bkpath}/fv_tracer.res.tile1.nc.${iii} ${bkpath}/fv_tracer.res.tile1.nc.${iii}.org
done
fi

$APRUN ./gsi.x < gsiparm.anl > stdout 2>&1 || print_err_msg_exit "\
Call to executable to run GSI returned with nonzero exit code."

# copy updated fv3_tracer back to restart
if [ "${IO_LAYOUT_Y}" == "1" ]; then
cp -fr fv3_tracer ${bkpath}/fv_tracer.res.tile1.nc
else
for ii in ${list_iolayout}
do
iii=`printf %4.4i $ii`
cp -fr fv3_tracer.${iii} ${bkpath}/fv_tracer.res.tile1.nc.${iii}
done
fi
fi

else

$APRUN ./gsi.x < gsiparm.anl > stdout 2>&1 || print_err_msg_exit "\
Call to executable to run GSI returned with nonzero exit code."

Expand All @@ -855,6 +929,7 @@ sed -e 's/ asm all/rw asm 900/; s/ rej all/rw rej 900/; s/ mon all/rw mon

cat fit_p1 fit_w1 fit_t1 fit_q1 fit_pw1 fit_rad1 fit_rw1 > $comout/rrfs_a.t${HH}z.fits.tm00
cat fort.208 fort.210 fort.211 fort.212 fort.213 fort.220 > $comout/rrfs_a.t${HH}z.fits2.tm00
fi
#
#-----------------------------------------------------------------------
#
Expand Down
Loading

0 comments on commit cc8eafb

Please sign in to comment.