Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cam6_3_147: GEOS-Chem chemistry and four new compsets that use it #484

Merged
merged 194 commits into from
Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from 144 commits
Commits
Show all changes
194 commits
Select commit Hold shift + click to select a range
1189062
Feat: Changes to include GEOS-Chem as a chemistry option for CESM
fritzt Nov 6, 2019
a5bf274
Squashed of 50+ commits from Thibaud Fritz
fritzt May 14, 2020
94b7423
Squashed 5 commits from Haipeng Lin
jimmielin May 16, 2020
b25ec88
Squashed 2 commits from Thibaud Fritz
fritzt May 19, 2020
63df680
Squashed 4 commits from Lizzie Lundgren
lizziel Jul 21, 2020
9a9ead5
Squashed 60+ commits from Thibaud Fritz
fritzt Jul 31, 2020
6c3299f
Feat: Write ZPJ values for RXN_NO2, RXN_O3_1/2a into HCO_IN_JNO2, HCO…
jimmielin Feb 24, 2021
edf9056
Squashed 4 commits from Thibaud Fritz
fritzt Feb 24, 2021
7afe235
Feat: Now retrieve fields from HEMCO using 2-D pbuf fields
jimmielin Mar 1, 2021
de05dff
Squashed 10 commits from Thibaud Fritz
fritzt Mar 2, 2021
2343800
Feat: Retrieve ParaNOx deposition fluxes from HEMCO
jimmielin Mar 24, 2021
b1d572e
Squashed 18 commits from Thibaud Fritz
fritzt Mar 24, 2021
d8f3709
Fix: correct improper merge conflict handling introduced during rebase
lizziel Dec 7, 2021
1db7a5b
Merge branch 'cam_development' into CESM-GC+cam_development
lizziel Dec 9, 2021
62bb87d
Feat: Return in sox_cldaero_mod if running with GEOS-Chem
fritzt Dec 9, 2021
515ad9a
Fix: correct wrong indexes introduced by manual revert; rm GC wetscav
lizziel Dec 13, 2021
1b1aaea
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Dec 15, 2021
d86976c
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jan 7, 2022
490e50b
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jan 25, 2022
71fb83a
Enable compilation in CESM 2.3 for non-GEOS-Chem case
lizziel Feb 7, 2022
9f80b02
Build fixes for CESM-GC within CESM: non-GEOS-Chem cases
lizziel Feb 10, 2022
60e537a
Update GEOS-Chem interface code for compatibility with CESM 2.3
lizziel Feb 16, 2022
a6c7cc6
Fix bug in J-value diagnostic names for O3O1D
lizziel Mar 4, 2022
035f27c
Remove remaining references to compset FSPCAMM_GC
lizziel Mar 7, 2022
a002aff
GEOS-Chem driver routine updates for compatibility with GEOS-Chem 13.3.4
lizziel Mar 11, 2022
6fd9744
Modifications for new GEOS-Chem species (HMS) in version 13.3
lizziel Mar 31, 2022
596c261
Use ESCOMP/HEMCO_CESM rather than H. Lin's fork
lizziel Mar 31, 2022
425bb49
Change GEOS-Chem branch name to diverge from version used in CESM-GC 2.1
lizziel Mar 31, 2022
eb70ed3
Set default namelist values for cam_physics_mesh in geos-chem use cases
lizziel Mar 31, 2022
1778e5d
Bug fix: increase module parameter gas_pcnst by 1 to include HMS
lizziel Apr 27, 2022
0a782b9
Modifications to turn off dry deposition and dependencies on CLM for …
lizziel Jun 24, 2022
97f4a30
Kludge to get by missing Henry's Law coeffs for certain species
lizziel Jun 24, 2022
e9b8b27
Configure compsets that use GEOS-Chem to also use HEMCO
lizziel Jun 24, 2022
ae59e64
Added high-level log prints
lizziel Jun 29, 2022
aae00e7
Use same RUN_STARTDATE for compset FCHIST_GC as used in FCHIST
lizziel Jun 30, 2022
e27c049
Revert hist_geoschem.xml to original; will adjust in user_nl_cam
lizziel Jun 30, 2022
87e3511
Remove compset that uses geoschem_mam3
lizziel Jun 30, 2022
19832a9
No diff updates to GEOS-Chem use cases to document diffs with non-GC
lizziel Jul 14, 2022
e6dd893
Clean up GEOS-Chem compset namelists
lizziel Jul 19, 2022
849edd7
Move GEOS-Chem deposition lists to common file with namelist defaults
lizziel Jul 21, 2022
45d4efe
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jul 25, 2022
d7e810f
Merge remote-tracking branch 'fvitt/dep_data_file' into temp_fvitt_pr…
lizziel Jul 27, 2022
9ab1b89
Updates to Neu wet dep in GEOS-Chem for Henry's Law coeffs from netcdf
lizziel Aug 4, 2022
4fa1cf4
Update Neu wet dep debug prints in GEOS-Chem
lizziel Aug 4, 2022
9fed226
Preliminary updates for GEOS-Chem 14.0
lizziel Aug 4, 2022
e8c43b2
Add debug print option within GEOS-Chem chemistry.F90
lizziel Aug 4, 2022
44c48db
Fixes for using GEOS-Chem 14.0
lizziel Aug 9, 2022
5c153c1
Updates to get gas-phase dry deposition when using GEOS-Chem to run
lizziel Aug 11, 2022
e565c30
Change geoschem .exclude file to use relative paths to files
lizziel Sep 13, 2022
03f75fd
Clean up new debug print code in physpkg.F90
lizziel Sep 13, 2022
e8b0747
Expand error prints in constituents module for clarify
lizziel Sep 13, 2022
a11b7e8
Remove online land type option when using GEOS-Chem and use Olson/XLAI
lizziel Sep 13, 2022
3a27896
Update GEOS-Chem chemistry log messages for clarity
lizziel Sep 16, 2022
d9d9f67
Remove unused code from GEOS-Chem chemistry.F90 file
lizziel Sep 16, 2022
5ddd22e
Externals update to use latest GEOS-Chem, HEMCO_CESM, and HEMCO
lizziel Sep 21, 2022
fd67bd8
Temporarily put wetdep and drydep lists in namelist file per GEOS-Che…
lizziel Sep 21, 2022
bfd2a09
Add deposition coefficient data file to GEOS-Chem use case files
lizziel Sep 21, 2022
5da5680
Minor edit to Neu wet deposition debug code when using GEOS-Chem
lizziel Sep 21, 2022
33de60e
Add non-advected GEOS-Chem species OH and HO2 to solsym for diagnostics
lizziel Sep 23, 2022
06985e5
Change default FCSD_GC year from 2005 to 2015
lizziel Sep 23, 2022
822cd06
Fix parameters incremented for non-advected species added to solysm
lizziel Sep 27, 2022
8056597
Change Default FCHIST_GC run startdate year from 2010 t0 2015
lizziel Sep 27, 2022
a89b9cb
Add friction velocity as a nuopc import in CAM
lizziel Sep 29, 2022
c8dd834
Add hemco_grid_xdim, hemco_grid_ydim namelist variables to configure …
jimmielin Oct 31, 2022
a9b8c51
Update HEMCO tag to hemco-cesm1_0_hemco3_5_0
jimmielin Oct 31, 2022
aefa2ef
Experimental first version of New History Diagnostics
jimmielin Oct 31, 2022
5cac78c
Disable legacy Jval_ approach; new history diags with debug (wip)
jimmielin Nov 1, 2022
3f0e725
Fix diagnostic chunk bug; now functional
jimmielin Nov 1, 2022
23a2ca7
Update HEMCO external to 3.5.1
jimmielin Nov 3, 2022
73b1cc2
Add FCnudged_GC component set based on FCnudged.
jimmielin Nov 3, 2022
edc6ebc
Merge pull request #9 from jimmielin/CESM-GC_rebased_on_cam6_0_034
lizziel Nov 3, 2022
babae9f
Add hist_geoschem_nudged.xml configuration for FCnudged_GC
jimmielin Nov 3, 2022
f19429e
Remove config_compsets.xml change that does not belong to this branch…
jimmielin Nov 3, 2022
dca0f5e
Expand CAM history field name maximum to 32 chars
jimmielin Nov 3, 2022
c74560a
Fix bug that was forcing HEMCO_Config.rc as hemco_config_file
jimmielin Nov 3, 2022
ea168b0
Fix typo in HEMCO-CESM tag
lizziel Nov 3, 2022
0af7d66
Remove debugging routines
jimmielin Nov 4, 2022
ecc9be2
Merge pull request #12 from jimmielin/hplin/fix-bld-namelist
lizziel Nov 9, 2022
17b6180
Fix HEMCO namelist bugs
lizziel Nov 9, 2022
13607ad
Upgrade GEOS-Chem to version 14.0.1
lizziel Nov 9, 2022
dc68379
Fix MEGAN emissions in CESM-GC - active_fall_flxvoc is a logical and …
jimmielin Nov 14, 2022
717e0fb
Merge pull request #13 from jimmielin/CESM-GC_rebased_on_cam6_0_034
lizziel Nov 14, 2022
224faaf
Add comments on xml source
jimmielin Nov 14, 2022
ad9f8d5
Merge pull request #10 from jimmielin/hplin/add_FCnudged_GC
lizziel Nov 15, 2022
07d197c
Update comments; remove more debug routines
jimmielin Nov 16, 2022
a0742f4
Remove array temporary allocations; now use one outTmp_3D and outTmp_…
jimmielin Nov 17, 2022
cbe679e
Remove unnecessary legacy code in cesmgc_diag_mod.F90
jimmielin Nov 17, 2022
0c6204e
Update comments; remove extraneous GC_FAILURE call to address review …
jimmielin Nov 17, 2022
6553464
Merge pull request #11 from CESM-GC/hplin/new_history_diags
lizziel Nov 17, 2022
74bb99d
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Nov 17, 2022
76bd32a
Change CMEPS and coupler remotes from fvitt to ESCOMP github
lizziel Dec 15, 2022
2001197
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Dec 15, 2022
a20ed2d
Reduce GEOS-Chem dir mozart files; build mozart and pp_none if geos-chem
lizziel Dec 21, 2022
9c5f0b4
Removed unused file geoschem/getLandTypes.F90
lizziel Jan 4, 2023
0458ae6
Modify mozart module mo_neu_wetdep for use when GEOS-Chem chemistry e…
lizziel Jan 4, 2023
c7d196c
Use mozart chem_prod_loss_diags.F90 rather than copy if GEOS-Chem ena…
lizziel Jan 4, 2023
ae549e2
Modifications to use Mozart short_lived_species module in GEOS-Chem
lizziel Jan 9, 2023
08ea9a3
Add missing GEOS-Chem diagnostics subroutine calls; cleanup other files
lizziel Jan 10, 2023
36afa14
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jan 11, 2023
f60ef7a
Update GEOS-Chem compset diagnostics list; fix build-namelist permiss…
lizziel Jan 11, 2023
f9de916
Update cam_physics_mesh defaults for HEMCO
lizziel Jan 12, 2023
0d98d57
Draft commit to support HEMCO_CESM v1.1.0.
jimmielin Jan 20, 2023
60861dc
Tag to upstream HEMCO-CESM 1.1.0 and HEMCO 3.6.0
jimmielin Feb 9, 2023
99e30ec
Fix automatic array indexing
jimmielin Feb 13, 2023
fb7acec
Updates H2SO4 production rate passed to MAM4 sulfate nucleation
jimmielin Mar 2, 2023
c5f6792
Use online CLM albedo for CESM-GC simulations instead of offline albe…
jimmielin Mar 2, 2023
5a79789
Merge pull request #17 from jimmielin/hplin/use_online_clm_albd
lizziel Mar 2, 2023
3bdbfd0
Merge pull request #16 from jimmielin/hplin/update_h2so4_prdr
lizziel Mar 2, 2023
f501dfb
Set rxt_tag_cnt to 0 in GEOS-Chem as feature is unused
jimmielin Mar 2, 2023
9126efb
Update cesmgc_diag_mod for moved ucx_mod module variables
jimmielin Mar 2, 2023
37b34b1
Remove LWI; remove cleanup_ucx
jimmielin Mar 2, 2023
0fadb7b
Update to upstream HEMCO-CESM 1.1.1 and HEMCO 3.6.2
jimmielin Mar 2, 2023
9af0d17
Also run Init_UCX per State_Chm, not just once
jimmielin Mar 3, 2023
a6a71d6
Add comments on aerosol mapping code
jimmielin Mar 3, 2023
50a0a11
Merge pull request #18 from jimmielin/hplin/change_rxntag
lizziel Mar 6, 2023
ec8b7b7
Merge pull request #14 from jimmielin/hplin/update_extlst_3d_emis
lizziel Mar 6, 2023
c1447e9
Merge pull request #19 from jimmielin/hplin/fix_cesmgc_diag_ucx
lizziel Mar 6, 2023
5afb293
Change GEOS-Chem version tag to 14.1.1
lizziel Mar 6, 2023
1cb1223
Change names of GEOS-Chem diagnostic and emissions modules and subrou…
lizziel Mar 6, 2023
99a6698
Move short-lived reference MMR array from chem_mods to short-lived mo…
lizziel Mar 6, 2023
b5c73f4
Merge remote-tracking branch 'origin/cam_development' into CESM-GC_re…
lizziel Mar 7, 2023
a924520
Delete unused GEOS-Chem build code
lizziel Mar 7, 2023
6688703
Assorted minor code cleanup; add preliminary GEOS-Chem tests
lizziel Mar 7, 2023
1dc7019
Now emit surface emissions consistently as a 3-D flux term.
jimmielin Mar 8, 2023
b245303
Merge pull request #21 from jimmielin/hplin/update_srf_emis
lizziel Mar 15, 2023
1a3fbcf
Fix SOA mapping indices
jimmielin Mar 17, 2023
e07c7d6
Fix TSKIN field to correct value
jimmielin Mar 20, 2023
bda2db3
Update upstream HEMCO-CESM 1.1.3
jimmielin Mar 20, 2023
935edbb
Fix other indices in the reverse direction.
jimmielin Mar 30, 2023
ab58d4e
Merge pull request #22 from jimmielin/hplin/fix_soa_map
lizziel Apr 12, 2023
217721d
Merge pull request #23 from jimmielin/hplin/fix_tskin
lizziel Apr 12, 2023
794d1ba
Fix dry and wet deposition for GEOS-Chem non-gas species.
jimmielin Apr 18, 2023
d77da0b
Merge pull request #24 from jimmielin/hplin/fix_aer_deposition
lizziel Apr 18, 2023
a16a4ff
Fix GEOS-Chem tests by replacing StrSplit in chem_readnl
lizziel Apr 18, 2023
9ed40a2
Merge remote-tracking branch 'upstream/cam_development' into CESM-GC_…
lizziel May 18, 2023
acfe426
Update lightning emissions code in GEOS-Chem interface for compatibility
lizziel May 18, 2023
006d314
Merge pull request #25 from CESM-GC/ewl/update_lightning_emissions_fo…
lizziel May 23, 2023
efc1efd
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jul 21, 2023
f71850c
Post-merge update to add pbuf argument to GEOS-Chem chem_emissions
lizziel Jul 28, 2023
5eb55a1
Updates to use HEMCO for GEOS-Chem compset
lizziel Jul 28, 2023
4563541
Minor cleanup changes
lizziel Jul 28, 2023
38d51b7
Remove HEMCO from src/control/cam_comp.F90
lizziel Aug 29, 2023
8796376
Fix how HEMCO is specified in GEOS-Chem compset configuration
lizziel Aug 29, 2023
750cf52
Use HEMCO config files in Buildconf/camconf when running with GEOS-Chem
lizziel Aug 29, 2023
a105233
Merge remote-tracking branch 'upstream/cam_development' into CESM-GC_…
lizziel Sep 1, 2023
dae6502
Remove unused code in configure and build-namelist
lizziel Sep 6, 2023
e1a6fd2
Use shr_kind_cl in GEOS-Chem character declarations; remove SPMD cpp …
lizziel Sep 6, 2023
8b3dff5
Always use ONLY keyword in USE statements
lizziel Sep 6, 2023
ac9e547
rename optional arg compare_uppercase; use spmd_utils and mpi_bcast
lizziel Sep 7, 2023
9418375
Change modal aerosol species name retrieval method
lizziel Sep 8, 2023
d37e70a
Unused code deletion and update setting short-lived species fieldnames
lizziel Sep 29, 2023
d43c4e8
Add script to copy GEOS-Chem config files during case setup
lizziel Oct 2, 2023
675afd0
Update deposition input file path used for GEOS-Chem
lizziel Oct 5, 2023
4e552bb
Copy GEOS-Chem configuration files from caseroot to run directory
lizziel Oct 5, 2023
99361e1
Updates to copy GEOS-Chem files to case and then run directory
lizziel Oct 13, 2023
6898cf7
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Oct 13, 2023
2731270
Change cam case_setup script from bash to python
lizziel Oct 13, 2023
c44c904
Fix typo in error message
lizziel Oct 13, 2023
ba31348
Change GEOS-Chem acronym in compset long name from GC to GEOSCHEM
lizziel Oct 13, 2023
da76f71
Change GEOS-Chem namelist and its parameter to use geoschem not gc
lizziel Oct 16, 2023
7f1d099
Updates for paper, SE grid compatibility, bug fixes
jimmielin Oct 17, 2023
a66be15
Slight formatting updates to GEOS-Chem run log output
jimmielin Oct 19, 2023
972c057
Update GEOS-Chem external tag to 14.1.2
jimmielin Oct 20, 2023
95bc735
Remove unnecessary comment about NTHRDS
lizziel Oct 20, 2023
cf0e7b6
Update Externals_CAM.cfg to use hash as 14.1.2 matches branch as well
jimmielin Oct 30, 2023
95cd2a5
Revert "Update Externals_CAM.cfg to use hash as 14.1.2 matches branch…
jimmielin Oct 30, 2023
1b5c281
Suggested changes to cam.case_setup.py
Oct 2, 2023
0d4bf3f
Fix bug and change error messages in cam.case_setup.py
lizziel Oct 31, 2023
6f86e11
Merge pull request #27 from jimmielin/hplin/updates_cgc_part1r
lizziel Nov 2, 2023
84e830d
Remove the FCSD_GC compset
lizziel Nov 3, 2023
15bbeef
Remove NTHRDS overrides for GEOS-Chem
lizziel Nov 3, 2023
392e9e3
Remove redundant includes of src/hemco in .gitignore
lizziel Nov 8, 2023
12d89ea
Exit with warning in build-namelist if hemco_config_file or hemco_dia…
jimmielin Nov 15, 2023
5c048af
Fix typo; indent with spaces
jimmielin Nov 15, 2023
fecbd92
Merge pull request #30 from jimmielin/hplin/nl_catch_hemco_error
lizziel Nov 16, 2023
cc85a5b
Split master deposition lists into two: mozart and geoschem
lizziel Nov 16, 2023
dcc7e20
Revert dep_data_file input_pathname to "abs"; use new file for geoschem
lizziel Nov 16, 2023
e06ddff
Merge remote-tracking branch 'origin/cam_development' into CESM-GC_re…
lizziel Dec 21, 2023
4441ce0
Merge branch 'cam_development' into CESM-GC_rebased_on_cam6_0_034
lizziel Jan 18, 2024
3558a95
Update bld/configure
lizziel Jan 18, 2024
14b6813
Clean up GEOS-Chem code in configure based on suggestions from Brian …
lizziel Jan 18, 2024
6319c77
Remove unnecessary changes made for GEOS-Chem; minor bug fix for GNU
lizziel Jan 23, 2024
3301267
Revert setting GEOS-Chem $chem_cppdefs to earlier in configure
lizziel Jan 30, 2024
9a4144a
Remove project paths to GEOS-Chem inputs; now stored in inputdata
lizziel Jan 30, 2024
c18380c
Updated GEOs-Chem tests from cheyenne to derecho
lizziel Jan 30, 2024
5d05e8c
Add categories prealpha and aux_cam to all GEOS-Chem compset tests
lizziel Jan 30, 2024
5fa370c
Delete redundant setting of deposition lists in namelists
lizziel Jan 31, 2024
28412bf
Reduce GEOS-Chem tests to one aux_cam and one prealpha across two com…
lizziel Jan 31, 2024
e9773d8
Merge remote-tracking branch 'upstream/cam_development' into CESM-GC_…
lizziel Jan 31, 2024
40371e4
Change FCnudged_GC derecho test to not use zonal mean nudging
lizziel Jan 31, 2024
ffec5d1
skip over geoschem in r8 kind checker
fvitt Feb 1, 2024
a5e78df
Update Changelog
lizziel Feb 1, 2024
4442c2a
include commit and time limit to goes-chem tests
fvitt Feb 1, 2024
86720cc
update ChangLog
fvitt Feb 2, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ src/physics/carma/base
src/physics/clubb
src/physics/cosp2/src
src/physics/silhs
src/chemistry/geoschem/geoschem_src
src/hemco
src/physics/pumas
src/physics/pumas-frozen
src/dynamics/fv3/atmos_cubed_sphere
Expand Down
9 changes: 8 additions & 1 deletion Externals_CAM.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,18 @@ sparse = ../.mpas_sparse_checkout
hash = ff76a231
required = True

[geoschem]
local_path = src/chemistry/geoschem/geoschem_src
protocol = git
repo_url = https://github.com/geoschem/geos-chem.git
tag = 14.1.1
required = True

[hemco]
local_path = src/hemco
tag = hemco-cesm1_2_0_hemco3_6_2_cesm
protocol = git
repo_url = https://github.com/ESCOMP/HEMCO_CESM.git
tag = hemco-cesm1_2_0_hemco3_6_2_cesm
required = True
externals = Externals_HCO.cfg

Expand Down
101 changes: 89 additions & 12 deletions bld/build-namelist
Original file line number Diff line number Diff line change
Expand Up @@ -540,7 +540,7 @@ my $rad_prog_bcarb = (($prog_species =~ "BC" or $aero_chem) and !($chem_rad_pa
my $rad_prog_sulf = (($prog_species =~ "SO4" or $aero_chem) and !($chem_rad_passive));
my $rad_prog_dust = (($prog_species =~ "DST" or $aero_chem) and !($chem_rad_passive));
my $rad_prog_sslt = (($prog_species =~ "SSLT" or $aero_chem) and !($chem_rad_passive));
my $rad_prog_ozone = (($chem =~ "mozart" or $chem =~ "waccm_ma" or $chem =~ "tsmlt" or $chem =~ "trop_strat") and !($chem_rad_passive));
my $rad_prog_ozone = (($chem =~ "mozart" or $chem =~ "waccm_ma" or $chem =~ "tsmlt" or $chem =~ "trop_strat" or $chem =~ /geoschem/) and !($chem_rad_passive));

# Check for eruptive volcano emissions. These will be radiatively active by default, but
# only if using BAM and the camrt radiation package
Expand Down Expand Up @@ -582,6 +582,11 @@ if ( ($chem ne 'none') or ( $prog_species ) ){
add_default($nl, 'gas_wetdep_method' );
add_default($nl, 'gas_wetdep_list', 'val'=>$gas_wetdep_list );
}

if ($chem =~ /geoschem/) {
$prescribe_aerosols = $FALSE;
}

brian-eaton marked this conversation as resolved.
Show resolved Hide resolved
if (length($aer_wetdep_list)>2){
# determine if prescribed aerosols are not needed ...
if ($aer_wetdep_list =~ /so4/i &&
Expand Down Expand Up @@ -612,6 +617,10 @@ if ( ($chem ne 'none') or ( $prog_species ) ){
if (length($aer_drydep_list)>2){
add_default($nl, 'aer_drydep_list', 'val'=>$aer_drydep_list );
}
$nl->set_variable_value('aerosol_nl', 'aer_drydep_list', $aer_drydep_list);
$nl->set_variable_value('aerosol_nl', 'aer_wetdep_list', $aer_wetdep_list);
$nl->set_variable_value('drydep_inparm', 'drydep_list', $gas_drydep_list);
$nl->set_variable_value('wetdep_inparm', 'gas_wetdep_list', $gas_wetdep_list);
brian-eaton marked this conversation as resolved.
Show resolved Hide resolved
}
if ($chem) {
# drydep_srf_file is only needed for prognostic MAM when the grid is unstructured.
Expand Down Expand Up @@ -862,7 +871,7 @@ my $radval = "'A:Q:H2O'";
if (($chem =~ /waccm_ma/ or $chem =~ /waccm_tsmlt/) and !$chem_rad_passive) {
$radval .= ",'A:O2:O2','A:CO2:CO2'";
}
elsif ($chem =~ /trop_strat/ and !$chem_rad_passive) {
elsif (($chem =~ /trop_strat/ or $chem =~ /geoschem/) and !$chem_rad_passive) {
$radval .= ",'N:O2:O2','A:CO2:CO2'";
}
elsif (($co2_cycle and !$co2_cycle_rad_passive) or ($chem =~ /ghg_mam4/)) {
Expand Down Expand Up @@ -897,6 +906,8 @@ if ((($chem =~ /ghg_mam4/) or ($chem =~ /waccm_ma/) or ($chem =~ /waccm_sc_mam/)
$radval .= ",'A:N2O:N2O','A:CH4:CH4','A:CFC11:CFC11','A:CFC12:CFC12'";
} elsif ($prog_ghg1 and !$prog_ghg2 and !$chem_rad_passive ) {
$radval .= ",'A:N2O:N2O','A:CH4:CH4','N:CFC11:CFC11','N:CFC12:CFC12'";
} elsif ($chem =~ /geoschem/) {
$radval .= ",'A:N2O:N2O','A:CH4:CH4','A:CFC11:CFC11','A:CFC12:CFC12'";
} else {
$radval .= ",'N:N2O:N2O','N:CH4:CH4','N:CFC11:CFC11','N:CFC12:CFC12'";
}
Expand Down Expand Up @@ -2018,6 +2029,38 @@ if (($chem =~ /trop_mozart/ or $chem =~ /trop_strat/ or $chem =~ /waccm_tsmlt/)
}
}

if ($chem =~ /geoschem/) {

my $val;

# Species with fixed lower boundary
$val = "'CCL4','CH4','N2O','CO2','CFC11','CFC12','CH3BR','CH3CCL3','CH3CL'"
.",'HCFC22','CFC114','CFC115','HCFC141B','HCFC142B','CH2BR2','CHBR3','H2402'";

if ($chem_has_ocs) {
$val .= ",'OCS'";
}
if (chem_has_species($cfg, 'SF6')) {
$val .= ",'SF6'";
}
add_default($nl, 'flbc_list', 'val'=>$val);
unless (defined $nl->get_value('flbc_type')) {
add_default($nl, 'flbc_type', 'val'=>'CYCLICAL');
add_default($nl, 'flbc_cycle_yr', 'val'=>'2000');
}

my @files;
# Datasets
#@files = ( 'soil_erod_file', 'flbc_file',
# 'xs_coef_file','xs_short_file',
# 'xs_long_file', 'rsf_file',
# 'exo_coldens_file', 'sulf_file' );
lizziel marked this conversation as resolved.
Show resolved Hide resolved
@files = ( 'soil_erod_file', 'flbc_file' );
foreach my $file (@files) {
add_default($nl, $file);
}
}

if ($chem =~ /trop_mozart/ or $chem =~ /trop_strat/ or $chem =~ /waccm_tsmlt/) {

my $val;
Expand Down Expand Up @@ -2364,10 +2407,12 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
}
}
}
add_default($nl, 'srf_emis_specifier', 'val'=>$val);
unless (defined $nl->get_value('srf_emis_type')) {
add_default($nl, 'srf_emis_type', 'val'=>'CYCLICAL');
add_default($nl, 'srf_emis_cycle_yr', 'val'=>2000);
if ($chem !~ /geoschem/) {
add_default($nl, 'srf_emis_specifier', 'val'=>$val);
unless (defined $nl->get_value('srf_emis_type')) {
add_default($nl, 'srf_emis_type', 'val'=>'CYCLICAL');
add_default($nl, 'srf_emis_cycle_yr', 'val'=>2000);
}
}

# Vertical emission datasets:
Expand Down Expand Up @@ -2428,10 +2473,12 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
$first = 0;
}
}
add_default($nl, 'ext_frc_specifier', 'val'=>$val);
unless (defined $nl->get_value('ext_frc_type')) {
add_default($nl, 'ext_frc_type', 'val'=>"'CYCLICAL'");
add_default($nl, 'ext_frc_cycle_yr', 'val'=>2000);
if ($chem !~ /geoschem/) {
add_default($nl, 'ext_frc_specifier', 'val'=>$val);
unless (defined $nl->get_value('ext_frc_type')) {
add_default($nl, 'ext_frc_type', 'val'=>"'CYCLICAL'");
add_default($nl, 'ext_frc_cycle_yr', 'val'=>2000);
}
}

# MEGAN emissions
Expand Down Expand Up @@ -2477,6 +2524,30 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
add_default($nl, 'megan_factors_file');
add_default($nl, 'megan_mapped_emisfctrs', 'val'=>'.false.');
}
if ($chem =~ /geoschem/) {
my $val = "'ISOP = isoprene',"
. "'MOH = methanol',"
. "'EOH = ethanol',"
. "'CH2O = formaldehyde',"
. "'ALD2 = acetaldehyde',"
. "'ACTA = acetic_acid',"
. "'ACET = acetone',"
. "'HCOOH = formic_acid',"
. "'HCN = hydrogen_cyanide',"
. "'CO = carbon_monoxide',"
. "'C2H6 = ethane',"
. "'C2H4 = ethene',"
. "'C3H8 = propane',"
. "'ALK4 = pentane + hexane + heptane + tricyclene',"
. "'PRPE = propene + butene',"
. "'TOLU = toluene',"
. "'LIMO = limonene',"
. "'MTPA = pinene_a + pinene_b + sabinene + carene_3',"
. "'MTPO = terpinene_g + terpinene_a + terpinolene + myrcene + ocimene_al + ocimene_t_b + ocimene_c_b + thujene_a + 2met_styrene + cymene_p + cymene_o + bornene + fenchene_a + camphene + phellandrene_a + phellandrene_b'";
add_default($nl, 'megan_specifier', 'val'=>$val);
add_default($nl, 'megan_factors_file');
add_default($nl, 'megan_mapped_emisfctrs', 'val'=>'.false.');
}
if ($chem =~ /trop_strat_mam4_vbs/ or $chem =~ /trop_strat_mam5_vbs/) {
my $val = "'ISOP = isoprene',"
. "'MTERP = carene_3 + pinene_a + thujene_a + bornene + terpineol_4 + terpineol_a + terpinyl_ACT_a "
Expand Down Expand Up @@ -2892,6 +2963,12 @@ if ($nl->get_value('use_hemco') =~ m/$TRUE/io) {
# ignored at runtime when HEMCO is used.
$nl->delete_variable('chem_inparm', 'ext_frc_specifier');
$nl->delete_variable('chem_inparm', 'srf_emis_specifier');

# If using GEOS-Chem reset paths of HEMCO configuration files to local filename only
if ($chem =~ /geoschem/) {
$nl->set_variable_value('hemco_nl', 'hemco_config_file', "'HEMCO_Config.rc'");
$nl->set_variable_value('hemco_nl', 'hemco_diagn_file', "'HEMCO_Diagn.rc'");
}
}

# Physics options
Expand Down Expand Up @@ -3020,7 +3097,7 @@ if (!$simple_phys) {
}

# tropopause level used in gas-phase / aerosol processes
if (($chem ne 'none') and ($chem ne 'terminator')) {
if (($chem ne 'none') and ($chem ne 'terminator') and !($chem =~ /geoschem/)) {
add_default($nl, 'chem_use_chemtrop');
}

Expand Down Expand Up @@ -3537,7 +3614,7 @@ if ( length($nl->get_value('soil_erod_file'))>0 ) {
add_default($nl, 'dust_emis_fact', 'tms'=>'1');
}
else {
if ($chem =~ /trop_strat/ or $chem =~ /waccm_ma/ or $chem =~ /waccm_tsmlt/ or $chem =~ /trop_mozart/) {
if ($chem =~ /trop_strat/ or $chem =~ /geoschem/ or $chem =~ /waccm_ma/ or $chem =~ /waccm_tsmlt/ or $chem =~ /trop_mozart/) {
add_default($nl, 'dust_emis_fact', 'ver'=>'chem');
}
else {
Expand Down
4 changes: 2 additions & 2 deletions bld/config_files/definition.xml
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,8 @@ meteor_smoke (Meteor Smoke), mixed_sulfate (Meteor Smoke and Sulfate), pmc (Pola
sulfate (Sulfate Aerosols), tholin (early earth haze), test_detrain (Detrainment), test_growth (Particle Growth), test_passive (Passive Dust),
test_radiative (Radiatively Active Dust), test_swelling (Sea Salt), test_tracers (Asian Monsoon), test_tracers2 (Guam).
</entry>
<entry id="chem" valid_values="none,ghg_mam4,terminator,trop_mam3,trop_mam4,trop_mam7,trop_mozart,trop_strat_mam4_ts2,trop_strat_mam4_vbs,trop_strat_mam4_vbsext,trop_strat_mam5_ts2,trop_strat_mam5_vbs,trop_strat_mam5_vbsext,waccm_ma,waccm_mad,waccm_ma_sulfur,waccm_sc,waccm_sc_mam4,waccm_mad_mam4,waccm_ma_mam4,waccm_tsmlt_mam4,waccm_tsmlt_mam4_vbsext,waccm_mad_mam5,waccm_ma_mam5,waccm_tsmlt_mam5,waccm_tsmlt_mam5_vbsext" value="">
Chemistry package: none,ghg_mam4,terminator,trop_mam3,trop_mam4,trop_mam7,trop_mozart,trop_strat_mam4_ts2,trop_strat_mam4_vbs,trop_strat_mam4_vbsext,trop_strat_mam5_ts2,trop_strat_mam5_vbs,trop_strat_mam5_vbsext,waccm_ma,waccm_mad,waccm_ma_sulfur,waccm_sc,waccm_sc_mam4,waccm_mad_mam4,waccm_ma_mam4,waccm_tsmlt_mam4,waccm_tsmlt_mam4_vbsext,waccm_mad_mam5,waccm_ma_mam5,waccm_tsmlt_mam5,waccm_tsmlt_mam5_vbsext
<entry id="chem" valid_values="none,ghg_mam4,terminator,trop_mam3,trop_mam4,trop_mam7,trop_mozart,trop_strat_mam4_ts2,trop_strat_mam4_vbs,trop_strat_mam4_vbsext,trop_strat_mam5_ts2,trop_strat_mam5_vbs,trop_strat_mam5_vbsext,waccm_ma,waccm_mad,waccm_ma_sulfur,waccm_sc,waccm_sc_mam4,waccm_mad_mam4,waccm_ma_mam4,waccm_tsmlt_mam4,waccm_tsmlt_mam4_vbsext,waccm_mad_mam5,waccm_ma_mam5,waccm_tsmlt_mam5,waccm_tsmlt_mam5_vbsext,geoschem_mam4" value="">
Chemistry package: none,ghg_mam4,terminator,trop_mam3,trop_mam4,trop_mam7,trop_mozart,trop_strat_mam4_ts2,trop_strat_mam4_vbs,trop_strat_mam4_vbsext,trop_strat_mam5_ts2,trop_strat_mam5_vbs,trop_strat_mam5_vbsext,waccm_ma,waccm_mad,waccm_ma_sulfur,waccm_sc,waccm_sc_mam4,waccm_mad_mam4,waccm_ma_mam4,waccm_tsmlt_mam4,waccm_tsmlt_mam4_vbsext,waccm_mad_mam5,waccm_ma_mam5,waccm_tsmlt_mam5,waccm_tsmlt_mam5_vbsext,geoschem_mam4
</entry>
<entry id="prog_species" valid_values="DST,SSLT,SO4,GHG,OC,BC,CARBON16" value="" list="1">
Prognostic mozart species packages: list of any subset of the following: DST,SSLT,SO4,GHG,OC,BC,CARBON16
Expand Down
51 changes: 41 additions & 10 deletions bld/configure
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ OPTIONS
trop_strat_mam4_vbs | trop_strat_mam4_vbsext | trop_strat_mam5_ts2 | trop_strat_mam5_vbs |
trop_strat_mam5_vbsext | waccm_ma | waccm_mad | waccm_ma_sulfur | waccm_sc | waccm_sc_mam4 |
waccm_mad_mam4 | waccm_ma_mam4 | waccm_tsmlt_mam4 | waccm_tsmlt_mam4_vbsext | waccm_mad_mam5 |
waccm_ma_mam5 | waccm_tsmlt_mam5 | waccm_tsmlt_mam5_vbsext ].
waccm_ma_mam5 | waccm_tsmlt_mam5 | waccm_tsmlt_mam5_vbsext | geoschem_mam4 ].
Default: trop_mam4 for cam6 and trop_mam3 for cam5.
-[no]clubb_sgs Switch on [off] CLUBB_SGS. Default: on for cam6, otherwise off.
-clubb_opts <list> Comma separated list of CLUBB options to turn on/off. By default they are all off.
Expand All @@ -80,6 +80,7 @@ OPTIONS
-cpl Coupling framework [mct | nuopc]. Default: mct.
-dyn <name> Dynamical core option: [eul | fv | se | fv3 | mpas]. Default: fv.
-edit_chem_mech Invokes CAMCHEM_EDITOR to allow the user to edit the chemistry mechanism file
-hemco Switch enables the use of the Harmonized Emissions Component.
lizziel marked this conversation as resolved.
Show resolved Hide resolved
-hgrid <name> Specify horizontal grid. Use nlatxnlon for spectral grids;
dlatxdlon for fv grids (dlat and dlon are the grid cell size
in degrees for latitude and longitude respectively); nexnp for
Expand Down Expand Up @@ -263,6 +264,7 @@ GetOptions(
"fv3core_libdir=s" => \$opts{'fv3core_libdir'},
"gmake=s" => \$opts{'gmake'},
"h|help" => \$opts{'help'},
"hemco" => \$opts{'hemco'},
"hgrid=s" => \$opts{'hgrid'},
"ionosphere=s" => \$opts{'ionosphere'},
"lapack_libdir=s" => \$opts{'lapack_libdir'},
Expand Down Expand Up @@ -592,10 +594,10 @@ if (defined $opts{'chem'}) {

# If the user has specified a simple physics package...
if ($simple_phys) {
# the only valid chemistry options are 'none' and 'terminator'
if (($chem_pkg ne 'none') and ($chem_pkg ne 'terminator')) {
# the only valid chemistry options are 'none', 'terminator' and 'geoschem'
if (($chem_pkg ne 'none') and ($chem_pkg ne 'terminator') and !($chem_pkg =~ 'geoschem')) {
die "configure ERROR: -phys=$phys_pkg -chem=$chem_pkg\n".
" -chem can only be set to 'none' or 'terminator'.\n";
" -chem can only be set to 'none', 'terminator' or 'geoschem'.\n";
brian-eaton marked this conversation as resolved.
Show resolved Hide resolved
}
}
elsif ($phys_pkg =~ m/^cam3$|^cam4$|^spcam_sam1mom$/) {
Expand Down Expand Up @@ -1356,7 +1358,11 @@ my $chem_cppdefs = '';
my $chem_src_dir = '';

if (!$prog_species) {
$chem_src_dir = "$cam_dir/src/chemistry/pp_$chem_pkg";
if ($chem_pkg =~ 'geoschem') {
$chem_src_dir = "$cam_dir/src/chemistry/geoschem";
} else {
$chem_src_dir = "$cam_dir/src/chemistry/pp_$chem_pkg";
}
$cfg_ref->set('chem_src_dir', $chem_src_dir);
}

Expand All @@ -1383,10 +1389,10 @@ if ($customize) {
}
if ($print>=2) { print "Chem preprocessor compiler: $chemproc_fc $eol"; }
($chem_nadv) = chem_preprocess($cfg_ref,$print,$chemproc_fc);
} elsif ($chem_pkg ne 'none') {
} elsif ($chem_pkg ne 'none' and $chem_pkg !~ 'geoschem') {
# copy over chem docs
copy("$chem_src_dir/chem_mech.doc",$cam_bld) or die "copy failed $! \n";
copy("$chem_src_dir/chem_mech.in" ,$cam_bld) or die "copy failed $! \n";
copy("$chem_src_dir/chem_mech.doc",$cam_bld) or die "copy of chem_mec.doc failed $! \n";
copy("$chem_src_dir/chem_mech.in" ,$cam_bld) or die "copy of chem_mech.in failed $! \n";
($chem_nadv) = chem_number_adv($chem_src_dir);
}

Expand All @@ -1400,6 +1406,13 @@ if ($chem_pkg =~ '_mam3') {
$chem_cppdefs = ' -DMODAL_AERO -DMODAL_AERO_7MODE ';
}

# Set GEOS-Chem CPP definitions here
if ($chem_pkg =~ 'geoschem') {
$chem_cppdefs .= ' -DEXTERNAL_GRID -DEXTERNAL_FORCING -DLINUX_IFORT -DUSE_REAL8 -DMODEL_ -DMODEL_CESM';
$chem_nadv = 267; # includes GC advected species (233), CO2 (1), and MAM aerosols (33)
}


brian-eaton marked this conversation as resolved.
Show resolved Hide resolved
# CARMA sectional microphysics
#
# New CARMA models need to define the number of advected constituents.
Expand Down Expand Up @@ -1563,6 +1576,12 @@ if ($print>=2) { print "Total advected constituents: $nadv$eol"; }

#-----------------------------------------------------------------------------------------------

# Harmonized Emissions Component (HEMCO)
if (defined $opts{'hemco'}) {
$cfg_ref->set('hemco', $opts{'hemco'});
}
my $hemco = $cfg_ref->get('hemco');

#-----------------------------------------------------------------------------------------------
# Makefile configuration #######################################################################
#-----------------------------------------------------------------------------------------------
Expand Down Expand Up @@ -2093,6 +2112,7 @@ sub write_filepath
my $waccm_phys = $cfg_ref->get('waccm_phys');
my $waccmx = $cfg_ref->get('waccmx');
my $ionos = $cfg_ref->get('ionosphere');
my $hemco = $cfg_ref->get('hemco');
my $carma = $cfg_ref->get('carma');
my $rad = $cfg_ref->get('rad');
my $dyn = $cfg_ref->get('dyn');
Expand Down Expand Up @@ -2157,10 +2177,21 @@ sub write_filepath
if ($chem_src_dir) {
print $fh "$chem_src_dir\n";
}

# GEOS-Chem must be prior to Mozart
if ($chem_pkg =~ 'geoschem') {
print $fh "$chem_src_dir/geoschem_src/GeosCore\n";
print $fh "$chem_src_dir/geoschem_src/GeosUtil\n";
print $fh "$chem_src_dir/geoschem_src/Headers\n";
print $fh "$chem_src_dir/geoschem_src/ISORROPIA\n";
print $fh "$chem_src_dir/geoschem_src/KPP/fullchem\n";
print $fh "$camsrcdir/src/chemistry/pp_none\n";
}

if ($chem =~ /_mam/) {
print $fh "$camsrcdir/src/chemistry/modal_aero\n";
print $fh "$camsrcdir/src/chemistry/modal_aero\n";
} else {
print $fh "$camsrcdir/src/chemistry/bulk_aero\n";
print $fh "$camsrcdir/src/chemistry/bulk_aero\n";
}
print $fh "$camsrcdir/src/chemistry/aerosol\n";

Expand Down
Loading