@@ -1545,6 +1545,68 @@ elsif ($carma eq 'tholin') {
1545
1545
add_default($nl , ' carma_emis_total' , ' val' => ' 1e5' );
1546
1546
add_default($nl , ' carma_emis_file' );
1547
1547
}
1548
+ elsif ($carma =~ / trop_strat/ ) {
1549
+ add_default($nl , ' carma_do_fixedinit' ,' val' => ' .false.' );
1550
+ add_default($nl , ' carma_do_partialinit' ,' val' => ' .false.' );
1551
+ add_default($nl , ' carma_do_drydep' , ' val' => ' .true.' );
1552
+ add_default($nl , ' carma_do_optics' , ' val' => ' .false.' );
1553
+ add_default($nl , ' carma_do_vtran' , ' val' => ' .true.' );
1554
+ add_default($nl , ' carma_do_wetdep' , ' val' => ' .false.' );
1555
+ add_default($nl , ' carma_soilerosion_file' );
1556
+ add_default($nl , ' carma_fields' , ' val' => ' Sl_soilw' );
1557
+ add_default($nl , ' carma_do_vdiff' , ' val' => ' .true.' );
1558
+ add_default($nl , ' carma_do_WeibullK' , ' val' => ' .false.' );
1559
+ add_default($nl , ' carma_seasalt_emis' ,' val' => ' Gong' );
1560
+ add_default($nl , ' carma_do_coag' , ' val' => ' .true.' );
1561
+ add_default($nl , ' carma_do_grow' , ' val' => ' .true.' );
1562
+ add_default($nl , ' carma_do_substep' , ' val' => ' .true.' );
1563
+ add_default($nl , ' carma_do_thermo' , ' val' => ' .false.' );
1564
+ add_default($nl , ' carma_seasalt_emis' ,' val' => ' Gong' );
1565
+ add_default($nl , ' carma_maxretries' , ' val' => ' 20' );
1566
+ add_default($nl , ' carma_maxsubsteps' , ' val' => ' 2' );
1567
+ add_default($nl , ' carma_dt_threshold' ,' val' => ' 2.0' );
1568
+ add_default($nl , ' carma_hetchem_feedback' ,' val' => ' .false.' );
1569
+ add_default($nl , ' bin_defs' );
1570
+ add_default($nl , ' rad_climate' );
1571
+ add_default($nl , ' carma_do_emission' , ' val' => ' .true.' );
1572
+ add_default($nl , ' water_refindex_file' );
1573
+ add_default($nl , ' carma_do_cloudborne' , ' val' => ' .true.' );
1574
+
1575
+ # emissions
1576
+ add_default($nl , ' carma_BCOCemissions' ,' val' => ' Specified' );
1577
+ my $carma_BCOCemis = $nl -> get_value(' carma_BCOCemissions' );
1578
+ $carma_BCOCemis =~ s / ['"]// g ; # strip quotes "'
1579
+ if ($carma_BCOCemis eq ' Specified' ) {
1580
+ my %verhash ; # = ('ver'=>'cam6');
1581
+ if ( $sim_year == ' 2000' ) {
1582
+ %verhash = (' ver' => ' 2000cam6' );
1583
+ add_default($nl , ' emissions_type' , ' val' => ' CYCLICAL' );
1584
+ add_default($nl , ' emissions_cycle_yr' , ' val' => ' 2000' );
1585
+ } else {
1586
+ %verhash = (' ver' => ' cam6' );
1587
+ add_default($nl , ' emissions_type' , ' val' => ' INTERP_MISSING_MONTHS' );
1588
+ }
1589
+ my %species = (' bc_a4_an_srf_file' => ' BC' ,
1590
+ ' bc_a4_bb_srf_file' => ' BC' ,
1591
+ ' pom_a4_an_srf_file' => ' OC' ,
1592
+ ' pom_a4_bb_srf_file' => ' OC' );
1593
+ my $first = 1; my $pre = " " ; my $val = " " ;
1594
+ foreach my $id (sort keys %species ) {
1595
+ my $rel_filepath = get_default_value($id , \%verhash );
1596
+ my $abs_filepath = set_abs_filepath($rel_filepath , $inputdata_rootdir );
1597
+ $val .= $pre . quote_string(" $species {$id } -> " . $abs_filepath );
1598
+ if ($first ) { $pre = " ," ; $first = 0; }
1599
+ }
1600
+ add_default($nl , ' emissions_specifier' , ' val' => $val );
1601
+ } else {
1602
+ add_default($nl , ' BC_GAINS_filename' );
1603
+ add_default($nl , ' OC_GAINS_filename' );
1604
+ add_default($nl , ' BC_ship_filename' );
1605
+ add_default($nl , ' OC_ship_filename' );
1606
+ add_default($nl , ' BC_GFEDv3_filename' );
1607
+ add_default($nl , ' OC_GFEDv3_filename' );
1608
+ }
1609
+ }
1548
1610
1549
1611
# Stratospheric sulfur aerosols
1550
1612
@@ -1591,7 +1653,8 @@ if (defined $nl->get_value('prescribed_strataero_3modes')) {
1591
1653
1592
1654
# determine if prescribed stratospheric aerosol data is needed
1593
1655
if ( ($het_chem ) || ($nl -> get_value(' prescribed_strataero_feedback' ) =~ / $TRUE /io ) ){
1594
- if ( !($nl -> get_value(' modal_strat_sulfate' ) =~ / $TRUE /io ) ) { # if no prognostic stratospheric aerosols
1656
+ if ( !($carma =~ / trop_strat/ ) &&
1657
+ !($nl -> get_value(' modal_strat_sulfate' ) =~ / $TRUE /io ) ) { # if no prognostic stratospheric aerosols
1595
1658
1596
1659
unless (defined $nl -> get_value(' prescribed_strataero_type' )) {
1597
1660
add_default($nl , ' prescribed_strataero_type' ,' val' => ' CYCLICAL' );
@@ -2222,10 +2285,10 @@ if ($chem eq 'trop_mam3') {
2222
2285
}
2223
2286
2224
2287
# CMIP6 emissions
2225
- if (( $chem =~ / _mam4 / or $chem =~ / _mam5 / ) and ( $ phys =~ / cam6/ or $phys =~ / cam7/ ) ) {
2288
+ if ($ phys =~ / cam6/ or $phys =~ / cam7/ ) {
2226
2289
2227
2290
# OASISS (ocean) DMS emissions
2228
- if (!$aqua_mode and !$scam ) {
2291
+ if (!$aqua_mode and !$scam and chem_has_species( $cfg , ' DMS ' ) ) {
2229
2292
my $rel_filepath = get_default_value(' dms_ocn_emis_file' );
2230
2293
my $abs_filepath = set_abs_filepath($rel_filepath , $inputdata_rootdir );
2231
2294
my $val = quote_string(" DMS -> " . $abs_filepath );
@@ -2243,37 +2306,40 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2243
2306
}
2244
2307
}
2245
2308
2246
- my %species ;
2309
+ my %species = (' dms_bb_srf_file' => ' DMS' ,
2310
+ ' so2_ag_sh_file' => ' SO2' ,
2311
+ ' so2_an_srf_file' => ' SO2' ,
2312
+ ' so2_bb_srf_file' => ' SO2' );
2247
2313
2248
- # Surface emission datasets:
2249
- %species = (' dms_bb_srf_file' => ' DMS' ,
2250
- ' so2_ag_sh_file' => ' SO2' ,
2251
- ' so2_an_srf_file' => ' SO2' ,
2252
- ' so2_bb_srf_file' => ' SO2' ,
2253
- ' so4_a1_an_srf_file' => ' so4_a1' ,
2254
- ' so4_a1_bb_srf_file' => ' so4_a1' ,
2255
- ' so4_a2_an_srf_file' => ' so4_a2' ,
2256
- ' num_a1_sh_srf_file' => ' num_a1' ,
2257
- ' num_a1_bb_srf_file' => ' num_a1' ,
2258
- ' num_a2_an_srf_file' => ' num_a2' ,
2259
- ' bc_a4_an_srf_file' => ' bc_a4' ,
2260
- ' bc_a4_bb_srf_file' => ' bc_a4' ,
2261
- ' num_a4_bc_srf_file' => ' num_a4' ,
2262
- ' num_a4_oc_srf_file' => ' num_a4' ,
2263
- ' num_a4_bb_srf_file' => ' num_a4' ,
2264
- ' num_pom_bb_srf_file' => ' num_a4' );
2265
- if ((not defined $nl -> get_value(' csw_specifier' )) or (not $nl -> get_value(' csw_specifier' ) ~~ / DMS/ )) {
2266
- %species = (%species ,
2267
- ' dms_ot_srf_file' => ' DMS' );
2268
- }
2269
- if ($chem =~ / _vbsext/ ) {
2270
- %species = (%species ,
2271
- ' pom_a4_an_srf_file' => ' pomff1_a4' ,
2272
- ' pom_a4_bb_srf_file' => ' pombb1_a4' );
2273
- } else {
2314
+ if ($chem =~ / _mam4/ or $chem =~ / _mam5/ ) {
2315
+
2316
+ # Surface emission datasets:
2274
2317
%species = (%species ,
2275
- ' pom_a4_an_srf_file' => ' pom_a4' ,
2276
- ' pom_a4_bb_srf_file' => ' pom_a4' );
2318
+ ' so4_a1_an_srf_file' => ' so4_a1' ,
2319
+ ' so4_a1_bb_srf_file' => ' so4_a1' ,
2320
+ ' so4_a2_an_srf_file' => ' so4_a2' ,
2321
+ ' num_a1_sh_srf_file' => ' num_a1' ,
2322
+ ' num_a1_bb_srf_file' => ' num_a1' ,
2323
+ ' num_a2_an_srf_file' => ' num_a2' ,
2324
+ ' bc_a4_an_srf_file' => ' bc_a4' ,
2325
+ ' bc_a4_bb_srf_file' => ' bc_a4' ,
2326
+ ' num_a4_bc_srf_file' => ' num_a4' ,
2327
+ ' num_a4_oc_srf_file' => ' num_a4' ,
2328
+ ' num_a4_bb_srf_file' => ' num_a4' ,
2329
+ ' num_pom_bb_srf_file' => ' num_a4' );
2330
+ if ((not defined $nl -> get_value(' csw_specifier' )) or (not $nl -> get_value(' csw_specifier' ) ~~ / DMS/ )) {
2331
+ %species = (%species ,
2332
+ ' dms_ot_srf_file' => ' DMS' );
2333
+ }
2334
+ if ($chem =~ / _vbsext/ ) {
2335
+ %species = (%species ,
2336
+ ' pom_a4_an_srf_file' => ' pomff1_a4' ,
2337
+ ' pom_a4_bb_srf_file' => ' pombb1_a4' );
2338
+ } else {
2339
+ %species = (%species ,
2340
+ ' pom_a4_an_srf_file' => ' pom_a4' ,
2341
+ ' pom_a4_bb_srf_file' => ' pom_a4' );
2342
+ }
2277
2343
}
2278
2344
2279
2345
# for old simple SOA schemes (without SOAE)
@@ -2430,7 +2496,7 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2430
2496
}
2431
2497
}
2432
2498
}
2433
- if ($chem !~ / geoschem/ ) {
2499
+ if (( $chem !~ / geoschem/ ) and ( $chem ne ' none ' ) ) {
2434
2500
add_default($nl , ' srf_emis_specifier' , ' val' => $val );
2435
2501
unless (defined $nl -> get_value(' srf_emis_type' )) {
2436
2502
add_default($nl , ' srf_emis_type' , ' val' => ' CYCLICAL' );
@@ -2439,20 +2505,25 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2439
2505
}
2440
2506
2441
2507
# Vertical emission datasets:
2442
- %species = (' so2_cv_ext_file' => ' SO2' ,
2443
- ' so4_a1_an_ext_file' => ' so4_a1' ,
2444
- ' so4_a1_cv_ext_file' => ' so4_a1' ,
2445
- ' so4_a2_cv_ext_file' => ' so4_a2' ,
2446
- ' num_a1_an_ext_file' => ' num_a1' ,
2447
- ' num_a1_cv_ext_file' => ' num_a1' ,
2448
- ' num_a2_cv_ext_file' => ' num_a2' ,
2508
+ %species = (' so2_cv_ext_file' => ' SO2' );
2509
+ if ($chem =~ / _mam4/ or $chem =~ / _mam5/ ) {
2510
+ %species = (%species ,
2511
+ ' so4_a1_an_ext_file' => ' so4_a1' ,
2512
+ ' so4_a1_cv_ext_file' => ' so4_a1' ,
2513
+ ' so4_a2_cv_ext_file' => ' so4_a2' ,
2514
+ ' num_a1_an_ext_file' => ' num_a1' ,
2515
+ ' num_a1_cv_ext_file' => ' num_a1' ,
2516
+ ' num_a2_cv_ext_file' => ' num_a2' ,
2449
2517
);
2450
-
2518
+ }
2451
2519
# air craft emissions
2452
2520
if ($chem !~ / trop_mam/ and $chem !~ / ghg_mam/ and $chem !~ / waccm_sc/ ) {
2453
- %species = (%species ,
2521
+ if ($chem !~ / _noaer/ ) {
2522
+ %species = (%species ,
2454
2523
' bc_a4_ar_ext_file' => ' bc_a4' ,
2455
- ' num_a4_ar_ext_file' => ' num_a4' ,
2524
+ ' num_a4_ar_ext_file' => ' num_a4' );
2525
+ }
2526
+ %species = (%species ,
2456
2527
' no2_ar_ext_file' => ' NO2' ,
2457
2528
' so2_ar_ext_file' => ' SO2' );
2458
2529
} elsif ($chem =~ / ghg_mam/ ) {
@@ -2463,8 +2534,8 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2463
2534
}
2464
2535
2465
2536
# for transient cases include volcanic emissions
2466
- if ( ($nl -> get_value(' modal_strat_sulfate' ) =~ / $TRUE /io ) and
2467
- (defined $nl -> get_value(' ext_frc_type' )) ) {
2537
+ if ( (( $nl -> get_value(' modal_strat_sulfate' ) =~ / $TRUE /io ) or ( $carma eq ' trop_strat ' ))
2538
+ and (defined $nl -> get_value(' ext_frc_type' )) ) {
2468
2539
if ( $nl -> get_value(' ext_frc_type' ) !~ / CYCLICAL/ ) {
2469
2540
my $hgrid = $cfg -> get(' hgrid' );
2470
2541
if ($hgrid =~ / 1.9x2.5/ ) {
@@ -2501,7 +2572,7 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2501
2572
$first = 0;
2502
2573
}
2503
2574
}
2504
- if ($chem !~ / geoschem/ ) {
2575
+ if (( $chem !~ / geoschem/ ) and ( $chem ne ' none ' ) ) {
2505
2576
add_default($nl , ' ext_frc_specifier' , ' val' => $val );
2506
2577
unless (defined $nl -> get_value(' ext_frc_type' )) {
2507
2578
add_default($nl , ' ext_frc_type' , ' val' => " 'CYCLICAL'" );
@@ -2526,7 +2597,7 @@ if (($chem =~ /_mam4/ or $chem =~ /_mam5/) and ($phys =~ /cam6/ or $phys =~ /cam
2526
2597
add_default($nl , ' megan_factors_file' );
2527
2598
add_default($nl , ' megan_mapped_emisfctrs' , ' val' => ' .false.' );
2528
2599
}
2529
- if ($chem =~ / trop_strat_mam4_vbsext/ or $chem =~ / waccm_tsmlt/ ) {
2600
+ if ($chem =~ / trop_strat_mam4_vbsext/ or $chem =~ / trop_strat_noaero / or $chem =~ / waccm_tsmlt/ ) {
2530
2601
my $val = " 'ISOP = isoprene',"
2531
2602
. " 'MTERP = pinene_a + carene_3 + thujene_a + 2met_styrene + cymene_p + cymene_o + terpinolene + bornene +'"
2532
2603
. " ' fenchene_a + ocimene_al + pinene_b + sabinene + camphene + limonene + phellandrene_a + terpinene_g +'"
@@ -3310,7 +3381,7 @@ add_default($nl, 'microp_aero_wsubi_min');
3310
3381
3311
3382
# Ice nucleation options
3312
3383
if (!$simple_phys ) {
3313
- if ($chem =~ / _mam/ ) {
3384
+ if ($chem =~ / _mam/ or $carma =~ / trop_strat / ) {
3314
3385
add_default($nl , ' use_hetfrz_classnuc' );
3315
3386
} else {
3316
3387
add_default($nl , ' use_hetfrz_classnuc' , ' val' => ' .false.' );
@@ -3577,6 +3648,10 @@ if ($chem =~ /_mam/) {
3577
3648
add_default($nl , ' sol_factb_interstitial' );
3578
3649
add_default($nl , ' sol_factic_interstitial' );
3579
3650
}
3651
+ if ($carma =~ / trop_strat/ ) {
3652
+ add_default($nl , ' sol_facti_cloud_borne' );
3653
+ add_default($nl , ' sol_factic_interstitial' );
3654
+ }
3580
3655
3581
3656
# Turbulent Mountain Stress
3582
3657
my $do_tms ;
@@ -4927,7 +5002,7 @@ sub check_input_files {
4927
5002
my @vars = qw( aircraft_specifier csw_specifier ext_frc_specifier
4928
5003
rad_climate rad_diag_1 rad_diag_2 rad_diag_3 rad_diag_4
4929
5004
rad_diag_5 rad_diag_6 rad_diag_7 rad_diag_8 rad_diag_9
4930
- rad_diag_10 srf_emis_specifier mode_defs) ;
5005
+ rad_diag_10 srf_emis_specifier mode_defs bin_defs ) ;
4931
5006
4932
5007
foreach my $var (@vars ) {
4933
5008
@@ -4987,11 +5062,11 @@ sub check_input_files {
4987
5062
}
4988
5063
}
4989
5064
}
4990
- # Look for values that begin with 'X:name:name2' where X is one of [AMN ]
5065
+ # Look for values that begin with 'X:name:name2' where X is one of [ABMN ]
4991
5066
# Extract name and filename
4992
- elsif ($spec =~ m / ^\s *[AMN ] :(\w +) # name of species preceded by optional whitespace and X:
4993
- : # : separator
4994
- (\S +) # name2
5067
+ elsif ($spec =~ m / ^\s *[ABMN ] :(\w +) # name of species preceded by optional whitespace and X:
5068
+ : # : separator
5069
+ (\S +) # name2
4995
5070
/ xo ) {
4996
5071
my $name = $1 ;
4997
5072
my $name2 = $2 ;
@@ -5022,9 +5097,14 @@ sub check_input_files {
5022
5097
my @flds = split /:/, $name2 ;
5023
5098
if (scalar (@flds ) >= 4) {
5024
5099
5100
+ my $file ;
5025
5101
if ($flds [3] =~ m : ^[/\$ ] : ) {
5026
-
5027
- my $file = $flds [3];
5102
+ $file = $flds [3];
5103
+ }
5104
+ elsif ($flds [4] =~ m : ^[/\$ ] : ) {
5105
+ $file = $flds [4];
5106
+ }
5107
+ if (defined $file ) {
5028
5108
if ($inputdata_rootdir ) {
5029
5109
print $fh " $var for $name = $file \n " ;
5030
5110
}
0 commit comments