From 7d7b690f1b6931ab0ecaafa2bf9a875dbcc3985f Mon Sep 17 00:00:00 2001 From: Samuel Trahan Date: Tue, 6 Apr 2021 19:32:02 +0000 Subject: [PATCH 01/11] Point to gocart_co branch of ccpp/physics --- .gitmodules | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitmodules b/.gitmodules index 92af6be8d..e26abfc1a 100644 --- a/.gitmodules +++ b/.gitmodules @@ -9,4 +9,4 @@ [submodule "ccpp/physics"] path = ccpp/physics url = https://github.com/SamuelTrahanNOAA/ccpp-physics - branch = ca-sgs-emis + branch = gocart_co From f49c8f20482e308f240229a76133a8d4def2d77d Mon Sep 17 00:00:00 2001 From: Samuel Trahan Date: Tue, 6 Apr 2021 20:03:30 +0000 Subject: [PATCH 02/11] First pass at merging Mariusz's gocart changes to gsdchem --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 7b440d040..7eab06fb8 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 7b440d040c3bc51d66402444f9f64e058d69ab6c +Subproject commit 7eab06fb8a7b02989aa8885de3802ec8fe2633b9 From 2c111e7f01bb48cbcb2517933376fa2536bc89e6 Mon Sep 17 00:00:00 2001 From: Samuel Trahan Date: Tue, 6 Apr 2021 21:18:17 +0000 Subject: [PATCH 03/11] Add CO tracer and a gsd_chem_config_wrapper to pass tracer indices down to gsd_chem. --- ccpp/config/ccpp_prebuild_config.py | 1 + ccpp/physics | 2 +- ccpp/suites/suite_FV3_GFS_2017_gfdlmp_gsd_chem.xml | 1 + ccpp/suites/suite_FV3_GFS_v15_gsd_chem.xml | 1 + ccpp/suites/suite_FV3_GFS_v16beta_gsd_chem.xml | 1 + gfsphysics/GFS_layer/GFS_typedefs.F90 | 7 ++++++- gfsphysics/GFS_layer/GFS_typedefs.meta | 6 ++++++ 7 files changed, 17 insertions(+), 2 deletions(-) diff --git a/ccpp/config/ccpp_prebuild_config.py b/ccpp/config/ccpp_prebuild_config.py index 21d3bc3e3..38e67c2e1 100755 --- a/ccpp/config/ccpp_prebuild_config.py +++ b/ccpp/config/ccpp_prebuild_config.py @@ -178,6 +178,7 @@ 'FV3/ccpp/physics/physics/sfc_ocean.F', 'FV3/ccpp/physics/physics/sfc_sice.f', 'FV3/ccpp/physics/physics/tracer_sanitizer.F90', + 'FV3/ccpp/physics/gsdchem/gsd_chem_config_wrapper.F90', 'FV3/ccpp/physics/gsdchem/gsd_chem_seas_wrapper.F90', 'FV3/ccpp/physics/gsdchem/gsd_chem_dust_wrapper.F90', 'FV3/ccpp/physics/gsdchem/gsd_chem_anthropogenic_wrapper.F90', diff --git a/ccpp/physics b/ccpp/physics index 7eab06fb8..70656b67b 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 7eab06fb8a7b02989aa8885de3802ec8fe2633b9 +Subproject commit 70656b67b73c526c39cebd119f04b0773e86635f diff --git a/ccpp/suites/suite_FV3_GFS_2017_gfdlmp_gsd_chem.xml b/ccpp/suites/suite_FV3_GFS_2017_gfdlmp_gsd_chem.xml index 81d836924..d5eea096f 100644 --- a/ccpp/suites/suite_FV3_GFS_2017_gfdlmp_gsd_chem.xml +++ b/ccpp/suites/suite_FV3_GFS_2017_gfdlmp_gsd_chem.xml @@ -57,6 +57,7 @@ sfc_diag sfc_diag_post GFS_surface_generic_post + gsd_chem_config_wrapper gsd_chem_seas_wrapper gsd_chem_dmsemis_wrapper gsd_chem_dust_wrapper diff --git a/ccpp/suites/suite_FV3_GFS_v15_gsd_chem.xml b/ccpp/suites/suite_FV3_GFS_v15_gsd_chem.xml index f4e108902..8d5ed548d 100644 --- a/ccpp/suites/suite_FV3_GFS_v15_gsd_chem.xml +++ b/ccpp/suites/suite_FV3_GFS_v15_gsd_chem.xml @@ -57,6 +57,7 @@ sfc_diag sfc_diag_post GFS_surface_generic_post + gsd_chem_config_wrapper gsd_chem_seas_wrapper gsd_chem_dmsemis_wrapper gsd_chem_dust_wrapper diff --git a/ccpp/suites/suite_FV3_GFS_v16beta_gsd_chem.xml b/ccpp/suites/suite_FV3_GFS_v16beta_gsd_chem.xml index fd1e15c08..ccf5f053e 100644 --- a/ccpp/suites/suite_FV3_GFS_v16beta_gsd_chem.xml +++ b/ccpp/suites/suite_FV3_GFS_v16beta_gsd_chem.xml @@ -57,6 +57,7 @@ sfc_diag sfc_diag_post GFS_surface_generic_post + gsd_chem_config_wrapper gsd_chem_seas_wrapper gsd_chem_dmsemis_wrapper gsd_chem_dust_wrapper diff --git a/gfsphysics/GFS_layer/GFS_typedefs.F90 b/gfsphysics/GFS_layer/GFS_typedefs.F90 index bc4133a0a..234a9e342 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.F90 +++ b/gfsphysics/GFS_layer/GFS_typedefs.F90 @@ -1168,6 +1168,9 @@ module GFS_typedefs integer :: chem_conv_tr integer :: chem_in_opt integer :: chem_opt + ! These must match gsd_chem_config.F90: + integer, parameter :: chem_opt_gocart = 300 !< chem_opt for simple scheme + integer, parameter :: chem_opt_gocart_co = 499 !< chem_opt for simple scheme with co integer :: chemdt integer :: cldchem_onoff integer :: dmsemis_opt @@ -3466,7 +3469,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & integer :: biomass_burn_opt = 1 integer :: chem_conv_tr = 0 integer :: chem_in_opt = 0 - integer :: chem_opt =300 + integer :: chem_opt = chem_opt_gocart integer :: chemdt = 3 integer :: cldchem_onoff = 0 integer :: dmsemis_opt = 1 @@ -4300,6 +4303,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%ntsulf = get_tracer_index(Model%tracer_names, 'sulf', Model%me, Model%master, Model%debug) Model%ntdms = get_tracer_index(Model%tracer_names, 'dms', Model%me, Model%master, Model%debug) Model%ntmsa = get_tracer_index(Model%tracer_names, 'msa', Model%me, Model%master, Model%debug) + Model%ntco = get_tracer_index(Model%tracer_names, 'co', Model%me, Model%master, Model%debug) Model%ntpp25 = get_tracer_index(Model%tracer_names, 'pp25', Model%me, Model%master, Model%debug) Model%ntbc1 = get_tracer_index(Model%tracer_names, 'bc1', Model%me, Model%master, Model%debug) Model%ntbc2 = get_tracer_index(Model%tracer_names, 'bc2', Model%me, Model%master, Model%debug) @@ -5401,6 +5405,7 @@ subroutine control_print(Model) print *, ' ntsulf : ', Model%ntsulf print *, ' ntdms : ', Model%ntdms print *, ' ntmsa : ', Model%ntmsa + print *, ' ntco : ', Model%ntco print *, ' ntpp25 : ', Model%ntpp25 print *, ' ntbc1 : ', Model%ntbc1 print *, ' ntbc2 : ', Model%ntbc2 diff --git a/gfsphysics/GFS_layer/GFS_typedefs.meta b/gfsphysics/GFS_layer/GFS_typedefs.meta index 9ff5edae1..fe747a367 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.meta +++ b/gfsphysics/GFS_layer/GFS_typedefs.meta @@ -4222,6 +4222,12 @@ units = index dimensions = () type = integer +[ntco] + standard_name = index_for_co + long_name = tracer index for co + units = index + dimensions = () + type = integer [ntpp25] standard_name = index_for_pp25 long_name = tracer index for pp25 From 2980e9033d8321ad643104cf5d6790a27ba88b8e Mon Sep 17 00:00:00 2001 From: Samuel Trahan Date: Wed, 7 Apr 2021 00:09:13 +0000 Subject: [PATCH 04/11] Connect CO several more places and get the changes to compile. --- ccpp/physics | 2 +- gfsphysics/GFS_layer/GFS_typedefs.F90 | 22 +++++++++++++++++----- io/FV3GFS_io.F90 | 16 ++++++++++++++++ 3 files changed, 34 insertions(+), 6 deletions(-) diff --git a/ccpp/physics b/ccpp/physics index 70656b67b..2c49997ff 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 70656b67b73c526c39cebd119f04b0773e86635f +Subproject commit 2c49997ffd878ec29d8694c181d898d9b835f1cb diff --git a/gfsphysics/GFS_layer/GFS_typedefs.F90 b/gfsphysics/GFS_layer/GFS_typedefs.F90 index 234a9e342..2b620f2de 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.F90 +++ b/gfsphysics/GFS_layer/GFS_typedefs.F90 @@ -1114,6 +1114,7 @@ module GFS_typedefs integer :: ntsulf !< tracer index for sulf integer :: ntdms !< tracer index for DMS integer :: ntmsa !< tracer index for msa + integer :: ntco !< tracer index for co integer :: ntpp25 !< tracer index for pp25 integer :: ntbc1 !< tracer index for bc1 integer :: ntbc2 !< tracer index for bc2 @@ -1169,8 +1170,8 @@ module GFS_typedefs integer :: chem_in_opt integer :: chem_opt ! These must match gsd_chem_config.F90: - integer, parameter :: chem_opt_gocart = 300 !< chem_opt for simple scheme - integer, parameter :: chem_opt_gocart_co = 499 !< chem_opt for simple scheme with co + integer :: chem_opt_gocart !< chem_opt for simple scheme + integer :: chem_opt_gocart_co !< chem_opt for simple scheme with co integer :: chemdt integer :: cldchem_onoff integer :: dmsemis_opt @@ -2337,10 +2338,18 @@ subroutine sfcprop_create (Sfcprop, IM, Model) ! allocate (Sfcprop%hprim (IM)) allocate (Sfcprop%hprime (IM,Model%nmtvr)) allocate (Sfcprop%dust_in (IM,5)) - allocate (Sfcprop%emi_in (IM,10)) + if(Model%chem_opt == Model%CHEM_OPT_GOCART_CO) then + allocate (Sfcprop%emi_in (IM,11)) + else + allocate (Sfcprop%emi_in (IM,10)) + endif allocate (Sfcprop%emi2_in (IM,64,3)) allocate (Sfcprop%fire_MODIS (IM,13)) - allocate (Sfcprop%fire_GBBEPx(IM,5)) + if(Model%chem_opt == Model%CHEM_OPT_GOCART_CO) then + allocate (Sfcprop%fire_GBBEPx(IM,6)) + else + allocate (Sfcprop%fire_GBBEPx(IM,5)) + endif Sfcprop%slmsk = clear_val Sfcprop%oceanfrac = clear_val @@ -3461,6 +3470,8 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & #ifdef CCPP !-- chem nml variables for FV3/CCPP-Chem + integer, parameter :: chem_opt_gocart = 300 + integer, parameter :: chem_opt_gocart_co = 499 integer :: aer_bc_opt = 1 integer :: aer_ic_opt = 1 integer :: aer_ra_feedback = 0 @@ -3643,7 +3654,6 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !--- convective clouds integer :: ncnvcld3d = 0 !< number of convective 3d clouds fields - !--- read in the namelist #ifdef INTERNAL_FILE_NML Model%input_nml_file => input_nml_file @@ -4380,6 +4390,8 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%biomass_burn_opt = biomass_burn_opt Model%chem_conv_tr = chem_conv_tr Model%chem_in_opt = chem_in_opt + Model%chem_opt_gocart = chem_opt_gocart + Model%chem_opt_gocart_co= chem_opt_gocart_co Model%chem_opt = chem_opt Model%chemdt = chemdt Model%cldchem_onoff = cldchem_onoff diff --git a/io/FV3GFS_io.F90 b/io/FV3GFS_io.F90 index 7387b4d4c..348fccc1a 100644 --- a/io/FV3GFS_io.F90 +++ b/io/FV3GFS_io.F90 @@ -548,6 +548,10 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain) nvar_emi2 = 3 nvar_gbbepx = 5 nvar_modis = 13 + if(Model%chem_opt == Model%CHEM_OPT_GOCART_CO) then + nvar_emi = nvar_emi+1 + nvar_gbbepx = nvar_gbbepx+1 + endif else nvar_dust = 0 nvar_emi = 0 @@ -762,6 +766,9 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain) emi_name(8) = 'ero1' emi_name(9) = 'ero2' emi_name(10) = 'ero3' + if(Model%chem_opt==Model%CHEM_OPT_GOCART_CO) then + emi_name(11) = 'e_co' + endif !--- register the 2D fields do num = 1,nvar_emi var2_p => emi_var(:,:,num) @@ -791,6 +798,9 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain) Sfcprop(nb)%emi_in(ix,8) = emi_var(i,j,8) Sfcprop(nb)%emi_in(ix,9) = emi_var(i,j,9) Sfcprop(nb)%emi_in(ix,10) = emi_var(i,j,10) + if(Model%chem_opt==Model%CHEM_OPT_GOCART_CO) then + Sfcprop(nb)%emi_in(ix,11) = emi_var(i,j,11) + endif enddo enddo @@ -847,6 +857,9 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain) gbbepx_name(3) = 'ebu_pm_25' gbbepx_name(4) = 'ebu_so2' gbbepx_name(5) = 'ebu_frp' + if(Model%chem_opt == Model%CHEM_OPT_GOCART_CO) then + gbbepx_name(6) = 'ebu_co' + endif !--- register the 2D fields do num = 1,nvar_gbbepx var2_p => gbbepx_var(:,:,num) @@ -871,6 +884,9 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain) Sfcprop(nb)%fire_GBBEPx(ix,3) = gbbepx_var(i,j,3) Sfcprop(nb)%fire_GBBEPx(ix,4) = gbbepx_var(i,j,4) Sfcprop(nb)%fire_GBBEPx(ix,5) = gbbepx_var(i,j,5) + if(Model%chem_opt == Model%CHEM_OPT_GOCART_CO) then + Sfcprop(nb)%fire_GBBEPx(ix,6) = gbbepx_var(i,j,6) + endif enddo enddo From bb3fd8d32e270e77f7d68aeb0b0ca80c417a5e2b Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Thu, 8 Apr 2021 22:59:23 +0000 Subject: [PATCH 05/11] bug fixes so non-co job runs --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 2c49997ff..264a960ea 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 2c49997ffd878ec29d8694c181d898d9b835f1cb +Subproject commit 264a960ea26074862860a9b8d190f98d5f3061af From 55c9174d69b55a93ca725b77533dd03d74f749bd Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Fri, 9 Apr 2021 00:46:18 +0000 Subject: [PATCH 06/11] Many bug fixes, not enough yet. --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 264a960ea..9c2f32d8f 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 264a960ea26074862860a9b8d190f98d5f3061af +Subproject commit 9c2f32d8fc2d7f5a2cb9428ded9580a36b298664 From 73ff321760bc484662dafa5544ac3bbbeb93ddca Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Fri, 9 Apr 2021 23:49:22 +0000 Subject: [PATCH 07/11] Correct array size and dimension mismatches. Do not specify array dimensions. Gocart co mode runs to completion. --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 9c2f32d8f..6c9a364bb 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 9c2f32d8fc2d7f5a2cb9428ded9580a36b298664 +Subproject commit 6c9a364bb32e97299a404cd791d3b3402156f3ee From c78b8d5d726be348173cbe6919f02fea00496740 Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Fri, 16 Apr 2021 17:19:30 +0000 Subject: [PATCH 08/11] Correct unit conversions for CO and array indices for buffer_ebu. --- ccpp/physics | 2 +- gfsphysics/GFS_layer/GFS_typedefs.F90 | 9 ++++++++- gfsphysics/GFS_layer/GFS_typedefs.meta | 14 +++++++++++++- 3 files changed, 22 insertions(+), 3 deletions(-) diff --git a/ccpp/physics b/ccpp/physics index 6c9a364bb..bb0a1b5e9 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 6c9a364bb32e97299a404cd791d3b3402156f3ee +Subproject commit bb0a1b5e91249206bc74d3d4783f20a190940313 diff --git a/gfsphysics/GFS_layer/GFS_typedefs.F90 b/gfsphysics/GFS_layer/GFS_typedefs.F90 index 2b620f2de..15743769c 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.F90 +++ b/gfsphysics/GFS_layer/GFS_typedefs.F90 @@ -621,6 +621,8 @@ module GFS_typedefs logical :: cplchm !< default no cplchm collection #ifdef CCPP logical :: cplchm_rad_opt !< default no cplchm radiation feedback + + integer :: num_ebu !< length of internal gsdchem ebu buffer #endif !--- integrated dynamics through earth's atmosphere @@ -2904,7 +2906,7 @@ subroutine coupling_create (Coupling, IM, Model) !--- accumulated convective rainfall allocate (Coupling%rainc_cpl (IM)) !-- chemistry coupling buffer - allocate (Coupling%buffer_ebu (IM,Model%levs+1,1,7)) + allocate (Coupling%buffer_ebu (IM,Model%levs+1,1,Model%num_ebu)) !-- chemistry coupling feedback to radiation allocate (Coupling%faersw_cpl (IM,Model%levr+LTP,14,3)) @@ -4393,6 +4395,11 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%chem_opt_gocart = chem_opt_gocart Model%chem_opt_gocart_co= chem_opt_gocart_co Model%chem_opt = chem_opt + if(chem_opt==chem_opt_gocart_co) then + Model%num_ebu=8 + else + Model%num_ebu=7 + endif Model%chemdt = chemdt Model%cldchem_onoff = cldchem_onoff Model%dmsemis_opt = dmsemis_opt diff --git a/gfsphysics/GFS_layer/GFS_typedefs.meta b/gfsphysics/GFS_layer/GFS_typedefs.meta index fe747a367..cbc6de21c 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.meta +++ b/gfsphysics/GFS_layer/GFS_typedefs.meta @@ -2142,7 +2142,7 @@ standard_name = chem_buffer_ebu long_name = chemistry buffer of ebu units = various - dimensions = (horizontal_dimension,vertical_dimension_plus_one,1,7) + dimensions = (horizontal_dimension,vertical_dimension_plus_one,1,buffer_ebu_length) type = real kind = kind_phys [faersw_cpl] @@ -2419,6 +2419,18 @@ units = flag dimensions = () type = logical +[num_chem] + standard_name = number_of_gsd_chem_chemistry_components + long_name = number of gsd chem chemistry components + units = count + dimensions = () + type = integer +[num_ebu] + standard_name = buffer_ebu_length + long_name = buffer ebu length + units = count + dimensions = () + type = integer [lsidea] standard_name = flag_idealized_physics long_name = flag for idealized physics From 7721cedec7eadfb9d4d49ba3b6b57d40402af07d Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Tue, 20 Apr 2021 19:10:35 +0000 Subject: [PATCH 09/11] Set emis_seas=0 when seas_opt is disabled so ssem is not filled with uninitialized memory. --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index bb0a1b5e9..e11aa8ed4 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit bb0a1b5e91249206bc74d3d4783f20a190940313 +Subproject commit e11aa8ed4051dc9f70c890e2afb9cca58c4d14f9 From d843d6c27718504ea7c8205588eca75d75970fa6 Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Tue, 20 Apr 2021 20:56:26 +0000 Subject: [PATCH 10/11] Remove duplicate (and incorrect) specification of p_seas and p_eseas parameters ins eas_mod.F90 --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index e11aa8ed4..272e0a4ff 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit e11aa8ed4051dc9f70c890e2afb9cca58c4d14f9 +Subproject commit 272e0a4ff533b897eca3e8e8dd4803abcb5daab1 From 0ef0101dabddcccdf08fb7a557452ba047b80bd5 Mon Sep 17 00:00:00 2001 From: "samuel.trahan" Date: Wed, 21 Apr 2021 21:39:50 +0000 Subject: [PATCH 11/11] Bugfixes to get CO working + remove print statements --- ccpp/physics | 2 +- gfsphysics/GFS_layer/GFS_diagnostics.F90 | 3 +++ gfsphysics/GFS_layer/GFS_typedefs.F90 | 7 +++++-- gfsphysics/GFS_layer/GFS_typedefs.meta | 8 +++++++- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/ccpp/physics b/ccpp/physics index 272e0a4ff..335715cd6 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 272e0a4ff533b897eca3e8e8dd4803abcb5daab1 +Subproject commit 335715cd678dc32b0435bcfbd3b6d5162daedf8c diff --git a/gfsphysics/GFS_layer/GFS_diagnostics.F90 b/gfsphysics/GFS_layer/GFS_diagnostics.F90 index 4c8310ebe..4f6ca6a6a 100644 --- a/gfsphysics/GFS_layer/GFS_diagnostics.F90 +++ b/gfsphysics/GFS_layer/GFS_diagnostics.F90 @@ -4202,6 +4202,9 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop case(6) ExtDiag(idx)%name = 'sscmass' ExtDiag(idx)%desc = 'Seasalt Column Mass Density' + case(7) + ExtDiag(idx)%name = 'comass' + ExtDiag(idx)%desc = 'Carbon Monoxide Column Mass Density' end select ExtDiag(idx)%axes = 2 diff --git a/gfsphysics/GFS_layer/GFS_typedefs.F90 b/gfsphysics/GFS_layer/GFS_typedefs.F90 index 15743769c..0c2ea3b06 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.F90 +++ b/gfsphysics/GFS_layer/GFS_typedefs.F90 @@ -623,6 +623,7 @@ module GFS_typedefs logical :: cplchm_rad_opt !< default no cplchm radiation feedback integer :: num_ebu !< length of internal gsdchem ebu buffer + integer :: num_aecm !< length of aecm buffer #endif !--- integrated dynamics through earth's atmosphere @@ -1742,7 +1743,7 @@ module GFS_typedefs real (kind=kind_phys), pointer :: abem (:,:) => null() !< instantaneous anthopogenic and biomass burning emissions !< for black carbon, organic carbon, and sulfur dioxide ( ug/m**2/s ) real (kind=kind_phys), pointer :: aecm (:,:) => null() !< instantaneous aerosol column mass densities for - !< pm2.5, black carbon, organic carbon, sulfate, dust, sea salt ( g/m**2 ) + !< pm2.5, black carbon, organic carbon, sulfate, dust, sea salt, CO ( g/m**2 ) real (kind=kind_phys), pointer :: wetdpc_deep(:,:) => null() !< instantaneous deep convective wet deposition ( kg/m**2/s ) real (kind=kind_phys), pointer :: wetdpc_mid (:,:) => null() !< instantaneous mid convective wet deposition ( kg/m**2/s ) real (kind=kind_phys), pointer :: wetdpc_shal(:,:) => null() !< instantaneous shallow convective wet deposition ( kg/m**2/s ) @@ -4397,8 +4398,10 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%chem_opt = chem_opt if(chem_opt==chem_opt_gocart_co) then Model%num_ebu=8 + Model%num_aecm=7 else Model%num_ebu=7 + Model%num_aecm=6 endif Model%chemdt = chemdt Model%cldchem_onoff = cldchem_onoff @@ -6523,7 +6526,7 @@ subroutine diag_chem_init(Diag, IM, Model) ! -- for aerosol species (in order): pm2.5 ! -- black carbon, organic carbon, sulfate, ! -- dust, sea salt - allocate (Diag%aecm(IM,6)) + allocate (Diag%aecm(IM,Model%num_aecm)) Diag%aecm = zero contains diff --git a/gfsphysics/GFS_layer/GFS_typedefs.meta b/gfsphysics/GFS_layer/GFS_typedefs.meta index cbc6de21c..5571d074c 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.meta +++ b/gfsphysics/GFS_layer/GFS_typedefs.meta @@ -2431,6 +2431,12 @@ units = count dimensions = () type = integer +[num_aecm] + standard_name = number_of_aerosol_column_mass_densities + long_name = number of aerosol column mass densities + units = count + dimensions = () + type = integer [lsidea] standard_name = flag_idealized_physics long_name = flag for idealized physics @@ -6891,7 +6897,7 @@ standard_name = instantaneous_aerosol_column_mass_densities long_name = instantaneous aerosol column mass densities for pm2.5, black carbon, organic carbon, sulfate, dust, sea salt units = kg m-2 - dimensions = (horizontal_dimension,6) + dimensions = (horizontal_dimension,number_of_aerosol_column_mass_densities) type = real kind = kind_phys [edmf_a]