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

Dust fluxes output and add descriptions in the xml-namelist file #420

Merged
merged 6 commits into from
Oct 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
29 changes: 24 additions & 5 deletions cime_config/buildnml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def buildnml(case, caseroot, compname):
hamocc_extncycle = case.get_value("HAMOCC_EXTNCYCLE")
hamocc_n2oc = case.get_value("HAMOCC_N2OC")
hamocc_atmndepc = case.get_value("HAMOCC_ATMNDEPC")
hamocc_m4ago = case.get_value("HAMOCC_M4AGO")
hamocc_sinking_scheme = case.get_value("HAMOCC_SINKING_SCHEME")
hamocc_sedbypass = case.get_value("HAMOCC_SEDBYPASS")
hamocc_sedspinup = case.get_value("HAMOCC_SEDSPINUP")
hamocc_sedspinup_yr_start = case.get_value("HAMOCC_SEDSPINUP_YR_START")
Expand Down Expand Up @@ -192,7 +192,6 @@ def buildnml(case, caseroot, compname):
config["hamocc_extncycle"] = "yes" if hamocc_extncycle else "no"
config["hamocc_n2oc"] = "yes" if hamocc_n2oc else "no"
config["hamocc_atmndepc"] = "yes" if hamocc_atmndepc else "no"
config["hamocc_m4ago"] = "yes" if hamocc_m4ago else "no"
config["hamocc_sedbypass"] = "yes" if hamocc_sedbypass else "no"
config["hamocc_sedspinup"] = "yes" if hamocc_sedspinup else "no"
config["hamocc_sedspinup_yr_start"] = hamocc_sedspinup_yr_start
Expand All @@ -201,9 +200,29 @@ def buildnml(case, caseroot, compname):
config["is_test"] = "yes" if is_test else "no"
config["comp_interface"] = comp_interface

# TODO: the following needs to have new ways to turn this to "yes"
config["use_agg"] = "no"
config["use_wlin"] = "yes"
# Set the sinking scheme in iHAMOCC
# Note: the following part requires to have set options for no/yes
# in the namelist_definition_blom.xml for the 'use_XXX' switches
if hamocc_sinking_scheme == 'WLIN': # current default
config['use_wlin'] = 'yes'
config['use_agg'] = 'no'
config['use_m4ago'] = 'no'
elif hamocc_sinking_scheme == 'M4AGO':
config['use_wlin'] = 'no'
config['use_agg'] = 'no'
config['use_m4ago'] = 'yes'
elif hamocc_sinking_scheme == 'AGG':
config['use_wlin'] = 'no'
config['use_agg'] = 'yes'
config['use_m4ago'] = 'no'
elif hamocc_sinking_scheme == 'CONST':
# if all options are 'no' iHAMOCC falls back to constant sinking velocities
config['use_wlin'] = 'no'
config['use_agg'] = 'no'
config['use_m4ago'] = 'no'
else: # likely doesn't enter here due to previous cime checkings for available options
print('Unknown sinking scheme option in BLOM buildnml- exit now')
exit

if is_test:
testcase = case.get_value("TESTCASE")
Expand Down
10 changes: 5 additions & 5 deletions cime_config/config_component.xml
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,13 @@
<desc>N2O and NH3 fluxes coupled from atmosphere. Requires module ecosys and extncycle</desc>
</entry>

<entry id="HAMOCC_M4AGO">
<type>logical</type>
<valid_values>TRUE,FALSE</valid_values>
<default_value>FALSE</default_value>
<entry id="HAMOCC_SINKING_SCHEME">
<type>char</type>
<valid_values>WLIN,M4AGO,AGG,CONST</valid_values>
<default_value>WLIN</default_value>
<group>run_component_blom</group>
<file>env_run.xml</file>
<desc>Set namelist option to activate the M4AGO sinking scheme. Requires module ecosys</desc>
<desc>Namelist option to set sinking scheme. Requires module ecosys</desc>
</entry>

<entry id="HAMOCC_PREF_TRACERS">
Expand Down
Loading