diff --git a/physics/CONV/SAMF/samfdeepcnv.f b/physics/CONV/SAMF/samfdeepcnv.f index 3ad067657..9522e8c64 100644 --- a/physics/CONV/SAMF/samfdeepcnv.f +++ b/physics/CONV/SAMF/samfdeepcnv.f @@ -8,7 +8,8 @@ module samfdeepcnv use samfcnv_aerosols, only : samfdeepcnv_aerosols use progsigma, only : progsigma_calc - + use progomega, only : progomega_calc + contains subroutine samfdeepcnv_init(imfdeepcnv,imfdeepcnv_samf, & @@ -77,14 +78,14 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & & eps,epsm1,fv,grav,hvap,rd,rv, & & t0c,delt,ntk,ntr,delp, & & prslp,psp,phil,qtr,prevsq,q,q1,t1,u1,v1,fscav, & - & hwrf_samfdeep,progsigma,cldwrk,rn,kbot,ktop,kcnv, & + & hwrf_samfdeep,progsigma,progomega,cldwrk,rn,kbot,ktop,kcnv, & & islimsk,garea,dot,ncloud,hpbl,ud_mf,dd_mf,dt_mf,cnvw,cnvc, & & QLCN, QICN, w_upi, cf_upi, CNV_MFD, & & CNV_DQLDT,CLCN,CNV_FICE,CNV_NDROP,CNV_NICE,mp_phys,mp_phys_mg,& & clam,c0s,c1,betal,betas,evef,pgcon,asolfac, & & do_ca, ca_closure, ca_entr, ca_trigger, nthresh,ca_deep, & - & rainevap,sigmain,sigmaout,betadcu,betamcu,betascu, & - & maxMF, do_mynnedmf,errmsg,errflg) + & rainevap,sigmain,sigmaout,omegain,omegaout, & + & betadcu,betamcu,betascu,maxMF,do_mynnedmf,errmsg,errflg) ! use machine , only : kind_phys use funcphys , only : fpvs @@ -100,16 +101,17 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & & prslp(:,:), garea(:), hpbl(:), dot(:,:), phil(:,:) real(kind=kind_phys), dimension(:), intent(in) :: fscav logical, intent(in) :: first_time_step,restart,hwrf_samfdeep, & - & progsigma,do_mynnedmf + & progsigma,progomega,do_mynnedmf real(kind=kind_phys), intent(in) :: nthresh,betadcu,betamcu, & & betascu real(kind=kind_phys), intent(in), optional :: ca_deep(:) real(kind=kind_phys), intent(in), optional :: sigmain(:,:), & - & qmicro(:,:), prevsq(:,:) + & qmicro(:,:), prevsq(:,:), omegain(:,:) real(kind=kind_phys), intent(in) :: tmf(:,:,:),q(:,:) real(kind=kind_phys), dimension (:), intent(in), optional :: maxMF real(kind=kind_phys), intent(out) :: rainevap(:) - real(kind=kind_phys), intent(out), optional :: sigmaout(:,:) + real(kind=kind_phys), intent(out), optional :: sigmaout(:,:), & + & omegaout(:,:) logical, intent(in) :: do_ca,ca_closure,ca_entr,ca_trigger integer, intent(inout) :: kcnv(:) ! DH* TODO - check dimensions of qtr, ntr+2 correct? *DH @@ -216,7 +218,7 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & ! parameters for prognostic sigma closure real(kind=kind_phys) omega_u(im,km),zdqca(im,km),tmfq(im,km), & omegac(im),zeta(im,km),dbyo1(im,km),sigmab(im),qadv(im,km), - & sigmaoutx(im) + & sigmaoutx(im),tentr(im,km) real(kind=kind_phys) gravinv,invdelt,sigmind,sigminm,sigmins parameter(sigmind=0.01,sigmins=0.03,sigminm=0.01) logical flag_shallow, flag_mid @@ -333,6 +335,7 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & c----------------------------------------------------------------------- !> ## Compute preliminary quantities needed for static, dynamic, and feedback control portions of the algorithm. !> - Convert input pressure terms to centibar units. + !************************************************************************ ! convert input Pa terms to Cb terms -- Moorthi ps = psp * 0.001 @@ -1131,7 +1134,8 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & do k = 2, km1 do i=1,im if(cnvflg(i) .and. - & (k > kbcon(i) .and. k < kmax(i))) then + & (k > kbcon(i) .and. k < kmax(i))) then + tentr(i,k)=xlamue(i,k)*fent1(i,k) tem = cxlamet(i) * frh(i,k) * fent2(i,k) xlamue(i,k) = xlamue(i,k)*fent1(i,k) + tem tem1 = cxlamdt(i) * frh(i,k) @@ -1743,43 +1747,62 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & enddo ! ! compute updraft velocity square(wu2) -!> - Calculate updraft velocity square(wu2) according to Han et al.'s (2017) \cite han_et_al_2017 equation 7. -! +!> - Calculate diagnostic updraft velocity square(wu2) according to Han et al.'s (2017) \cite han_et_al_2017 equation 7. +!> - if progomega = true, calculate prognostic updraft velocity (Pa/s) according to progomega routine. + if (hwrf_samfdeep) then - do i = 1, im - if (cnvflg(i)) then - k = kbcon1(i) - tem = po(i,k) / (rd * to(i,k)) - wucb = -0.01 * dot(i,k) / (tem * grav) - if(wucb.gt.0.) then - wu2(i,k) = wucb * wucb - else - wu2(i,k) = 0. - endif - endif - enddo - endif -! - do k = 2, km1 - do i = 1, im - if (cnvflg(i)) then - if(k > kbcon1(i) .and. k < ktcon(i)) then - dz = zi(i,k) - zi(i,k-1) - tem = 0.25 * bb1 * (drag(i,k-1)+drag(i,k)) * dz - tem1 = 0.5 * bb2 * (buo(i,k-1)+buo(i,k)) - tem2 = wush(i,k) * sqrt(wu2(i,k-1)) - tem2 = (tem1 - tem2) * dz - ptem = (1. - tem) * wu2(i,k-1) - ptem1 = 1. + tem - wu2(i,k) = (ptem + tem2) / ptem1 - wu2(i,k) = max(wu2(i,k), 0.) + do i = 1, im + if (cnvflg(i)) then + k = kbcon1(i) + tem = po(i,k) / (rd * to(i,k)) + wucb = -0.01 * dot(i,k) / (tem * grav) + if(wucb.gt.0.) then + wu2(i,k) = wucb * wucb + else + wu2(i,k) = 0. + endif endif - endif - enddo - enddo - - if(progsigma)then - do k = 2, km1 + enddo + endif +! + if (progomega) then + call progomega_calc(first_time_step,restart,im,km, + & kbcon1,ktcon,omegain,delt,del,zi,cnvflg,omegaout, + & grav,buo,drag,wush,tentr,bb1,bb2) + do k = 1, km + do i = 1, im + if (cnvflg(i)) then + omega_u(i,k)=omegaout(i,k) + omega_u(i,k)=MAX(omega_u(i,k),-80.) +! Convert to m/s for use in convective time-scale: + rho = po(i,k)*100. / (rd * to(i,k)) + tem = (-omega_u(i,k)) / ((rho * grav)) + wu2(i,k) = tem**2 + wu2(i,k) = max(wu2(i,k), 0.) + endif + enddo + enddo + else +! diagnostic method: + do k = 2, km1 + do i = 1, im + if (cnvflg(i)) then + if(k > kbcon1(i) .and. k < ktcon(i)) then + dz = zi(i,k) - zi(i,k-1) + tem = 0.25 * bb1 * (drag(i,k-1)+drag(i,k)) * dz + tem1 = 0.5 * bb2 * (buo(i,k-1)+buo(i,k)) + tem2 = wush(i,k) * sqrt(wu2(i,k-1)) + tem2 = (tem1 - tem2) * dz + ptem = (1. - tem) * wu2(i,k-1) + ptem1 = 1. + tem + wu2(i,k) = (ptem + tem2) / ptem1 + wu2(i,k) = max(wu2(i,k), 0.) + endif + endif + enddo + enddo +! convert to Pa/s for use in closure + do k = 1, km do i = 1, im if (cnvflg(i)) then if(k > kbcon1(i) .and. k < ktcon(i)) then @@ -1790,10 +1813,11 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & endif enddo enddo - endif + + endif !progomega + ! ! compute updraft velocity average over the whole cumulus -! !> - Calculate the mean updraft velocity within the cloud (wc). do i = 1, im wc(i) = 0. @@ -1821,11 +1845,10 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & val = 1.e-4 if (wc(i) < val) cnvflg(i)=.false. endif - enddo + enddo c - !> - For progsigma = T, calculate the mean updraft velocity within the cloud (omegac),cast in pressure coordinates. - if(progsigma)then + if(progsigma)then do i = 1, im omegac(i) = 0. sumx(i) = 0. @@ -2912,10 +2935,9 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, & advfac(i) = min(advfac(i), 1.) endif enddo - + !> - From Bengtsson et al. (2022) \cite Bengtsson_2022 prognostic closure scheme, equation 8, call progsigma_calc() to compute updraft area fraction based on a moisture budget if(progsigma)then - !Initial computations, dynamic q-tendency if(first_time_step .and. .not.restart)then do k = 1,km diff --git a/physics/CONV/SAMF/samfdeepcnv.meta b/physics/CONV/SAMF/samfdeepcnv.meta index 3652a0d27..f3fcb424b 100644 --- a/physics/CONV/SAMF/samfdeepcnv.meta +++ b/physics/CONV/SAMF/samfdeepcnv.meta @@ -1,7 +1,7 @@ [ccpp-table-properties] name = samfdeepcnv type = scheme - dependencies = ../../tools/funcphys.f90,../../hooks/machine.F,samfaerosols.F,../progsigma_calc.f90 + dependencies = ../../tools/funcphys.f90,../../hooks/machine.F,samfaerosols.F,../progsigma_calc.f90,../progomega_calc.f90 ######################################################################## [ccpp-arg-table] @@ -321,6 +321,13 @@ dimensions = () type = logical intent = in +[progomega] + standard_name = do_prognostic_updraft_velocity + long_name = flag for prognostic omega in cumuls scheme + units = flag + dimensions = () + type = logical + intent = in [cldwrk] standard_name = cloud_work_function long_name = cloud work function @@ -455,6 +462,24 @@ kind = kind_phys intent = out optional = True +[omegain] + standard_name = prognostic_updraft_velocity_in_convection + long_name = convective updraft velocity + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = in + optional = True +[omegaout] + standard_name = updraft_velocity_updated_by_physics + long_name = convective updraft velocity updated by physics + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = out + optional = True [betascu] standard_name = tuning_param_for_shallow_cu long_name = tuning param for shallow cu in case prognostic closure is used diff --git a/physics/CONV/SAMF/samfshalcnv.f b/physics/CONV/SAMF/samfshalcnv.f index ce783ea15..b58309d6e 100644 --- a/physics/CONV/SAMF/samfshalcnv.f +++ b/physics/CONV/SAMF/samfshalcnv.f @@ -5,7 +5,7 @@ module samfshalcnv use samfcnv_aerosols, only : samfshalcnv_aerosols use progsigma, only : progsigma_calc - + use progomega, only : progomega_calc contains subroutine samfshalcnv_init(imfshalcnv, imfshalcnv_samf, & @@ -52,12 +52,13 @@ end subroutine samfshalcnv_init subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & & eps,epsm1,fv,grav,hvap,rd,rv, & & t0c,delt,ntk,ntr,delp,first_time_step,restart, & - & tmf,qmicro,progsigma, & + & tmf,qmicro,progsigma,progomega, & & prslp,psp,phil,qtr,prevsq,q,q1,t1,u1,v1,fscav, & & rn,kbot,ktop,kcnv,islimsk,garea, & & dot,ncloud,hpbl,ud_mf,dt_mf,cnvw,cnvc, & & clam,c0s,c1,evef,pgcon,asolfac,hwrf_samfshal, & - & sigmain,sigmaout,betadcu,betamcu,betascu,errmsg,errflg) + & sigmain,sigmaout,omegain,omegaout,betadcu,betamcu,betascu, & + & errmsg,errflg) ! use machine , only : kind_phys use funcphys , only : fpvs @@ -75,7 +76,8 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & & tmf(:,:,:), q(:,:) real(kind=kind_phys), intent(in), optional :: qmicro(:,:), & & prevsq(:,:) - real(kind=kind_phys), intent(in), optional :: sigmain(:,:) + real(kind=kind_phys), intent(in), optional :: sigmain(:,:), & + & omegain(:,:) ! real(kind=kind_phys), dimension(:), intent(in) :: fscav integer, intent(inout) :: kcnv(:) @@ -88,11 +90,11 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & & cnvw(:,:), cnvc(:,:), dt_mf(:,:) ! real(kind=kind_phys), intent(out), optional :: ud_mf(:,:), & - & sigmaout(:,:) + & sigmaout(:,:), omegaout(:,:) real(kind=kind_phys), intent(in) :: clam, c0s, c1, & & asolfac, evef, pgcon logical, intent(in) :: hwrf_samfshal,first_time_step, & - & restart,progsigma + & restart,progsigma,progomega character(len=*), intent(out) :: errmsg integer, intent(out) :: errflg ! @@ -1478,7 +1480,7 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & ! ! compute updraft velocity square(wu2) !> - Calculate updraft velocity square(wu2) according to Han et al.'s (2017) \cite han_et_al_2017 equation 7. -! +!!> - if progomega = true, calculate prognostic updraft velocity (Pa/s) according to progomega routine. if (hwrf_samfshal) then do i = 1, im if (cnvflg(i)) then @@ -1493,26 +1495,46 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & endif enddo endif - do k = 2, km1 - do i = 1, im - if (cnvflg(i)) then - if(k > kbcon1(i) .and. k < ktcon(i)) then - dz = zi(i,k) - zi(i,k-1) - tem = 0.25 * bb1 * (drag(i,k-1)+drag(i,k)) * dz - tem1 = 0.5 * bb2 * (buo(i,k-1)+buo(i,k)) - tem2 = wush(i,k) * sqrt(wu2(i,k-1)) - tem2 = (tem1 - tem2) * dz - ptem = (1. - tem) * wu2(i,k-1) - ptem1 = 1. + tem - wu2(i,k) = (ptem + tem2) / ptem1 - wu2(i,k) = max(wu2(i,k), 0.) - endif - endif - enddo - enddo ! - if(progsigma)then - do k = 2, km1 + if (progomega) then + call progomega_calc(first_time_step,restart,im,km, + & kbcon1,ktcon,omegain,delt,del,zi,cnvflg,omegaout, + & grav,buo,drag,wush,xlamue,bb1,bb2) + do k = 1, km + do i = 1, im + if (cnvflg(i)) then + omega_u(i,k)=omegaout(i,k) + omega_u(i,k)=MAX(omega_u(i,k),-80.) +! Convert to m/s for use in convective time-scale: + rho = po(i,k)*100. / (rd * to(i,k)) + tem = (-omega_u(i,k)) / ((rho * grav)) + wu2(i,k) = tem**2 + wu2(i,k) = max(wu2(i,k), 0.) + endif + enddo + enddo + + else +! diagnostic updraft velocity + do k = 2, km1 + do i = 1, im + if (cnvflg(i)) then + if(k > kbcon1(i) .and. k < ktcon(i)) then + dz = zi(i,k) - zi(i,k-1) + tem = 0.25 * bb1 * (drag(i,k-1)+drag(i,k)) * dz + tem1 = 0.5 * bb2 * (buo(i,k-1)+buo(i,k)) + tem2 = wush(i,k) * sqrt(wu2(i,k-1)) + tem2 = (tem1 - tem2) * dz + ptem = (1. - tem) * wu2(i,k-1) + ptem1 = 1. + tem + wu2(i,k) = (ptem + tem2) / ptem1 + wu2(i,k) = max(wu2(i,k), 0.) + endif + endif + enddo + enddo +!convert to Pa/s for use in closure + do k = 2, km1 do i = 1, im if (cnvflg(i)) then if(k > kbcon1(i) .and. k < ktcon(i)) then @@ -1523,8 +1545,9 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, & endif enddo enddo - endif + endif !progomega + ! compute updraft velocity averaged over the whole cumulus ! !> - Calculate the mean updraft velocity within the cloud (wc). diff --git a/physics/CONV/SAMF/samfshalcnv.meta b/physics/CONV/SAMF/samfshalcnv.meta index 4dfa8ac20..ebd27d907 100644 --- a/physics/CONV/SAMF/samfshalcnv.meta +++ b/physics/CONV/SAMF/samfshalcnv.meta @@ -1,7 +1,7 @@ [ccpp-table-properties] name = samfshalcnv type = scheme - dependencies = ../../tools/funcphys.f90,../../hooks/machine.F,samfaerosols.F,../progsigma_calc.f90 + dependencies = ../../tools/funcphys.f90,../../hooks/machine.F,samfaerosols.F,../progsigma_calc.f90,../progomega_calc.f90 ######################################################################## [ccpp-arg-table] @@ -469,6 +469,13 @@ dimensions = () type = logical intent = in +[progomega] + standard_name = do_prognostic_updraft_velocity + long_name = flag for prognostic omega in cumuls scheme + units = flag + dimensions = () + type = logical + intent = in [sigmain] standard_name = prognostic_updraft_area_fraction_in_convection long_name = convective updraft area fraction @@ -487,6 +494,24 @@ kind = kind_phys intent = out optional = True +[omegain] + standard_name = prognostic_updraft_velocity_in_convection + long_name = convective updraft velocity + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = in + optional = True +[omegaout] + standard_name = updraft_velocity_updated_by_physics + long_name = convective updraft velocity updated by physics + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = out + optional = True [betascu] standard_name = tuning_param_for_shallow_cu long_name = tuning param for shallow cu in case prognostic closure is used diff --git a/physics/CONV/progomega_calc.f90 b/physics/CONV/progomega_calc.f90 new file mode 100644 index 000000000..14139c1b7 --- /dev/null +++ b/physics/CONV/progomega_calc.f90 @@ -0,0 +1,117 @@ + module progomega + + implicit none + + public progomega_calc + + contains + +!>\file progomega_calc.f90 +!! This file contains the subroutine that calculates the prognostic +!! updraft vertical velocity that is used for closure computations in +!! saSAS and C3 deep and shallow convection. + +!>\ingroup SAMFdeep +!>\ingroup SAMF_shal +!> This subroutine computes a prognostic updraft vertical velocity +!! used in the closure computations in the samfdeepcnv.f and cu_c3_conv.f scheme +!! This subroutine computes a prognostic updraft vertical velocity +!! used in the closure computations in the samfshalcnv. and cu_c3_shal scheme +!!\section gen_progomega progomega_calc General Algorithm + + subroutine progomega_calc(first_time_step,flag_restart,im,km,kbcon1,ktcon,omegain,delt,del, & + zi,cnvflg,omegaout,grav,buo,drag,wush,tentr,bb1,bb2) + + use machine, only : kind_phys + use funcphys, only : fpvs + implicit none + + integer, intent(in) :: im, km + integer, intent(in) :: kbcon1(im),ktcon(im) + real(kind=kind_phys), intent(in) :: delt,grav,bb1,bb2 + real(kind=kind_phys), intent(in) :: omegain(im,km), del(im,km),zi(im,km) + real(kind=kind_phys), intent(in) :: drag(im,km),buo(im,km),wush(im,km),tentr(im,km) + real(kind=kind_phys), intent(out) :: omegaout(im,km) + logical, intent(in) :: cnvflg(im),first_time_step,flag_restart + real(kind=kind_phys) :: termA(im,km),termB(im,km),termC(im,km),omega(im,km) + real(kind=kind_phys) :: RHS(im,km),Kd(im,km) + real(kind=kind_phys) :: dp,dz,entrn,Kdn,discr,wush_pa,lbb1,lbb2,lbb3 + integer :: i,k + + entrn = 0.8E-4 !0.5E-4 !m^-1 + Kdn = 0.5E-4 !2.9E-4 !m^-1 + lbb1 = 0.5 !1.0 + lbb2 = 3.2 !3.0 + lbb3 = 0.5 !0.5 + + + !Initialization 2D + do k = 1,km + do i = 1,im + termA(i,k)=0. + termB(i,k)=0. + termC(i,k)=0. + RHS(i,k)=0. + omega(i,k)=omegain(i,k) + enddo + enddo + + if(first_time_step .and. .not. flag_restart)then + do k = 1,km + do i = 1,im + if(cnvflg(i))then + omega(i,k)=-1.2 !Pa/s + endif + enddo + enddo + endif + + ! Compute RHS terms + !Lisa Bengtsson: ! compute updraft velocity omega (Pa/s) + !> - Expand the steady state solution of updraft velocity from Han et al.'s (2017) + !> \cite han_et_al_2017 equation 7 to include the time-derivative, and an aerodynamic + !> drag term from Gueremy 2016. + !> Solve using implicit time-stepping scheme, solving the quadratic equation for omega. + + do k = 2, km + do i = 1, im + if (cnvflg(i)) then + if (k > kbcon1(i) .and. k < ktcon(i)) then + + ! Aerodynamic drag parameter + Kd(i,k) = (tentr(i,k)/entrn)*Kdn + + ! Scale by dp/dz to have equation in Pa/s + !(dp/dz > 0) + dp = 1000. * del(i,k) + dz = zi(i,k+1) - zi(i,k) + + !termA - Ensures quadratic damping (drag). + !termB - Ensures linear damping from wind shear. + !termC - Adds buoyancy forcing + + !Coefficients for the quadratic equation + termA(i,k) = delt * ((lbb1 * drag(i,k) * (dp/dz)) + (Kd(i,k) * (dp/dz))) + termB(i,k) = -1.0 - delt * lbb3 * wush(i,k) * dp/dz + termC(i,k) = omega(i,k) - delt * lbb2 * buo(i,k) * (dp/dz) & + - delt * omega(i,k) * (omega(i,k-1) - omega(i,k)) / dp + !Compute the discriminant + discr = termB(i,k)**2 - 4.0 * termA(i,k) * termC(i,k) + + ! Check if discriminant is non-negative + if (discr >= 0.0) then + ! Solve quadratic equation, take the negative root + omegaout(i,k) = (-termB(i,k) - sqrt(discr)) / (2.0 * termA(i,k)) + else + omegaout(i,k) = omega(i,k) + endif + + omegaout(i,k) = MAX(MIN(omegaout(i,k), -1.2), -80.0) + + endif + endif + enddo + enddo + + end subroutine progomega_calc +end module progomega diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.F90 b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.F90 index da255adc8..62e5f4862 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.F90 +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.F90 @@ -15,8 +15,8 @@ subroutine GFS_DCNV_generic_post_run (im, levs, lssav, ldiag3d, qdiag3d, ras, & index_of_temperature, index_of_x_wind, index_of_y_wind, ntqv, gq0, save_q, & cnvw, cnvc, cnvw_phy_f3d, cnvc_phy_f3d, flag_for_dcnv_generic_tend, & ntcw,ntiw,ntclamt,ntrw,ntsw,ntrnc,ntsnc,ntgl, & - ntgnc, nthl, nthnc, nthv, ntgv, ntrz, ntgz, nthz, ntsigma, ntrac,clw, & - satmedmf, trans_trac, errmsg, errflg) + ntgnc, nthl, nthnc, nthv, ntgv, ntrz, ntgz, nthz, ntsigma, ntomega, & + ntrac,clw,satmedmf, trans_trac, errmsg, errflg) use machine, only: kind_phys @@ -47,7 +47,7 @@ subroutine GFS_DCNV_generic_post_run (im, levs, lssav, ldiag3d, qdiag3d, ras, & index_of_x_wind, index_of_y_wind, ntqv integer, intent(in) :: ntcw,ntiw,ntclamt,ntrw,ntsw,ntrnc,ntsnc,ntgl, & ntgnc, nthl, nthnc, nthv, ntgv, ntrz, ntgz, nthz, & - ntsigma, ntrac + ntsigma, ntomega, ntrac real(kind=kind_phys), dimension(:,:,:), intent(in) :: clw @@ -115,7 +115,7 @@ subroutine GFS_DCNV_generic_post_run (im, levs, lssav, ldiag3d, qdiag3d, ras, & n /= ntsnc .and. n /= ntgl .and. n /= ntgnc .and. & n /= nthl .and. n /= nthnc .and. n /= nthv .and. & n /= ntrz .and. n /= ntgz .and. n /= nthz .and. & - n /= ntgv .and. n /= ntsigma) then + n /= ntgv .and. n /= ntsigma .and. n /= ntomega) then tracers = tracers + 1 idtend = dtidx(100+n,index_of_process_dcnv) if(idtend>0) then diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.meta b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.meta index 30bc93ccd..1498afa53 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.meta +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_post.meta @@ -370,6 +370,13 @@ dimensions = () type = integer intent = in +[ntomega] + standard_name = index_of_updraft_velocity_in_tracer_concentration_array + long_name = tracer index of updraft_velocity + units = index + dimensions = () + type = integer + intent = in [ntcw] standard_name = index_of_cloud_liquid_water_mixing_ratio_in_tracer_concentration_array long_name = tracer index for cloud condensate (or liquid water) diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.F90 b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.F90 index 1dd3aafc7..7bb47ac9b 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.F90 +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.F90 @@ -14,7 +14,7 @@ subroutine GFS_DCNV_generic_pre_run (im, levs, ldiag3d, qdiag3d, do_cnvgwd, cplc save_u, save_v, save_t, save_q, clw, & ntcw,ntiw,ntclamt,ntrw,ntsw,ntrnc,ntsnc,ntgl, & ntgnc, nthl, nthnc, nthv, ntgv, & - ntrz, ntgz, nthz, ntsigma, & + ntrz, ntgz, nthz, ntsigma, ntomega, & cscnv, satmedmf, trans_trac, ras, ntrac, & dtidx, index_of_process_dcnv, errmsg, errflg) @@ -24,7 +24,7 @@ subroutine GFS_DCNV_generic_pre_run (im, levs, ldiag3d, qdiag3d, do_cnvgwd, cplc integer, intent(in) :: im, levs, nsamftrac, ntqv, index_of_process_dcnv, dtidx(:,:), & ntcw,ntiw,ntclamt,ntrw,ntsw,ntrnc,ntsnc,ntgl,ntrac,ntgnc,nthl,nthnc,nthv,ntgv, & - ntrz, ntgz, nthz, ntsigma + ntrz, ntgz, nthz, ntsigma, ntomega logical, intent(in) :: ldiag3d, qdiag3d, do_cnvgwd, cplchm real(kind=kind_phys), dimension(:,:), intent(in) :: gu0 real(kind=kind_phys), dimension(:,:), intent(in) :: gv0 @@ -71,7 +71,7 @@ subroutine GFS_DCNV_generic_pre_run (im, levs, ldiag3d, qdiag3d, do_cnvgwd, cplc n /= ntsnc .and. n /= ntgl .and. n /= ntgnc .and. & n /= nthl .and. n /= nthnc .and. n /= nthv .and. & n /= ntrz .and. n /= ntgz .and. n /= nthz .and. & - n /= ntgv .and. n/= ntsigma) then + n /= ntgv .and. n/= ntsigma .and. n /= ntomega) then tracers = tracers + 1 if(dtidx(100+n,index_of_process_dcnv)>0) then save_q(:,:,n) = clw(:,:,tracers) diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.meta b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.meta index b8be36596..15fb106e7 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.meta +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_DCNV_generic_pre.meta @@ -176,6 +176,13 @@ dimensions = () type = integer intent = in +[ntomega] + standard_name = index_of_updraft_velocity_in_tracer_concentration_array + long_name = tracer index of updraft_velocity + units = index + dimensions = () + type = integer + intent = in [ntcw] standard_name = index_of_cloud_liquid_water_mixing_ratio_in_tracer_concentration_array long_name = tracer index for cloud condensate (or liquid water) diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.F90 b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.F90 index bc99e7fff..d5278bd42 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.F90 +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.F90 @@ -11,12 +11,12 @@ module GFS_suite_interstitial_3 subroutine GFS_suite_interstitial_3_run (otsptflag, & im, levs, nn, cscnv,imfshalcnv, imfdeepcnv, & imfshalcnv_samf, imfdeepcnv_samf, imfdeepcnv_c3, & - imfshalcnv_c3,progsigma, & + imfshalcnv_c3,progsigma,progomega, & first_time_step, restart, & satmedmf, trans_trac, do_shoc, ltaerosol, ntrac, ntcw, & ntiw, ntclamt, ntrw, ntsw, ntrnc, ntsnc, ntgl, ntgnc, & xlon, xlat, gt0, gq0, sigmain,sigmaout,qmicro, & - imp_physics, imp_physics_mg, & + omegain,omegaout,imp_physics, imp_physics_mg, & imp_physics_zhao_carr, imp_physics_zhao_carr_pdf, & imp_physics_gfdl, imp_physics_thompson, dtidx, ntlnc, & imp_physics_wsm6, imp_physics_fer_hires, prsi, ntinc, & @@ -38,7 +38,7 @@ subroutine GFS_suite_interstitial_3_run (otsptflag, & imp_physics_nssl, me, index_of_process_conv_trans integer, intent(in ), dimension(:) :: islmsk, kpbl, kinver logical, intent(in ) :: cscnv, satmedmf, trans_trac, do_shoc, ltaerosol, ras, progsigma - logical, intent(in ) :: first_time_step, restart + logical, intent(in ) :: first_time_step, restart, progomega integer, intent(in ) :: imfshalcnv, imfdeepcnv, imfshalcnv_samf,imfdeepcnv_samf integer, intent(in ) :: imfshalcnv_c3,imfdeepcnv_c3 integer, intent(in) :: ntinc, ntlnc @@ -54,8 +54,8 @@ subroutine GFS_suite_interstitial_3_run (otsptflag, & real(kind=kind_phys), intent(in ), dimension(:,:) :: gt0 real(kind=kind_phys), intent(in ), dimension(:,:,:) :: gq0 - real(kind=kind_phys), intent(inout ), dimension(:,:), optional :: sigmain - real(kind=kind_phys), intent(inout ), dimension(:,:), optional :: sigmaout, qmicro + real(kind=kind_phys), intent(inout ), dimension(:,:), optional :: sigmain, omegain + real(kind=kind_phys), intent(inout ), dimension(:,:), optional :: sigmaout, qmicro, omegaout real(kind=kind_phys), intent(inout), dimension(:,:) :: rhc, save_qc ! save_qi is not allocated for Zhao-Carr MP real(kind=kind_phys), intent(inout), dimension(:,:) :: save_qi @@ -81,7 +81,7 @@ subroutine GFS_suite_interstitial_3_run (otsptflag, & errmsg = '' errflg = 0 - ! In case of using prognostic updraf area fraction, initialize area fraction here + ! In case of using prognostic updraft area fraction, initialize area fraction here ! since progsigma_calc is called from both deep and shallow schemes. if(((imfshalcnv == imfshalcnv_samf) .or. (imfdeepcnv == imfdeepcnv_samf) & .or. (imfshalcnv == imfshalcnv_c3) .or. (imfdeepcnv == imfdeepcnv_c3)) & @@ -102,7 +102,26 @@ subroutine GFS_suite_interstitial_3_run (otsptflag, & enddo endif - + ! In case of using prognostic updraft velocity, initialize updraft velocity here + ! since progomega_calc is called from both deep and shallow schemes. + if(((imfshalcnv == imfshalcnv_samf) .or. (imfdeepcnv == imfdeepcnv_samf) & + .or. (imfshalcnv == imfshalcnv_c3) .or. (imfdeepcnv == imfdeepcnv_c3)) & + .and. progomega)then + if(first_time_step .and. .not. restart)then + do k=1,levs + do i=1,im + omegain(i,k)=0.0 + omegaout(i,k)=0.0 + enddo + enddo + endif + do k=1,levs + do i=1,im + omegaout(i,k)=0.0 + enddo + enddo + endif + if (cscnv .or. satmedmf .or. trans_trac .or. ras) then tracers = 2 do n=2,ntrac diff --git a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.meta b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.meta index d1e9d4d50..c79182679 100644 --- a/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.meta +++ b/physics/Interstitials/UFS_SCM_NEPTUNE/GFS_suite_interstitial_3.meta @@ -92,6 +92,13 @@ dimensions = () type = logical intent = in +[progomega] + standard_name = do_prognostic_updraft_velocity + long_name = flag for prognostic omega in cumuls scheme + units = flag + dimensions = () + type = logical + intent = in [first_time_step] standard_name = flag_for_first_timestep long_name = flag for first time step for time integration loop (cold/warmstart) @@ -263,6 +270,24 @@ kind = kind_phys intent = out optional = True +[omegain] + standard_name = prognostic_updraft_velocity_in_convection + long_name = convective updraft velocity + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = in + optional = True +[omegaout] + standard_name = updraft_velocity_updated_by_physics + long_name = convective updraft velocity updated by physics + units = frac + dimensions = (horizontal_loop_extent,vertical_layer_dimension) + type = real + kind = kind_phys + intent = out + optional = True [imp_physics] standard_name = control_for_microphysics_scheme long_name = choice of microphysics scheme