@@ -35,6 +35,7 @@ def buildnml(case, caseroot, compname):
35
35
ocn_forcing = case .get_value ("MPASO_FORCING" )
36
36
ocn_iceberg = case .get_value ("MPASO_ICEBERG" )
37
37
ocn_ismf = case .get_value ("MPASO_ISMF" )
38
+ ocn_sgr = case .get_value ("MPASO_SGR" )
38
39
ocn_bgc = case .get_value ("MPASO_BGC" )
39
40
ocn_wave = case .get_value ("MPASO_WAVE" )
40
41
ocn_tidal_mixing = case .get_value ("MPASO_TIDAL_MIXING" )
@@ -76,6 +77,7 @@ def buildnml(case, caseroot, compname):
76
77
analysis_mask_file = ''
77
78
eco_forcing_file = ''
78
79
u_tidal_rms_file = ''
80
+ data_sgr_file = ''
79
81
80
82
if ocn_grid == 'oEC60to30v3' :
81
83
decomp_date = '230424'
@@ -140,6 +142,8 @@ def buildnml(case, caseroot, compname):
140
142
data_ismf_file = 'prescribed_ismf_paolo2023.oQU240wLI.20240404.nc'
141
143
if ocn_tidal_mixing == 'true' :
142
144
u_tidal_rms_file = 'velocityTidalRMS_CATS2008.oQU240wLI.20240221.nc'
145
+ if ocn_sgr == 'data' :
146
+ data_sgr_file = 'DSGR.massFlux.MALI.out2055.oQU240wLI.20240328.nc'
143
147
144
148
elif ocn_grid == 'oQU120' :
145
149
decomp_date = '230424'
@@ -277,6 +281,8 @@ def buildnml(case, caseroot, compname):
277
281
data_ismf_file = 'prescribed_ismf_adusumilli2020.SOwISC12to60E2r4.230516.nc'
278
282
if ocn_tidal_mixing == 'true' :
279
283
u_tidal_rms_file = 'velocityTidalRMS_CATS2008.SOwISC12to60E2r4.20210114.nc'
284
+ if ocn_sgr == 'data' :
285
+ data_sgr_file = 'DSGR.massFlux.MALI.out2055.SOwISC12to60E2r4.20240328.nc'
280
286
281
287
elif ocn_grid == 'FRISwISC08to60E3r1' :
282
288
decomp_date = '20230913' # changed to date of partiotions in ../files_for_e3sm/assembled_files/inputdata/ocn/mpas-o/FRISwISC08to60E3r1/partitions
@@ -352,6 +358,8 @@ def buildnml(case, caseroot, compname):
352
358
data_ismf_file = 'prescribed_ismf_adusumilli2020.ECwISC30to60E2r1.230429.nc'
353
359
if ocn_tidal_mixing == 'true' :
354
360
u_tidal_rms_file = 'velocityTidalRMS_CATS2008.ECwISC30to60E2r1.20240221.nc'
361
+ if ocn_sgr == 'data' :
362
+ data_sgr_file = 'DSGR.massFlux.MALI.out2055.ECwISC30to60E2r1.20240328.nc'
355
363
356
364
elif ocn_grid == 'IcoswISC30E3r5' :
357
365
decomp_date = '20231120'
@@ -371,6 +379,8 @@ def buildnml(case, caseroot, compname):
371
379
data_ismf_file = 'prescribed_ismf_paolo2023.IcoswISC30E3r5.20240227.nc'
372
380
if ocn_tidal_mixing == 'true' :
373
381
u_tidal_rms_file = 'velocityTidalRMS_CATS2008.IcoswISC30E3r5.20231120.nc'
382
+ if ocn_sgr == 'data' :
383
+ data_sgr_file = 'DSGR.massFlux.MALI.out2055.IcoswISC30E3r5.20240328.nc'
374
384
375
385
elif ocn_grid == 'IcosXISC30E3r7' :
376
386
decomp_date = '20240314'
@@ -396,7 +406,6 @@ def buildnml(case, caseroot, compname):
396
406
if ocn_ismf == 'data' :
397
407
data_ismf_file = 'prescribed_ismf_paolo2023.RRSwISC6to18E3r5.20240327.nc'
398
408
399
-
400
409
#--------------------------------------------------------------------
401
410
# Set OCN_FORCING = datm_forced_restoring if restoring file is available
402
411
#--------------------------------------------------------------------
@@ -436,6 +445,9 @@ def buildnml(case, caseroot, compname):
436
445
if u_tidal_rms_file != '' :
437
446
input_list .write ("u_tidal_rms = {}/ocn/mpas-o/{}/{}\n " .format (din_loc_root , ocn_mask , u_tidal_rms_file ))
438
447
448
+ if data_sgr_file != '' :
449
+ input_list .write ("subglacial_runoff = {}/ocn/mpas-o/{}/{}\n " .format (din_loc_root , ocn_mask , data_sgr_file ))
450
+
439
451
#--------------------------------------------------------------------
440
452
# Invoke mpas build-namelist - output will go in $CASEBUILD/mpasoconf
441
453
#--------------------------------------------------------------------
@@ -495,6 +507,7 @@ def buildnml(case, caseroot, compname):
495
507
sysmod += " -ocn_forcing '{}'" .format (ocn_forcing )
496
508
sysmod += " -ocn_iceberg '{}'" .format (ocn_iceberg )
497
509
sysmod += " -ocn_ismf '{}'" .format (ocn_ismf )
510
+ sysmod += " -ocn_sgr '{}'" .format (ocn_sgr )
498
511
sysmod += " -ocn_bgc '{}'" .format (ocn_bgc )
499
512
sysmod += " -ocn_wave '{}'" .format (ocn_wave )
500
513
sysmod += " -ocn_tidal_mixing '{}'" .format (ocn_tidal_mixing )
@@ -702,6 +715,19 @@ def buildnml(case, caseroot, compname):
702
715
lines .append ('</stream>' )
703
716
lines .append ('' )
704
717
718
+ if data_sgr_file != '' :
719
+ lines .append ('<stream name="prescribed_subglacial_runoff"' )
720
+ lines .append (' type="input"' )
721
+ lines .append (' io_type="{}"' .format (ocn_pio_typename ))
722
+ lines .append (
723
+ ' filename_template="{}/ocn/mpas-o/{}/{}"' .format (din_loc_root , ocn_mask , data_sgr_file ))
724
+ lines .append (' input_interval="initial_only" ' )
725
+ lines .append (' packages="landIceFluxesPKG">' )
726
+ lines .append ('' )
727
+ lines .append (' <var name="subglacialRunoffFlux"/>' )
728
+ lines .append ('</stream>' )
729
+ lines .append ('' )
730
+
705
731
if analysis_mask_file != '' :
706
732
lines .append ('<stream name="transectMasksInput"' )
707
733
lines .append (' type="input"' )
@@ -1169,12 +1195,14 @@ def buildnml(case, caseroot, compname):
1169
1195
lines .append ('<var name="accumulatedEvapTemperatureFlux"/>' )
1170
1196
lines .append ('<var name="accumulatedSeaIceTemperatureFlux"/>' )
1171
1197
lines .append ('<var name="accumulatedRiverRunoffTemperatureFlux"/>' )
1198
+ lines .append ('<var name="accumulatedSubglacialRunoffTemperatureFlux"/>' )
1172
1199
lines .append ('<var name="accumulatedIcebergTemperatureFlux"/>' )
1173
1200
lines .append ('<var name="accumulatedRainFlux"/>' )
1174
1201
lines .append ('<var name="accumulatedSnowFlux"/>' )
1175
1202
lines .append ('<var name="accumulatedEvaporationFlux"/>' )
1176
1203
lines .append ('<var name="accumulatedSeaIceFlux"/>' )
1177
1204
lines .append ('<var name="accumulatedRiverRunoffFlux"/>' )
1205
+ lines .append ('<var name="accumulatedSubglacialRunoffFlux"/>' )
1178
1206
lines .append ('<var name="accumulatedIceRunoffFlux"/>' )
1179
1207
lines .append ('<var name="accumulatedRemovedRiverRunoffFlux"/>' )
1180
1208
lines .append ('<var name="accumulatedRemovedIceRunoffFlux"/>' )
@@ -1183,6 +1211,7 @@ def buildnml(case, caseroot, compname):
1183
1211
lines .append ('<var name="accumulatedLandIceFlux"/>' )
1184
1212
lines .append ('<var name="accumulatedLandIceFrazilFlux"/>' )
1185
1213
lines .append ('<var name="accumulatedSeaIceSalinityFlux"/>' )
1214
+ lines .append ('<var name="accumulatedSubglacialRunoffSalinityFlux"/>' )
1186
1215
lines .append ('<var name="initialCarbon"/>' )
1187
1216
lines .append ('<var name="finalCarbon"/>' )
1188
1217
lines .append ('<var name="carbonChange"/>' )
@@ -1331,6 +1360,7 @@ def buildnml(case, caseroot, compname):
1331
1360
lines .append (' <var name="seaIceSalinityFlux"/>' )
1332
1361
lines .append (' <var name="seaIceFreshWaterFlux"/>' )
1333
1362
lines .append (' <var name="riverRunoffFlux"/>' )
1363
+ lines .append (' <var name="subglacialRunoffFlux"/>' )
1334
1364
lines .append (' <var name="iceRunoffFlux"/>' )
1335
1365
lines .append (' <var name="rainFlux"/>' )
1336
1366
lines .append (' <var name="snowFlux"/>' )
@@ -1533,6 +1563,7 @@ def buildnml(case, caseroot, compname):
1533
1563
lines .append (' <var name="icebergFreshWaterFlux"/>' )
1534
1564
1535
1565
lines .append (' <var name="riverRunoffFlux"/>' )
1566
+ lines .append (' <var name="subglacialRunoffFlux"/>' )
1536
1567
lines .append (' <var name="iceRunoffFlux"/>' )
1537
1568
lines .append (' <var name="rainFlux"/>' )
1538
1569
lines .append (' <var name="snowFlux"/>' )
@@ -1598,6 +1629,7 @@ def buildnml(case, caseroot, compname):
1598
1629
lines .append (' <var name="icebergFreshWaterFlux"/>' )
1599
1630
1600
1631
lines .append (' <var name="riverRunoffFlux"/>' )
1632
+ lines .append (' <var name="subglacialRunoffFlux"/>' )
1601
1633
lines .append (' <var name="iceRunoffFlux"/>' )
1602
1634
lines .append (' <var name="rainFlux"/>' )
1603
1635
lines .append (' <var name="snowFlux"/>' )
@@ -1812,6 +1844,7 @@ def buildnml(case, caseroot, compname):
1812
1844
lines .append (' <var name="seaIceSalinityFlux"/>' )
1813
1845
lines .append (' <var name="seaIceFreshWaterFlux"/>' )
1814
1846
lines .append (' <var name="riverRunoffFlux"/>' )
1847
+ lines .append (' <var name="subglacialRunoffFlux"/>' )
1815
1848
lines .append (' <var name="iceRunoffFlux"/>' )
1816
1849
lines .append (' <var name="rainFlux"/>' )
1817
1850
lines .append (' <var name="snowFlux"/>' )
0 commit comments