Skip to content
This repository has been archived by the owner on Nov 8, 2024. It is now read-only.

Commit

Permalink
HWRF surface layer and ocean coupling updates (#74)
Browse files Browse the repository at this point in the history
TYPE: enhancement

KEYWORDS: NMM, HWRF, Surface layer, ocean coupling

SOURCE: NCEP/EMC HWRF Development team

DESCRIPTION OF CHANGES: Add updates to the surface fluxes and ocean
coupling option for HWRF.  This includes a coupling connection 
to the WaveWatchIII model.  These updates are used in the 2016 operational 
HWRF forecast system, the WW3 coupling is configured as one-way only 
until further testing can be completed.

See documentation on page 49 here:

http://www.dtcenter.org/HurrWRF/users/docs/scientific_documents/HWRFv3.8a_ScientificDoc.pdf


LIST OF MODIFIED FILES:

    M       Registry/Registry.NMM
    M       dyn_nmm/module_PHYSICS_CALLS.F
    M       dyn_nmm/module_initialize_real.F
    M       dyn_nmm/solve_nmm.F
    M       external/atm_ocn/atm_comm.F
    M       external/atm_ocn/cmpcomm.F
    M       external/atm_ocn/module_PATCH_QUILT.F
    M       phys/module_bl_gfs.F
    M       phys/module_pbl_driver.F
    M       phys/module_sf_exchcoef.F
    M       phys/module_sf_gfdl.F
    M       phys/module_surface_driver.F
    M       share/module_interp_nmm.F


TESTS CONDUCTED:

WTF completed
HWRF operational configuration (3-nests, ocean coupled) - completed as expected
  • Loading branch information
llpcarson committed Jan 6, 2017
1 parent e0c2c66 commit d60645c
Show file tree
Hide file tree
Showing 13 changed files with 993 additions and 316 deletions.
13 changes: 11 additions & 2 deletions Registry/Registry.NMM
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,14 @@ state real mixht ij dyn_nmm 1 - rh "MIXHT"
state real ustar ij dyn_nmm 1 - irh023d=(DownNear) "USTAR" "Friction velocity" "m s-1"
state real z0 ij dyn_nmm 1 - i01rh023d=(DownNear) "Z0" "Thermal Roughness length" "m"
state real mz0 ij dyn_nmm 1 - h "MZ0" "momentum Roughness length" "m"
state real scurx ij dyn_nmm 1 - irh023d=(DownNear)f=(force_sst_nmm:IIH,JJH,HBWGT1,HBWGT2,HBWGT3,HBWGT4,FORCE_SST) "SCURX" "Surface Currents(X)" "m s-1"
state real scury ij dyn_nmm 1 - irh023d=(DownNear)f=(force_sst_nmm:IIH,JJH,HBWGT1,HBWGT2,HBWGT3,HBWGT4,FORCE_SST) "SCURY" "Surface Currents(Y)" "m s-1"
state real charn ij dyn_nmm 1 - irh023d=(DownNear)f=(force_sst_nmm:IIH,JJH,HBWGT1,HBWGT2,HBWGT3,HBWGT4,FORCE_SST) "CHARN" "Charnock Coeff" " "
state real msang ij dyn_nmm 1 - irh023d=(DownNear)f=(force_sst_nmm:IIH,JJH,HBWGT1,HBWGT2,HBWGT3,HBWGT4,FORCE_SST) "MSANG" "Wind/Stress Angle" "Radian"
state real rchno ij dyn_nmm 1 - irh023 "RCHNO" "Richardson number" " "
state real zsig1 ij dyn_nmm 1 - irh023 "ZSIG1" "Height of lowest model level" "m"
state real ulowl ij dyn_nmm 1 - irh023 "ULOWL" "U at Lowest Level" "m s-1"
state real vlowl ij dyn_nmm 1 - irh023 "VLOWL" "V at Lowest Level" "m s-1"
state real rc2d ij dyn_nmm 1 - h "RC2D" "critical Richardson number" "m"
state real dku3d ijk dyn_nmm 1 - rh "DKU3D" "Momentum Diffusivity" "m*m/s"
state real dkt3d ijk dyn_nmm 1 - rh "DKT3D" "Thermal Diffusivity" "m*m/s"
Expand Down Expand Up @@ -1462,6 +1470,7 @@ endif
rconfig integer random_seed namelist,physics max_domains 0 irh "random_seed" "random number generator seed"

rconfig integer icoef_sf namelist,physics max_domains 0 irh012 3 "icoef_sf" "Option for exchange coefficients in the surface flux scheme" ""
rconfig integer iwavecpl namelist,physics max_domains 0 irh012 3 "iwavecpl" "Option for activate coupling to sea surface wave model" ""
rconfig logical lcurr_sf namelist,physics max_domains .false. irh012 3 "lcurr_sf" "Option to include ocean currents in the surface flux calculations" ""

ifdef HWRF=1
Expand Down Expand Up @@ -1865,7 +1874,7 @@ halo HALO_NMM_INIT_5 dyn_nmm 120:CPGFU,CURV,FCP
halo HALO_NMM_INIT_6 dyn_nmm 120:FDIV,FAD,F
halo HALO_NMM_INIT_7 dyn_nmm 120:DDMPU,DDMPV,GLAT
halo HALO_NMM_INIT_8 dyn_nmm 120:GLON,EPSR,TG
halo HALO_NMM_INIT_9 dyn_nmm 120:GFFC,SST,ALBASE
halo HALO_NMM_INIT_9 dyn_nmm 120:GFFC,SST,ALBASE,SCURX,SCURY,CHARN,MSANG
#halo HALO_NMM_INIT_10 dyn_nmm 120:HDAC,HDACV,IVGTYP
halo HALO_NMM_INIT_10 dyn_nmm 120:HDAC,HDACV
#halo HALO_NMM_INIT_11 dyn_nmm 120:ISLTYP,ISLOPE,VEGFRC
Expand Down Expand Up @@ -1929,7 +1938,7 @@ halo HALO_NMM_TURBL_B dyn_nmm 8:dudt,dvdt
# following halos added for nesting purpose (gopal's doing):

halo HALO_NMM_TRACK dyn_nmm 120:sm,pdyn,mslp,sqws
halo HALO_NMM_FORCE_DOWN_SST dyn_nmm 120:sst
halo HALO_NMM_FORCE_DOWN_SST dyn_nmm 120:sst,scurx,scury,charn,msang
halo HALO_NMM_WEIGHTS dyn_nmm 48:IIH,JJH,HBWGT1,HBWGT2,HBWGT3,HBWGT4,IIV,JJV,VBWGT1,VBWGT2,VBWGT3,VBWGT4,HNEAR_I,HNEAR_J

#halo HALO_NMM_FORCE_DOWN1 dyn_nmm 24:t,u,v,q,q2,cwm,pint,pd,hres_fis,fis,pdyn_parent,pdyn_smooth
Expand Down
57 changes: 47 additions & 10 deletions dyn_nmm/module_PHYSICS_CALLS.F
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,7 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
!- RLWIN/RSWIN - downward longwave/shortwave at the surface (also TOTLWDN/TOTSWDN in RADIATION)
& ,PD,RES,PINT,T,Q,CWM,F_ICE,F_RAIN,SR &
& ,Q2,U,V,THS,TSFC,SST,PREC,SNO &
& ,SCURX,SCURY &
& ,FIS,Z0,MZ0,Z0BASE,USTAR,MIXHT,PBLH,LPBL,EL_MYJ & !MZ0: MOMENTUM Z0 (KWON)
& ,MOIST,RMOL,MOL &
& ,EXCH_H,EXCH_M,F,AKHS,AKMS,AKHS_OUT,AKMS_OUT &
Expand All @@ -736,14 +737,14 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
& ,SFCEXC,ACSNOW,ACSNOM,SNOPCX,SICE,TG,SOILTB &
& ,ALBSI,ICEDEPTH,SNOWSI &
& ,ALBASE,MXSNAL,ALBEDO,SH2O,SI,EPSR,EMBCK &
& ,U10,V10,UOCE,VOCE,TH10,Q10,TSHLTR,QSHLTR,PSHLTR &
& ,U10,V10,UOCE,VOCE,TH10,Q10,TSHLTR,QSHLTR,PSHLTR &
& ,T2,QSG,QVG,QCG,SOILT1,TSNAV,SMFR3D,KEEPFR3DFLAG &
& ,TWBS,QWBS,TAUX,TAUY,SFCSHX,SFCLHX,SFCEVP,RTHRATEN&
& ,POTEVP,POTFLX,SUBSHX &
& ,APHTIM,ARDSW,ARDLW,ASRFC &
& ,RSWOUT,RSWTOA,RLWTOA &
& ,ASWIN,ASWOUT,ASWTOA,ALWIN,ALWOUT,ALWTOA &
& ,UZ0H,VZ0H,DUDT,DVDT,UGWDsfc,VGWDsfc,SFENTH & ! GWD
& ,UZ0H,VZ0H,DUDT,DVDT,UGWDsfc,VGWDsfc,SFENTH & ! GWD
& ,RTHBLTEN,RQVBLTEN &
& ,PCPFLG,DDATA & ! PRECIP ASSIM
& ,HSTDV,HCNVX,HASYW,HASYS,HASYSW,HASYNW,HLENW & ! GWD
Expand All @@ -757,6 +758,10 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
& ,HPBL2D, EVAP2D, HEAT2D,RC2D & !Kwon S&P
& ,SFCHEADRT,INFXSRT,SOLDRAIN & !Hydrology, no-op right now
& ,cd_out,ch_out &
& ,ulowl, vlowl &
& ,zkmax, ribn &
& ,charn, msang &
& ,DUBLDT,DVBLDT,DTHBLDT,DQVBLDT & !wang added PBL tendency output
& ,IDS,IDE,JDS,JDE,KDS,KDE &
& ,IMS,IME,JMS,JME,KMS,KME &
& ,IPS,IPE,JPS,JPE,KPS,KPE &
Expand Down Expand Up @@ -891,9 +896,18 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
,SFCEXC,SMSTAV &
,SOILTB,TWBS
!
REAL,DIMENSION(IMS:IME,JMS:JME),INTENT(IN) :: scurx, scury

REAL,DIMENSION(IMS:IME,JMS:JME),INTENT(INOUT) :: cd_out,ch_out
REAL,DIMENSION(IMS:IME,JMS:JME,KMS:KME),INTENT(INOUT) :: &
DTHBLDT &
,DQVBLDT &
,DUBLDT &
,DVBLDT

REAL,DIMENSION(IMS:IME,JMS:JME),INTENT(OUT) :: taux, tauy
REAL,DIMENSION(IMS:IME,JMS:JME),INTENT(INOUT) :: zkmax, ribn
REAL,DIMENSION(IMS:IME,JMS:JME),INTENT(IN) :: charn, msang
REAL,DIMENSION(IMS:IME,JMS:JME,KMS:KME),INTENT(IN) :: PINT
!
REAL,DIMENSION(IMS:IME,JMS:JME,KMS:KME),INTENT(INOUT) :: CWM &
Expand Down Expand Up @@ -976,6 +990,8 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
& ,T_PHY,TH_PHY,TKE &
& ,DUDT_GWD,DVDT_GWD & ! GWD
& ,U_PHY,V_PHY,Z
!
REAL,DIMENSION(IMS:IME,JMS:JME), INTENT(OUT) :: ULOWL, VLOWL
!
REAL,DIMENSION(:,:,:,:),ALLOCATABLE :: MOIST_TRANS
!
Expand Down Expand Up @@ -1041,6 +1057,7 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
IFNDALBSI = 0
IFNDSNOWSI = 0
IFNDICEDEPTH = 0
BR=10

SEAICE_ALBEDO_DEFAULT = CONFIG_FLAGS%SEAICE_ALBEDO_DEFAULT
SEAICE_THICKNESS_OPT = CONFIG_FLAGS%SEAICE_THICKNESS_OPT
Expand Down Expand Up @@ -1267,6 +1284,10 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
V_PHY(I,K,J)=(V(I+IHE(J),J,K)+V(I+IHW(J),J,K) &
& +V(I,J+1,K)+V(I,J-1,K)) &
& *0.25
IF ( K == KTS ) THEN
ULOWL(I,J) = U_PHY(I,K,J)
VLOWL(I,J) = V_PHY(I,K,J)
ENDIF
ENDDO
ENDDO
ENDDO
Expand Down Expand Up @@ -1382,6 +1403,9 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
& ,QSHLTR=QSHLTR,QZ0=QZ0 &
& ,ICOEF_SF=CONFIG_FLAGS%ICOEF_SF &
& ,LCURR_SF=CONFIG_FLAGS%LCURR_SF &!for gfdl-sf drag
& ,ZKMAX=ZKMAX,RIBN=RIBN &
& ,CHARN=CHARN,MSANG=MSANG,SCURX=SCURX,SCURY=SCURY &
& ,IWAVECPL=CONFIG_FLAGS%IWAVECPL &
#if (HWRF==1)
& ,pert_Cd=config_flags%pert_Cd &
& ,ens_random_seed=config_flags%ens_random_seed &
Expand Down Expand Up @@ -1584,6 +1608,10 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
!BSF & ,RQGBLTEN=RQGBLTEN & !BSF
& ,TSK=TSFC,XLAND=XLAND,ZNT=Z0 &
#if ( HWRF == 1 )
& ,MSANG=MSANG,SCURX=SCURX,SCURY=SCURY &
& ,IWAVECPL=CONFIG_FLAGS%IWAVECPL &
& ,LCURR_SF=CONFIG_FLAGS%LCURR_SF &

& ,MZNT=MZ0 &
#endif
& ,HT=SFCZ & !KWON
Expand Down Expand Up @@ -1647,6 +1675,22 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
& ,fasdas=fasdas &
& ,sf_urban_physics=CONFIG_FLAGS%SF_URBAN_PHYSICS)
!
!output PBL tendency
!
!$omp parallel do &
!$omp& private(i,j,k)
DO J=JMS,JME
DO K=KMS,KME
DO I=IMS,IME
DUBLDT(I,J,K)=DUDT_PHY(I,K,J)
DVBLDT(I,J,K)=DVDT_PHY(I,K,J)
DTHBLDT(I,J,K)=RTHBLTEN(I,K,J)
DQVBLDT(I,J,K)=RQVBLTEN(I,K,J)
ENDDO
ENDDO
ENDDO
!

!*** NOTE THAT THE EXCHANGE COEFFICIENTS FOR HEAT EXCH_H COMING OUT OF
!*** PBL_DRIVER ARE DEFINED AT THE TOPS OF THE LAYERS KTS TO KTE-1
!*** IF MODULE_BL_MYJPBL WAS INVOKED.
Expand Down Expand Up @@ -1959,18 +2003,12 @@ SUBROUTINE TURBL(NTSD,DT,NPHS,RESTRT &
MOIST(I,J,K,P_QV)=MAX(EPSQ,(MOIST(I,J,K,P_QV)+RQVBLTEN(I,K,J)*DTPHS) )
CWM(I,J,K)=0.
!
pbl_check1: IF (.NOT.ETAMP_PHYSICS) THEN
pbl_check1: IF (.NOT.ETAMP_PHYSICS) THEN
DO I_M=1,N_MOIST
IF(I_M==P_QC) THEN
MOIST(I,J,K,I_M)=MAX(EPSQ,(MOIST(I,J,K,I_M)+RQCBLTEN(I,K,J)*DTPHS) )
ELSE IF(I_M==P_QI) THEN
MOIST(I,J,K,I_M)=MAX(EPSQ,(MOIST(I,J,K,I_M)+RQIBLTEN(I,K,J)*DTPHS) )
!BSF ELSE IF(I_M==P_QS) THEN
!BSF MOIST(I,J,K,I_M)=MAX(EPSQ,(MOIST(I,J,K,I_M)+RQSBLTEN(I,K,J)*DTPHS) )
!BSF ELSE IF(I_M==P_QR) THEN
!BSF MOIST(I,J,K,I_M)=MAX(EPSQ,(MOIST(I,J,K,I_M)+RQRBLTEN(I,K,J)*DTPHS) )
!BSF ELSE IF(I_M==P_QG) THEN
!BSF MOIST(I,J,K,I_M)=MAX(EPSQ,(MOIST(I,J,K,I_M)+RQGBLTEN(I,K,J)*DTPHS) )
ENDIF
IF(I_M/=P_QV) CWM(I,J,K)=CWM(I,J,K)+MOIST(I,J,K,I_M)
ENDDO
Expand Down Expand Up @@ -2332,7 +2370,6 @@ SUBROUTINE CUCNVC(NTSD,DT,NCNVC,NRADS,NRADL &
REAL,DIMENSION(IMS:IME,JMS:JME,KMS:KME,N_MOIST) &
& ,INTENT(INOUT) :: MOIST
!
REAL,DIMENSION(IMS:IME,KMS:KME,JMS:JME),INTENT(INOUT) :: GD_CLOUD &
& ,GD_CLOUD2
INTEGER,DIMENSION(IMS:IME,JMS:JME),INTENT(INOUT) :: KTOP_DEEP
Expand Down
10 changes: 10 additions & 0 deletions dyn_nmm/module_initialize_real.F
Original file line number Diff line number Diff line change
Expand Up @@ -847,6 +847,16 @@ SUBROUTINE init_domain_nmm ( grid &

END IF ! <----- END OF VERTICAL INTERPOLATION PART ---->

DO j = jts, MIN(jde-1,jte) ! <--- Initialize the arrays from WW/Ocean Biju!
DO i = its, MIN(ide-1,ite)
grid%scurx(i,j) = 0.0
grid%scury(i,j) = 0.0
grid%charn(i,j) = 0.0185
grid%msang(i,j) = 0.0
grid%rchno(i,j) = 1e-03
grid%zsig1(i,j) = 20.0
END DO
END DO ! <----- END ---->

!! compute SST at each time if updating SST
if (config_flags%sst_update == 1) then
Expand Down
Loading

0 comments on commit d60645c

Please sign in to comment.