From 96cee64c1f753d474b3eccfdaf11747a09d35207 Mon Sep 17 00:00:00 2001 From: "Jun.Wang" Date: Mon, 26 Aug 2019 21:03:55 +0000 Subject: [PATCH 1/5] add option to output omega --- driver/fvGFS/fv_nggps_diag.F90 | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/driver/fvGFS/fv_nggps_diag.F90 b/driver/fvGFS/fv_nggps_diag.F90 index f8c8f94b9..01066f18e 100644 --- a/driver/fvGFS/fv_nggps_diag.F90 +++ b/driver/fvGFS/fv_nggps_diag.F90 @@ -93,13 +93,13 @@ module fv_nggps_diags_mod real, parameter:: stndrd_atmos_lapse = 0.0065 logical master - integer :: id_ua, id_va, id_pt, id_delp, id_pfhy, id_pfnh - integer :: id_w, id_delz, id_diss, id_ps, id_hs, id_dbz + integer :: id_ua, id_va, id_pt, id_delp, id_pfhy, id_pfnh + integer :: id_w, id_delz, id_diss, id_ps, id_hs, id_dbz, id_omga integer :: kstt_ua, kstt_va, kstt_pt, kstt_delp, kstt_pfhy integer :: kstt_pfnh, kstt_w, kstt_delz, kstt_diss, kstt_ps,kstt_hs integer :: kend_ua, kend_va, kend_pt, kend_delp, kend_pfhy integer :: kend_pfnh, kend_w, kend_delz, kend_diss, kend_ps,kend_hs - integer :: kstt_dbz, kend_dbz + integer :: kstt_dbz, kend_dbz, kstt_omga, kend_omga integer :: kstt_windvect, kend_windvect integer :: id_wmaxup,id_wmaxdn,kstt_wup, kend_wup,kstt_wdn,kend_wdn integer :: id_uhmax03,id_uhmin03,id_uhmax25,id_uhmin25,id_maxvort01 @@ -236,6 +236,13 @@ subroutine fv_nggps_diag_init(Atm, axes, Time) endif endif + id_omga = register_diag_field ( trim(file_name), 'omga', axes(1:3), Time, & + 'Vertical pressure velocity', 'pa/sec', missing_value=missing_value ) + if (id_omga>0) then + kstt_omga = nlevs+1; kend_omga = nlevs+npzo + nlevs = nlevs + npzo + endif + id_pt = register_diag_field ( trim(file_name), 'temp', axes(1:3), Time, & 'temperature', 'K', missing_value=missing_value, range=trange ) if (id_pt>0) then @@ -482,6 +489,11 @@ subroutine fv_nggps_diag(Atm, zvir, Time) call store_data(id_w, Atm(n)%w(isco:ieco,jsco:jeco,:), Time, kstt_w, kend_w) endif + !--- OMGA (non-hydrostatic) + if ( id_omga>0 ) then + call store_data(id_omga, Atm(n)%omga(isco:ieco,jsco:jeco,:), Time, kstt_omga, kend_omga) + endif + !--- TEMPERATURE if(id_pt > 0) call store_data(id_pt, Atm(n)%pt(isco:ieco,jsco:jeco,:), Time, kstt_pt, kend_pt) @@ -1172,6 +1184,13 @@ subroutine fv_dyn_bundle_setup(axes, dyn_bundle, fcst_grid, quilting, rc) if(rc==0) num_field_dyn=num_field_dyn+1 endif endif +! + if( id_omga>0 ) then + call find_outputname(trim(file_name),'omga',output_name) + call add_field_to_bundle(trim(output_name),'Vertical pressure velocity', 'pa/sec', "time: point", & + axes(1:3), fcst_grid, kstt_omga,kend_omga, dyn_bundle, output_file, rcd=rc) + if(rc==0) num_field_dyn=num_field_dyn+1 + endif ! if(id_pt > 0) then call find_outputname(trim(file_name),'temp',output_name) From c86c32c6e112a106f551cbe498eccec199ee4c11 Mon Sep 17 00:00:00 2001 From: "fanglin.yang" Date: Thu, 5 Sep 2019 19:24:09 +0000 Subject: [PATCH 2/5] VLab Issue #68141 modified: docs/FV3_citations.bib modified: model/fv_cmp.F90 1) Add an option (namelist parameter: intqs) to use temperature instead of the liquid frozen temperature to calculate saturation mixing ratio in deriving GFDLMP PDF cloud cover. 2) Add a literature reference. --- docs/FV3_citations.bib | 10 ++++++++++ model/fv_cmp.F90 | 17 +++++++++++------ 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/docs/FV3_citations.bib b/docs/FV3_citations.bib index 825323bae..074367fb9 100644 --- a/docs/FV3_citations.bib +++ b/docs/FV3_citations.bib @@ -33,6 +33,16 @@ @article{chen2013seasonal doi={10.1175/JCLI-D-12-00061.1} } +@article{zhou2019toward, + title={Toward Convective-Scale Prediction within the Next Generation Global Prediction System}, + author={Zhou, Linjiong and Lin, Shian-Jiann and Chen, Jan-Huey and Harris, Lucas M. and Chen, Xi and Rees, Shannon L.}, + journal={Bulletin of the American Meteorological Society}, + volume={100}, + issue={7}, + year={2019}, + doi={10.1175/bams-d-17-0246.1} +} + @article {deng2008cirrus, author = {Deng, Min and Mace, Gerald G.}, title = {Cirrus cloud microphysical properties and air motion statistics using cloud radar Doppler moments: Water content, particle size, and sedimentation relationships}, diff --git a/model/fv_cmp.F90 b/model/fv_cmp.F90 index aacf69dbe..79e7c513b 100644 --- a/model/fv_cmp.F90 +++ b/model/fv_cmp.F90 @@ -50,7 +50,7 @@ module fv_cmp_mod ! gfdl_cloud_microphys_mod ! ql_gen, qi_gen, qi0_max, ql_mlt, ql0_max, qi_lim, qs_mlt, ! tau_r2g, tau_smlt, tau_i2s, tau_v2l, tau_l2v, tau_imlt, tau_l2r, -! rad_rain, rad_snow, rad_graupel, dw_ocean, dw_land +! rad_rain, rad_snow, rad_graupel, dw_ocean, dw_land, tintqs ! ! @@ -60,7 +60,7 @@ module fv_cmp_mod use gfdl_cloud_microphys_mod, only: ql_gen, qi_gen, qi0_max, ql_mlt, ql0_max, qi_lim, qs_mlt use gfdl_cloud_microphys_mod, only: icloud_f, sat_adj0, t_sub, cld_min use gfdl_cloud_microphys_mod, only: tau_r2g, tau_smlt, tau_i2s, tau_v2l, tau_l2v, tau_imlt, tau_l2r - use gfdl_cloud_microphys_mod, only: rad_rain, rad_snow, rad_graupel, dw_ocean, dw_land + use gfdl_cloud_microphys_mod, only: rad_rain, rad_snow, rad_graupel, dw_ocean, dw_land, tintqs #ifdef MULTI_GASES use multi_gases_mod, only: virq_qpz, vicpqd_qpz, vicvqd_qpz, num_gas #endif @@ -774,9 +774,14 @@ subroutine fv_sat_adj (mdt, zvir, is, ie, js, je, ng, hydrostatic, consv_te, te0 do i = is, ie - tin = pt1 (i) - (lcp2 (i) * q_cond (i) + icp2 (i) * q_sol (i)) ! minimum temperature + if(tintqs) then + tin = pt1(i) + else +! tin = pt1 (i) - (lcp2 (i) * q_cond (i) + icp2 (i) * q_sol (i)) ! minimum temperature + tin = pt1 (i) - (lcp2 (i) * q_liq (i) + icp2 (i) * q_sol (i)) ! minimum temperature ! tin = pt1 (i) - ((lv00 + d0_vap * pt1 (i)) * q_cond (i) + & ! (li00 + dc_ice * pt1 (i)) * q_sol (i)) / (mc_air (i) + qpz (i) * c_vap) + endif ! ----------------------------------------------------------------------- ! determine saturated specific humidity @@ -820,14 +825,14 @@ subroutine fv_sat_adj (mdt, zvir, is, ie, js, je, ng, hydrostatic, consv_te, te0 ! icloud_f = 2: binary cloud scheme (0 / 1) ! ----------------------------------------------------------------------- - if (rh > 0.75 .and. qpz (i) > 1.e-6) then + if (rh > 0.75 .and. qpz (i) > 1.e-8) then dq = hvar (i) * qpz (i) q_plus = qpz (i) + dq q_minus = qpz (i) - dq if (icloud_f == 2) then if (qpz (i) > qstar (i)) then qa (i, j) = 1. - elseif (qstar (i) < q_plus .and. q_cond (i) > 1.e-6) then + elseif (qstar (i) < q_plus .and. q_cond (i) > 1.e-8) then qa (i, j) = ((q_plus - qstar (i)) / dq) ** 2 qa (i, j) = min (1., qa (i, j)) else @@ -847,7 +852,7 @@ subroutine fv_sat_adj (mdt, zvir, is, ie, js, je, ng, hydrostatic, consv_te, te0 qa (i, j) = 0. endif ! impose minimum cloudiness if substantial q_cond (i) exist - if (q_cond (i) > 1.e-6) then + if (q_cond (i) > 1.e-8) then qa (i, j) = max (cld_min, qa (i, j)) endif qa (i, j) = min (1., qa (i, j)) From bdaaa8db1bd28b5372737a8122a744826a2a7fa1 Mon Sep 17 00:00:00 2001 From: "fanglin.yang" Date: Fri, 6 Sep 2019 19:15:51 +0000 Subject: [PATCH 3/5] Update fv_cmp.F90 to remove a bug introduced in last update. --- model/fv_cmp.F90 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/model/fv_cmp.F90 b/model/fv_cmp.F90 index 79e7c513b..16b679b9f 100644 --- a/model/fv_cmp.F90 +++ b/model/fv_cmp.F90 @@ -777,8 +777,7 @@ subroutine fv_sat_adj (mdt, zvir, is, ie, js, je, ng, hydrostatic, consv_te, te0 if(tintqs) then tin = pt1(i) else -! tin = pt1 (i) - (lcp2 (i) * q_cond (i) + icp2 (i) * q_sol (i)) ! minimum temperature - tin = pt1 (i) - (lcp2 (i) * q_liq (i) + icp2 (i) * q_sol (i)) ! minimum temperature + tin = pt1 (i) - (lcp2 (i) * q_cond (i) + icp2 (i) * q_sol (i)) ! minimum temperature ! tin = pt1 (i) - ((lv00 + d0_vap * pt1 (i)) * q_cond (i) + & ! (li00 + dc_ice * pt1 (i)) * q_sol (i)) / (mc_air (i) + qpz (i) * c_vap) endif From 700a4f767b64b0a472f47bcde7641f817c869a2e Mon Sep 17 00:00:00 2001 From: Dusan Jovic Date: Tue, 24 Sep 2019 01:57:11 +0000 Subject: [PATCH 4/5] change delz from positive value to the original value in the model --- driver/fvGFS/fv_nggps_diag.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/driver/fvGFS/fv_nggps_diag.F90 b/driver/fvGFS/fv_nggps_diag.F90 index 01066f18e..07a471c32 100644 --- a/driver/fvGFS/fv_nggps_diag.F90 +++ b/driver/fvGFS/fv_nggps_diag.F90 @@ -514,7 +514,7 @@ subroutine fv_nggps_diag(Atm, zvir, Time) do k=1,npzo do j=jsco,jeco do i=isco,ieco - wk(i,j,k) = -Atm(n)%delz(i,j,k) + wk(i,j,k) = Atm(n)%delz(i,j,k) enddo enddo enddo From eb10b8bd3cb98e5faf5928b7c80729334d7dade1 Mon Sep 17 00:00:00 2001 From: climbfuji Date: Fri, 20 Sep 2019 08:52:01 -0600 Subject: [PATCH 5/5] Remove TRANSITION mode --- makefile | 15 --------------- model/fv_mapz.F90 | 22 ---------------------- 2 files changed, 37 deletions(-) diff --git a/makefile b/makefile index 7b029e0ee..523dc111b 100644 --- a/makefile +++ b/makefile @@ -96,7 +96,6 @@ $(LIBRARY): $(OBJS) ./model/nh_utils.o : ./model/nh_utils.F90 $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS) $(OTHER_FFLAGS) $(FAST) -c $< -o $@ -# For PROD/TRANSITION, this is overwritten below ./model/fv_mapz.o : ./model/fv_mapz.F90 $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS) $(OTHER_FFLAGS) $(FAST) -c $< -o $@ @@ -107,20 +106,6 @@ $(LIBRARY): $(OBJS) ./driver/fvGFS/atmosphere.o : ./driver/fvGFS/atmosphere.F90 $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS) $(OTHER_FFLAGS) $(ESMF_INC) -c $< -o $@ -# For CCPP acceptance: reduce optimization for certain files to -# obtain bit-for-bit identical results in PROD mode on Theia/Intel 15 -ifneq (,$(findstring TRANSITION,$(CPPDEFS))) -FFLAGS_LOPT=$(subst CORE-AVX2,CORE-AVX-I,\ - $(subst no-prec-div,prec-div,\ - $(subst no-prec-sqrt,prec-sqrt,$(FFLAGS)))) -./model/dyn_core.o : ./model/dyn_core.F90 - $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS_LOPT) $(OTHER_FFLAGS) -c $< -o $@ -./model/fv_mapz.o : ./model/fv_mapz.F90 - $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS_LOPT) $(OTHER_FFLAGS) $(FAST) -c $< -o $@ -./model/fv_cmp.o : ./model/fv_cmp.F90 - $(FC) $(CPPDEFS) $(FPPFLAGS) $(FFLAGS_LOPT) $(OTHER_FFLAGS) -c $< -o $@ -endif # (,$(findstring TRANSITION,$(CPPDEFS))) - .PHONY: clean clean: @echo "Cleaning fv3core ... " diff --git a/model/fv_mapz.F90 b/model/fv_mapz.F90 index 222aac9c5..4994538b9 100644 --- a/model/fv_mapz.F90 +++ b/model/fv_mapz.F90 @@ -201,10 +201,6 @@ subroutine Lagrangian_to_Eulerian(last_step, consv, ps, pe, delp, pkz, pk, & real, intent(inout):: dtdt(is:ie,js:je,km) real, intent(out):: pkz(is:ie,js:je,km) !< layer-mean pk for converting t to pt real, intent(out):: te(isd:ied,jsd:jed,km) -#if !defined(CCPP) && defined(TRANSITION) - ! For bit-for-bit reproducibility - real, volatile:: volatile_var -#endif ! !DESCRIPTION: ! @@ -663,9 +659,6 @@ subroutine Lagrangian_to_Eulerian(last_step, consv, ps, pe, delp, pkz, pk, & !$OMP ng,gridstruct,E_Flux,pdt,dtmp,reproduce_sum,q, & !$OMP mdt,cld_amt,cappa,dtdt,out_dt,rrg,akap,do_sat_adj, & !$OMP fast_mp_consv,kord_tm) & -#ifdef TRANSITION -!$OMP private(volatile_var) & -#endif #ifdef MULTI_GASES !$OMP shared(num_gas) & #endif @@ -854,28 +847,13 @@ subroutine Lagrangian_to_Eulerian(last_step, consv, ps, pe, delp, pkz, pk, & do j=js,je do i=is,ie #ifdef MOIST_CAPPA -#ifdef TRANSITION - volatile_var = log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k)) - pkz(i,j,k) = exp(cappa(i,j,k)*volatile_var) -#else pkz(i,j,k) = exp(cappa(i,j,k)*log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k))) -#endif -#else -#ifdef TRANSITION -#ifdef MULTI_GASES - volatile_var = log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k)) - pkz(i,j,k) = exp(akap*(virqd(q(i,j,k,1:num_gas))/vicpqd(q(i,j,k,1:num_gas))*volatile_var) -#else - volatile_var = log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k)) - pkz(i,j,k) = exp(akap*volatile_var) -#endif #else #ifdef MULTI_GASES pkz(i,j,k) = exp(akap*(virqd(q(i,j,k,1:num_gas))/vicpqd(q(i,j,k,1:num_gas))*log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k))) #else pkz(i,j,k) = exp(akap*log(rrg*delp(i,j,k)/delz(i,j,k)*pt(i,j,k))) #endif -#endif #endif enddo enddo