From 87c625c4ac804716da08fba263391f94a1a662d2 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Fri, 1 Mar 2024 17:56:23 +0100 Subject: [PATCH 1/7] new sum diagnostics to compare with tropmamoslo --- src/chemistry/mozart/mo_chm_diags.F90 | 70 ++++++++++++++++++++++++++- 1 file changed, 69 insertions(+), 1 deletion(-) diff --git a/src/chemistry/mozart/mo_chm_diags.F90 b/src/chemistry/mozart/mo_chm_diags.F90 index 5650403fee..c60f60d80c 100644 --- a/src/chemistry/mozart/mo_chm_diags.F90 +++ b/src/chemistry/mozart/mo_chm_diags.F90 @@ -484,6 +484,22 @@ subroutine chm_diags_inti call addfld( 'MASS', (/ 'lev' /), 'A', 'kg', 'mass of grid box' ) call addfld( 'AREA', horiz_only, 'A', 'm2', 'area of grid box' ) + call addfld('sum_SO4' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of SO4 concentrations') + call addfld('sum_BC' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of BC concentrations') + call addfld('sum_OM' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of OM concentrations') + call addfld('sum_DST' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of DST concentrations') + call addfld('sum_SS' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of SS concentrations') + call addfld('sum_SOA' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of SOA concentrations') + call addfld('sum_num' , (/ 'lev' /), 'A', 'kg/kg ', 'sum of num ') + + call add_default('sum_SO4' , 1, ' ') + call add_default('sum_BC' , 1, ' ') + call add_default('sum_OM' , 1, ' ') + call add_default('sum_DST' , 1, ' ') + call add_default('sum_SS' , 1, ' ') + call add_default('sum_SOA' , 1, ' ') + call add_default('sum_num' , 1, ' ') + call addfld( 'dry_deposition_NOy_as_N', horiz_only, 'I', 'kg/m2/s', 'NOy dry deposition flux ' ) call addfld( 'DF_SOX', horiz_only, 'I', 'kg/m2/s', 'SOx dry deposition flux ' ) call addfld( 'dry_deposition_NHx_as_N', horiz_only, 'I', 'kg/m2/s', 'NHx dry deposition flux ' ) @@ -555,6 +571,16 @@ subroutine chm_diags( lchnk, ncol, vmr, mmr, rxt_rates, invariants, depvel, depf real(r8), dimension(ncol) :: wd_noy, wd_nhx real(r8), dimension(ncol,pver) :: vmr_hox + character(len=16) :: jname, spc_name, attr + + real(r8) :: sum_so4(ncol,pver) + real(r8) :: sum_bc(ncol,pver) + real(r8) :: sum_om(ncol,pver) + real(r8) :: sum_dst(ncol,pver) + real(r8) :: sum_ss(ncol,pver) + real(r8) :: sum_soa(ncol,pver) + real(r8) :: sum_num(ncol,pver) + real(r8) :: area(ncol), mass(ncol,pver) real(r8) :: wgt @@ -748,8 +774,50 @@ subroutine chm_diags( lchnk, ncol, vmr, mmr, rxt_rates, invariants, depvel, depf call outfld('DO3CHM_LMS',do3chm_lms(:ncol), ncol, lchnk ) end if ! - enddo + enddo ! end loop from m=1,gas_pcnst + + ! Generate compund sum + ! so4_a1,so4_a2,so4_a3 + ! bc_a1,bc_a4 + ! pom_a1,pom_a4 + ! ncl_a1,ncl_a2,ncl_a3 + ! soa_a1,soa_a2 + ! num_a1,num_a2,num_a3,num_a4 + + sum_so4(:,:) = 0._r8 + sum_bc(:,:) = 0._r8 + sum_om(:,:) = 0._r8 + sum_dst(:,:) = 0._r8 + sum_ss(:,:) = 0._r8 + sum_soa(:,:) = 0._r8 + sum_num(:,:) = 0._r8 + + do m = 1,gas_pcnst + spc_name = trim(solsym(m)) + if (spc_name(1:4) == 'so4_') then + sum_so4(:ncol,:) = sum_so4(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:3) == 'bc_') then + sum_bc(:ncol,:) = sum_bc(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:4) == 'pom_') then + sum_om(:ncol,:) = sum_om(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:4) == 'dst_') then + sum_dst(:ncol,:) = sum_dst(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:3) == 'ncl_') then + sum_ss(:ncol,:) = sum_ss(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:4) == 'soa_') then + sum_soa(:ncol,:) = sum_soa(:ncol,:) + mmr(:ncol,:,m) + else if (spc_name(1:4) == 'num_') then + sum_num(:ncol,:) = sum_num(:ncol,:) + mmr(:ncol,:,m) + end if + end do + call outfld( 'sum_SO4', sum_so4(:ncol,:), ncol ,lchnk ) + call outfld( 'sum_BC' , sum_bc(:ncol,:) , ncol ,lchnk ) + call outfld( 'sum_OM' , sum_om(:ncol,:) , ncol ,lchnk ) + call outfld( 'sum_DST', sum_dst(:ncol,:), ncol ,lchnk ) + call outfld( 'sum_SS' , sum_ss(:ncol,:) , ncol ,lchnk ) + call outfld( 'sum_SOA', sum_soa(:ncol,:), ncol ,lchnk ) + call outfld( 'sum_num', sum_num(:ncol,:), ncol ,lchnk ) call outfld( 'NOX', vmr_nox (:ncol,:), ncol, lchnk ) call outfld( 'NOY', vmr_noy (:ncol,:), ncol, lchnk ) From 18b2c7eeeab6ea617ba7e21daec2d1ad032bde0a Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Mon, 4 Mar 2024 10:29:32 +0100 Subject: [PATCH 2/7] fixed bug for sum_SS output --- src/chemistry/mozart/mo_chm_diags.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/chemistry/mozart/mo_chm_diags.F90 b/src/chemistry/mozart/mo_chm_diags.F90 index c60f60d80c..6a270aa082 100644 --- a/src/chemistry/mozart/mo_chm_diags.F90 +++ b/src/chemistry/mozart/mo_chm_diags.F90 @@ -803,7 +803,7 @@ subroutine chm_diags( lchnk, ncol, vmr, mmr, rxt_rates, invariants, depvel, depf sum_om(:ncol,:) = sum_om(:ncol,:) + mmr(:ncol,:,m) else if (spc_name(1:4) == 'dst_') then sum_dst(:ncol,:) = sum_dst(:ncol,:) + mmr(:ncol,:,m) - else if (spc_name(1:3) == 'ncl_') then + else if (spc_name(1:4) == 'ncl_') then sum_ss(:ncol,:) = sum_ss(:ncol,:) + mmr(:ncol,:,m) else if (spc_name(1:4) == 'soa_') then sum_soa(:ncol,:) = sum_soa(:ncol,:) + mmr(:ncol,:,m) From 6748627b08e78f863eed212849f5fc89805cd6a7 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Tue, 5 Mar 2024 10:59:41 +0100 Subject: [PATCH 3/7] pointer to new oslo_aero branch --- Externals_CAM.cfg | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Externals_CAM.cfg b/Externals_CAM.cfg index 68215e7885..537b81a1e8 100644 --- a/Externals_CAM.cfg +++ b/Externals_CAM.cfg @@ -65,8 +65,10 @@ required = True [oslo_aero] protocol = git -tag = 592ab19 -repo_url = https://github.com/NorESMhub/OSLO_AERO +#tag = 592ab19 +#repo_url = https://github.com/NorESMhub/OSLO_AERO +branch = feature/new_sum_diagnostics +repo_url = https://github.com/mvertens/OSLO_AERO local_path = src/chemistry/oslo_aero required = True From 0a03d6f790a92edcc01e4b6397864d66b11c6041 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Sat, 25 May 2024 15:00:05 +0200 Subject: [PATCH 4/7] updated oslo-aero external --- Externals_CAM.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Externals_CAM.cfg b/Externals_CAM.cfg index 537b81a1e8..c9a34c71b0 100644 --- a/Externals_CAM.cfg +++ b/Externals_CAM.cfg @@ -67,7 +67,7 @@ required = True protocol = git #tag = 592ab19 #repo_url = https://github.com/NorESMhub/OSLO_AERO -branch = feature/new_sum_diagnostics +branch = feature/add_sum_diagnostics repo_url = https://github.com/mvertens/OSLO_AERO local_path = src/chemistry/oslo_aero required = True From de164bd84c436b316858bf273a2aa88255a84b17 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Sun, 26 May 2024 16:03:21 +0200 Subject: [PATCH 5/7] updated oslo-aero external --- Externals_CAM.cfg | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Externals_CAM.cfg b/Externals_CAM.cfg index c9a34c71b0..e220ccef87 100644 --- a/Externals_CAM.cfg +++ b/Externals_CAM.cfg @@ -65,10 +65,8 @@ required = True [oslo_aero] protocol = git -#tag = 592ab19 -#repo_url = https://github.com/NorESMhub/OSLO_AERO -branch = feature/add_sum_diagnostics -repo_url = https://github.com/mvertens/OSLO_AERO +tag = noresm_oslo_aero_v1 +repo_url = https://github.com/NorESMhub/OSLO_AERO local_path = src/chemistry/oslo_aero required = True From b5590c3ae394be25a80d3b2e797fcc646195e489 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Sun, 26 May 2024 22:22:15 +0200 Subject: [PATCH 6/7] addressed issues in PR --- src/chemistry/mozart/mo_chm_diags.F90 | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/src/chemistry/mozart/mo_chm_diags.F90 b/src/chemistry/mozart/mo_chm_diags.F90 index 6a270aa082..33e0a7e176 100644 --- a/src/chemistry/mozart/mo_chm_diags.F90 +++ b/src/chemistry/mozart/mo_chm_diags.F90 @@ -779,18 +779,24 @@ subroutine chm_diags( lchnk, ncol, vmr, mmr, rxt_rates, invariants, depvel, depf ! Generate compund sum ! so4_a1,so4_a2,so4_a3 - ! bc_a1,bc_a4 - ! pom_a1,pom_a4 - ! ncl_a1,ncl_a2,ncl_a3 - ! soa_a1,soa_a2 - ! num_a1,num_a2,num_a3,num_a4 - sum_so4(:,:) = 0._r8 + + ! bc_a1,bc_a4 sum_bc(:,:) = 0._r8 + + ! pom_a1,pom_a4 sum_om(:,:) = 0._r8 + + ! dst sum_dst(:,:) = 0._r8 + + ! ncl_a1,ncl_a2,ncl_a3 sum_ss(:,:) = 0._r8 + + ! soa_a1,soa_a2 sum_soa(:,:) = 0._r8 + + ! num_a1,num_a2,num_a3,num_a4 sum_num(:,:) = 0._r8 do m = 1,gas_pcnst From fb9e751b65212c54819e8bc0eedaa5a8ef01a856 Mon Sep 17 00:00:00 2001 From: Mariana Vertenstein Date: Wed, 29 May 2024 09:33:12 +0200 Subject: [PATCH 7/7] update time length for some tests --- cime_config/testdefs/testlist_cam.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cime_config/testdefs/testlist_cam.xml b/cime_config/testdefs/testlist_cam.xml index 618ba78ed4..590e9c98fa 100644 --- a/cime_config/testdefs/testlist_cam.xml +++ b/cime_config/testdefs/testlist_cam.xml @@ -40,7 +40,7 @@ - + @@ -48,7 +48,7 @@ - + @@ -89,7 +89,7 @@ - +