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

Full Wave Momentum Coupling #104

Open
wants to merge 57 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
5f7fbe4
Adds a lower limit to stem allocation to avoid negative states
thorntonpe May 23, 2024
67ae4d5
Merge branch 'thorntonpe/lnd/negc_debug' (PR #6589)
bishtgautam Nov 1, 2024
00f42a7
Add ICOS30 Wave Mesh.
erinethomas Sep 11, 2024
158d9ce
mask out sotkes drift under ice shelves for icos mesh.
erinethomas Sep 25, 2024
8cbd06e
add wave-ice remapping files for wQU225Icos30
erinethomas Sep 12, 2024
b9a8485
add wav-ocean flux,wav-ice remapping file definitions for ICOS wave mesh
erinethomas Sep 12, 2024
c8b9aa5
add wave to ocean FLUX remapper
erinethomas Sep 25, 2024
a8e5d2d
remove wav-atm, wav-ice coupling (for future PR)
erinethomas Sep 30, 2024
2b82016
remove seq_map_map call for wave to ocn fluxes (no fluxes coupled yet)
erinethomas Oct 1, 2024
f346119
add B case ICOS test to wav_developer test suite
erinethomas Oct 1, 2024
b1a35ff
trim down wav dev test suite
erinethomas Oct 22, 2024
0404047
correction to langmuir mixing logic for LandIce Mask.
erinethomas Oct 28, 2024
d9ced43
cleanup whitespace
erinethomas Nov 5, 2024
0a87f8b
remove flux wave to ocean remapping (will be done in later PR)
erinethomas Nov 5, 2024
15a544b
remove white space
erinethomas Nov 5, 2024
492554f
remove WAV2OCN_FMAPNAME
erinethomas Nov 5, 2024
ed5d04f
remove wav to ocean flux remapping
erinethomas Nov 5, 2024
abfd375
clean up seq_map_map line for Sw2o
erinethomas Nov 5, 2024
7e7c437
Add wind stress variables for wave momentum coupling to output streams.
Feb 20, 2024
175f562
Add Momentum coupling variables passed from driver to MPAS-O
Feb 20, 2024
90d2f18
Add wave momentum coupling variablesfrom drivert to ocn_comp_mct
Feb 20, 2024
bcc07ba
add Wave momentum coupling variable to MPAS-O Registry
Feb 20, 2024
114d842
Add wave to driver momentum coupling variables
Feb 20, 2024
5c80426
Add wave momentum coupling stress variables to seq_flds_mod
Feb 20, 2024
ad013a7
Add charnock SeaState to shr_flux_mod
OlawaleClimate Apr 23, 2022
6f46f58
Couple atm and wave through charnock sea state
OlawaleClimate Apr 24, 2022
59ccb7c
add xtime to wave output
Feb 20, 2024
8d7f089
modify ocean stress by wave effect (components/mpas-ocean/driver/ocn_…
Feb 20, 2024
cbcedb3
add config namelist for momentum coupling
May 2, 2024
f137dbe
adding wav_atm_coup and wav_ocn_coup flags
May 30, 2024
7ef793f
replace ocn_wave flag with new wav_ocn_coup flag
May 31, 2024
65e4039
fix to wav_ocn_coup flag
May 31, 2024
24de407
bug fix to wav_ocn_coup
May 31, 2024
182ad3e
testing wav_ocn_coup settings
Jun 4, 2024
99e5dc7
syntax fix the buildnml for drv_in for wav_coupling variables
Jun 6, 2024
1659784
change all wave coupling namelists from boolean to char.
Jun 7, 2024
bb6c0b2
add wav_ocn_coup to prep_ocn_mod
Jun 11, 2024
815b05f
add F+WW3 compset
Jun 11, 2024
ed670c1
modify F+WW3 compset
Jun 13, 2024
fc8782a
preliminary pe config for anvil and chrys for B compsets with WW3.
Jun 28, 2024
0294558
edit PE layout for anvil
Jun 28, 2024
0c4fd2e
final PE layout for B+WW3 on ANVIL
Jul 8, 2024
2fb6986
add comment to shr_flux_mod about coare3.0 w/ wave coupling. update a…
Jul 10, 2024
7b79a5e
add monthly and daily wave output streams
erinethomas Jul 26, 2024
4f6eefa
bug fix (remove duplicate line) and update pio format.
erinethomas Aug 8, 2024
a5bcfcf
update PE layout for fully coupled wave compsets, clean up namelist s…
erinethomas Aug 12, 2024
758443f
fix wav coupling flags
erinethomas Sep 26, 2024
d2cc42c
put wave output in default MPAS-O files (to ensure correct time serie…
erinethomas Sep 26, 2024
ea91ea2
add wave to ocn flux cime_config/config_grids.xml
erinethomas Nov 5, 2024
a9a077c
wave to ocn flux driver-mct/cime_config/config_component.xml
erinethomas Nov 5, 2024
606c549
wave to ocn flux driver-mct/cime_config/namelist_definition_drv.xml
erinethomas Nov 5, 2024
3325462
flux wave to ocn prep_ocn_mod.F90
erinethomas Nov 5, 2024
52e755d
remove lines that were commented out
erinethomas Nov 5, 2024
f053888
fix rebase on ICOS mesh
erinethomas Nov 6, 2024
1d22ac1
add wav2atm smap
erinethomas Nov 6, 2024
4c99f2a
remove 'two' way coupling option from wav_ic_coup
erinethomas Nov 6, 2024
a174729
add WAV2ATM remap file for EC30to60 grid
erinethomas Nov 7, 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
118 changes: 62 additions & 56 deletions cime_config/allactive/config_pesall.xml
Original file line number Diff line number Diff line change
Expand Up @@ -624,6 +624,36 @@
<rootpe_cpl>0</rootpe_cpl>
</rootpe>
</pes>
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+MOSART.+SGLC.+WW3." pesize="any">
<comment>anvil --compset WCYCL+ww3 --res ne30pg2_EC30to60E2r2_wQU225EC30to60E2r2 </comment>
<ntasks>
<ntasks_atm>1350</ntasks_atm>
<ntasks_lnd>72</ntasks_lnd>
<ntasks_rof>72</ntasks_rof>
<ntasks_ice>1296</ntasks_ice>
<ntasks_ocn>180</ntasks_ocn>
<ntasks_cpl>1368</ntasks_cpl>
<ntasks_wav>252</ntasks_wav>
</ntasks>
<rootpe>
<rootpe_atm>0</rootpe_atm>
<rootpe_lnd>1296</rootpe_lnd>
<rootpe_rof>1296</rootpe_rof>
<rootpe_ice>0</rootpe_ice>
<rootpe_ocn>1368</rootpe_ocn>
<rootpe_cpl>0</rootpe_cpl>
<rootpe_wav>1548</rootpe_wav>
</rootpe>
<nthrds>
<nthrds_atm>1</nthrds_atm>
<nthrds_lnd>1</nthrds_lnd>
<nthrds_rof>1</nthrds_rof>
<nthrds_ice>1</nthrds_ice>
<nthrds_ocn>1</nthrds_ocn>
<nthrds_cpl>1</nthrds_cpl>
<nthrds_wav>1</nthrds_wav>
</nthrds>
</pes>
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+SGLC_SWAV_SIAC_SESP_BGC.*" pesize="M">
<comment>anvil: --compset BGC* --res ne30pg2_r05_EC30to60E2r2 on 30 nodes pure-MPI, ~3 sypd </comment>
<ntasks>
Expand All @@ -644,6 +674,38 @@
</rootpe>
</pes>
</mach>
<mach name="chrysalis">
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+MOSART.+SGLC.+WW3." pesize="any">
<comment>chrysalis --compset WCYCL+ww3 --res ne30pg2_EC30to60E2r2_wQU225EC30to60E2r2 </comment>
<ntasks>
<ntasks_atm>1024</ntasks_atm>
<ntasks_lnd>384</ntasks_lnd>
<ntasks_rof>384</ntasks_rof>
<ntasks_ice>640</ntasks_ice>
<ntasks_cpl>1024</ntasks_cpl>
<ntasks_ocn>256</ntasks_ocn>
<ntasks_wav>640</ntasks_wav>
</ntasks>
<rootpe>
<rootpe_atm>0</rootpe_atm>
<rootpe_lnd>640</rootpe_lnd>
<rootpe_rof>640</rootpe_rof>
<rootpe_ice>0</rootpe_ice>
<rootpe_ocn>1024</rootpe_ocn>
<rootpe_cpl>0</rootpe_cpl>
<rootpe_wav>1280</rootpe_wav>
</rootpe>
<nthrds>
<nthrds_atm>1</nthrds_atm>
<nthrds_lnd>1</nthrds_lnd>
<nthrds_rof>1</nthrds_rof>
<nthrds_ice>1</nthrds_ice>
<nthrds_ocn>1</nthrds_ocn>
<nthrds_cpl>1</nthrds_cpl>
<nthrds_wav>1</nthrds_wav>
</nthrds>
</pes>
</mach>
<mach name="crusher">
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+SGLC_SWAV_SIAC_SESP_BGC.*" pesize="any">
<comment>crusher: --compset BGC* --res ne30pg2_r05_EC30to60E2r2 on 2 nodes pure-MPI</comment>
Expand Down Expand Up @@ -2202,62 +2264,6 @@
</pes>
</mach>
</grid>
<grid name="a%ne30np4_l%.+oi%oEC60to30.+w%wQU225EC60to30">
<mach name="anvil|chrysalis">
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+MOSART.+SGLC.+WW3" pesize="any">
<comment>none</comment>
<ntasks>
<ntasks_atm>1350</ntasks_atm>
<ntasks_lnd>72</ntasks_lnd>
<ntasks_rof>72</ntasks_rof>
<ntasks_ice>1296</ntasks_ice>
<ntasks_cpl>1296</ntasks_cpl>
<ntasks_ocn>216</ntasks_ocn>
<ntasks_wav>612</ntasks_wav>
</ntasks>
<rootpe>
<rootpe_lnd>1296</rootpe_lnd>
<rootpe_rof>1296</rootpe_rof>
<rootpe_ocn>1368</rootpe_ocn>
<rootpe_wav>1584</rootpe_wav>
</rootpe>
</pes>
</mach>
</grid>
<grid name="a%ne30np4.pg2_l%.+_oi%EC30to60E2r2.+w%wQU225EC30to60E2r2">
<mach name="anvil">
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+MOSART.+SGLC+WW3." pesize="M">
<comment> --compset WCYCL* --res ne30pg2_EC30to60E2r2_wQU225EC30to60E2r2 on 48 nodes pure-MPI, ~8.8 sypd </comment>
<ntasks>
<ntasks_atm>1350</ntasks_atm>
<ntasks_lnd>288</ntasks_lnd>
<ntasks_rof>288</ntasks_rof>
<ntasks_ice>1080</ntasks_ice>
<ntasks_ocn>360</ntasks_ocn>
<ntasks_cpl>1080</ntasks_cpl>
<ntasks_wav>612</ntasks_wav>
</ntasks>
<nthrds>
<nthrds_atm>1</nthrds_atm>
<nthrds_lnd>1</nthrds_lnd>
<nthrds_rof>1</nthrds_rof>
<nthrds_ice>1</nthrds_ice>
<nthrds_ocn>1</nthrds_ocn>
<nthrds_cpl>1</nthrds_cpl>
<nthrds_wav>1</nthrds_wav>
</nthrds>
<rootpe>
<rootpe_atm>0</rootpe_atm>
<rootpe_lnd>1080</rootpe_lnd>
<rootpe_rof>1080</rootpe_rof>
<rootpe_ice>0</rootpe_ice>
<rootpe_ocn>1368</rootpe_ocn>
<rootpe_cpl>0</rootpe_cpl>
<rootpe_wav>1728</rootpe_wav>
</rootpe>
</pes>
</mach>
</grid>
<grid name="a%ne30.+oi%oARRM60to10|a%ne30.+oi%ARRM10to60">
<mach name="onyx|warhawk|narwhal">
<pes compset=".*EAM.+ELM.+MPASSI.+MPASO.+MOSART.+SGLC" pesize="any">
Expand Down
34 changes: 34 additions & 0 deletions cime_config/config_grids.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2405,6 +2405,16 @@
<mask>EC30to60E2r2</mask>
</model_grid>

<model_grid alias="ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5">
<grid name="atm">ne30np4.pg2</grid>
<grid name="lnd">r05</grid>
<grid name="ocnice">IcoswISC30E3r5</grid>
<grid name="rof">r05</grid>
<grid name="glc">null</grid>
<grid name="wav">wQU225Icos30E3r5</grid>
<mask>IcoswISC30E3r5</mask>
</model_grid>

<model_grid alias="ne30pg2_WC14to60E2r3">
<grid name="atm">ne30np4.pg2</grid>
<grid name="lnd">ne30np4.pg2</grid>
Expand Down Expand Up @@ -3476,6 +3486,13 @@
<file grid="wav">$DIN_LOC_ROOT/share/domains/domain.ocn.wQU225EC30to60E2r2.220224.nc</file>
<desc>WW3 unstructured QU 225km global grid with EC30to60E2r2 coastlines</desc>
</domain>

<domain name="wQU225Icos30E3r5">
<nx>97988</nx>
<ny>1</ny>
<file grid="wav">$DIN_LOC_ROOT/share/domains/domain.ocn.wQU225Icos30E3r5.240910.nc</file>
<desc>WW3 unstructured QU 225km global grid with ICOS30 coastlines</desc>
</domain>

<!-- RRM grids -->

Expand Down Expand Up @@ -3636,7 +3653,10 @@
<required_gridmap grid1="atm_grid" grid2="rof_grid" compset="_MOSART">ATM2ROF_FMAPNAME</required_gridmap>
<required_gridmap grid1="atm_grid" grid2="rof_grid" compset="_MOSART">ATM2ROF_SMAPNAME</required_gridmap>
<required_gridmap grid1="atm_grid" grid2="wav_grid">ATM2WAV_SMAPNAME</required_gridmap>
<required_gridmap grid1="atm_grid" grid2="wav_grid">WAV2ATM_SMAPNAME</required_gridmap>
<required_gridmap grid1="ocn_grid" grid2="wav_grid">OCN2WAV_SMAPNAME</required_gridmap>
<required_gridmap grid1="ocn_grid" grid2="wav_grid">WAV2OCN_SMAPNAME</required_gridmap>
<required_gridmap grid1="ocn_grid" grid2="wav_grid">WAV2OCN_FMAPNAME</required_gridmap>
<required_gridmap grid1="ocn_grid" grid2="wav_grid">ICE2WAV_SMAPNAME</required_gridmap> <!-- ??? -->
<!-- <required_gridmap grid1="ocn_grid" grid2="rof_grid" not_compset="_POP">ROF2OCN_FMAPNAME</required_gridmap> ?? -->
<required_gridmap grid1="ocn_grid" grid2="rof_grid">ROF2OCN_LIQ_RMAPNAME</required_gridmap>
Expand Down Expand Up @@ -5040,6 +5060,12 @@

<gridmap atm_grid="ne30np4.pg2" wav_grid="wQU225EC30to60E2r2">
<map name="ATM2WAV_SMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_ne30pg2_TO_wQU225EC30to60E2r2_blin.20220222.nc</map>
<map name="WAV2ATM_SMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_wQU225EC30to60E2r2_TO_ne30pg2_blin.20220222.nc</map>
</gridmap>

<gridmap atm_grid="ne30np4.pg2" wav_grid="wQU225Icos30E3r5">
<map name="ATM2WAV_SMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_ne30pg2_to_wQU225Icos30E3r5_esmfbilin.20240910.nc</map>
<map name="WAV2ATM_SMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_wQU225Icos30E3r5_to_ne30pg2_esmfbilin.20240910.nc</map>
</gridmap>

<gridmap atm_grid="TL319" wav_grid="wQU225EC30to60E2r2">
Expand All @@ -5054,10 +5080,18 @@

<gridmap ocn_grid="EC30to60E2r2" wav_grid="wQU225EC30to60E2r2">
<map name="WAV2OCN_SMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_wQU225EC30to60E2r2_TO_EC30to60E2r2_blin.20220222.nc</map>
<map name="WAV2OCN_FMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_wQU225EC30to60E2r2_TO_EC30to60E2r2_aave.20220222.nc</map>
<map name="OCN2WAV_SMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_EC30to60E2r2_TO_wQU225EC30to60E2r2_blin.20220222.nc</map>
<map name="ICE2WAV_SMAPNAME">cpl/gridmaps/wQU225EC30to60E2r2/map_EC30to60E2r2_TO_wQU225EC30to60E2r2_blin.20220222.nc</map>
</gridmap>

<gridmap ocn_grid="IcoswISC30E3r5" wav_grid="wQU225Icos30E3r5">
<map name="WAV2OCN_SMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_wQU225Icos30E3r5_to_IcoswISC30E3r5_esmfbilin.20240910.nc</map>
<map name="WAV2OCN_FMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_wQU225Icos30E3r5_to_IcoswISC30E3r5_esmfaave.20240910.nc</map>
<map name="OCN2WAV_SMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_IcoswISC30E3r5_to_wQU225Icos30E3r5_esmfbilin.20240910.nc</map>
<map name="ICE2WAV_SMAPNAME">cpl/gridmaps/wQU225Icos30E3r5/map_IcoswISC30E3r5_to_wQU225Icos30E3r5_esmfbilin.20240910.nc</map>
</gridmap>

<gridmap atm_grid="CFSv2" wav_grid="wQU225EC60to30">
<map name="ATM2WAV_SMAPNAME">cpl/gridmaps/wQU225EC60to30/map_CFSv2_TO_wQU225EC60to30_blin.20210412.nc</map>
</gridmap>
Expand Down
7 changes: 4 additions & 3 deletions cime_config/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -822,10 +822,11 @@
"e3sm_wav_developer" : {
"time" : "0:45:00",
"tests" : (
"ERS.TL319_EC30to60E2r2_wQU225EC30to60E2r2.GMPAS-JRA1p5-WW3.ww3-jra_1958",
"PEM.TL319_EC30to60E2r2_wQU225EC30to60E2r2.GMPAS-JRA1p5-WW3.ww3-jra_1958",
"PET.TL319_EC30to60E2r2_wQU225EC30to60E2r2.GMPAS-JRA1p5-WW3.ww3-jra_1958",
"SMS_D_Ln3.TL319_EC30to60E2r2_wQU225EC30to60E2r2.GMPAS-JRA1p5-WW3.ww3-jra_1958",
"ERS.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3",
"PEM.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3",
"PET.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3",
"SMS_D_Ln3.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3",
)
},

Expand Down
4 changes: 2 additions & 2 deletions components/elm/src/biogeochem/AllocationMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,7 @@ subroutine Allocation1_PlantNPDemand (bounds, num_soilc, filter_soilc, num_soilp

if (stem_leaf(ivt(p)) < 0._r8) then
if (stem_leaf(ivt(p)) == -1._r8) then
f3 = (2.7/(1.0+exp(-0.004*(annsum_npp(p) - 300.0)))) - 0.4
f3 = max((2.7/(1.0+exp(-0.004*(annsum_npp(p) - 300.0)))) - 0.4_r8, 0.2_r8)
else
f3 = max((-1.0_r8*stem_leaf(ivt(p))*2.7_r8)/(1.0_r8+exp(-0.004_r8*(annsum_npp(p) - &
300.0_r8))) - 0.4_r8, 0.2_r8)
Expand Down Expand Up @@ -2118,7 +2118,7 @@ subroutine Allocation3_PlantCNPAlloc (bounds , &

if (stem_leaf(ivt(p)) < 0._r8) then
if (stem_leaf(ivt(p)) == -1._r8) then
f3 = (2.7/(1.0+exp(-0.004*(annsum_npp(p) - 300.0)))) - 0.4
f3 = max((2.7/(1.0+exp(-0.004*(annsum_npp(p) - 300.0)))) - 0.4_r8, 0.2_r8)
else
f3 = max((-1.0_r8*stem_leaf(ivt(p))*2.7_r8)/(1.0_r8+exp(-0.004_r8*(annsum_npp(p) - &
300.0_r8))) - 0.4_r8, 0.2_r8)
Expand Down
12 changes: 6 additions & 6 deletions components/mpas-ocean/bld/build-namelist
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ OPTIONS
(Needed to run build-namelist from SourceMods dir)
-inst_string inst_string variable
-ocn_bgc ocean BGC configuration
-ocn_wave ocean wave coupling flag
-ocn_co2_type how atm co2 is set within MPASO
-atm_co2_const_val value of atm co2 if ocn_co2_type = constant
-ice_bgc check for coupling with sea ice BGC
Expand Down Expand Up @@ -118,7 +117,6 @@ my %opts = ( help => 0,
decomp_prefix => undef,
date_stamp => undef,
ocn_bgc => undef,
ocn_wave => undef,
ocn_co2_type => undef,
atm_co2_const_val => undef,
ice_bgc => undef,
Expand All @@ -145,7 +143,6 @@ GetOptions(
"decomp_prefix=s" => \$opts{'decomp_prefix'},
"date_stamp=s" => \$opts{'date_stamp'},
"ocn_bgc=s" => \$opts{'ocn_bgc'},
"ocn_wave=s" => \$opts{'ocn_wave'},
"ocn_co2_type=s" => \$opts{'ocn_co2_type'},
"atm_co2_const_val=s" => \$opts{'atm_co2_const_val'},
"ice_bgc=s" => \$opts{'ice_bgc'},
Expand Down Expand Up @@ -189,7 +186,6 @@ my $OCN_SGR = $opts{'ocn_sgr'};
my $decomp_prefix = $opts{'decomp_prefix'};
my $date_stamp = $opts{'date_stamp'};
my $ocn_bgc = $opts{'ocn_bgc'};
my $ocn_wave = $opts{'ocn_wave'};
my $ocn_co2_type = $opts{'ocn_co2_type'};
my $atm_co2_const_val = $opts{'atm_co2_const_val'};
my $ice_bgc = $opts{'ice_bgc'};
Expand Down Expand Up @@ -444,6 +440,8 @@ my $RUN_STARTDATE = "$xmlvars{'RUN_STARTDATE'}";
my $START_TOD = "$xmlvars{'START_TOD'}";
my $RUN_REFDATE = "$xmlvars{'RUN_REFDATE'}";
my $CONTINUE_RUN = "$xmlvars{'CONTINUE_RUN'}";
my $COMP_OCN = "$xmlvars{'COMP_OCN'}";
my $COMP_WAV = "$xmlvars{'COMP_WAV'}";

my $output_r = "./${CASE}.mpaso.r";
my $output_h = "./${CASE}.mpaso.h";
Expand Down Expand Up @@ -667,7 +665,7 @@ add_default($nl, 'configure_cvmix_kpp_minimum_OBL_under_sea_ice');
add_default($nl, 'config_cvmix_kpp_stop_OBL_search');
add_default($nl, 'config_cvmix_kpp_use_enhanced_diff');
add_default($nl, 'config_cvmix_kpp_nonlocal_with_implicit_mix');
if ($ocn_wave eq 'true' ) {
if ($COMP_WAV eq 'ww3' and $COMP_OCN eq 'mpaso' ) {
add_default($nl, 'config_cvmix_kpp_use_theory_wave', 'val'=>'.false.');
add_default($nl, 'config_cvmix_kpp_use_active_wave', 'val'=>'.true.');
add_default($nl, 'config_cvmix_kpp_langmuir_mixing_opt', 'val'=>'LWF16');
Expand All @@ -682,10 +680,12 @@ if ($ocn_wave eq 'true' ) {
# Namelist group: wave_coupling #
#################################

if ($ocn_wave eq 'true' ) {
if ($COMP_WAV eq 'ww3' and $COMP_OCN eq 'mpaso' ) {
add_default($nl, 'config_use_active_wave', 'val'=>'.true.');
add_default($nl, 'config_momentum_use_active_wave', 'val'=>'.true.');
} else {
add_default($nl, 'config_use_active_wave', 'val'=>'.false.');
add_default($nl, 'config_momentum_use_active_wave', 'val'=>'.false.');
}
add_default($nl, 'config_n_stokes_drift_wavenumber_partitions');

Expand Down
1 change: 1 addition & 0 deletions components/mpas-ocean/bld/build-namelist-section
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@ add_default($nl, 'config_cvmix_kpp_use_active_wave');
#################################

add_default($nl, 'config_use_active_wave');
add_default($nl, 'config_momentum_use_active_wave');
add_default($nl, 'config_n_stokes_drift_wavenumber_partitions');

########################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,7 @@

<!-- wave_coupling -->
<config_use_active_wave>.false.</config_use_active_wave>
<config_momentum_use_active_wave>.false.</config_momentum_use_active_wave>
<config_n_stokes_drift_wavenumber_partitions>6</config_n_stokes_drift_wavenumber_partitions>

<!-- gotm -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1094,6 +1094,14 @@ Valid values: .true. or .false.
Default: Defined in namelist_defaults.xml
</entry>

<entry id="config_momentum_use_active_wave" type="logical"
category="wave_coupling" group="wave_coupling">
Flag for correcting momentum in ocean due waves. Requires config_use_active_wave = .true.

Valid values: .true. or .false.
Default: Defined in namelist_defaults.xml
</entry>

<entry id="config_n_stokes_drift_wavenumber_partitions" type="integer"
category="wave_coupling" group="wave_coupling">
Number of wavenumber partitions to be used in reconstructing wave-induced Stokes drift profile
Expand Down
Loading