From e3da19494b17c477f9d6e32feb244dc5f2b06e2a Mon Sep 17 00:00:00 2001 From: Kyle Shores Date: Fri, 19 Jan 2024 14:55:52 -0600 Subject: [PATCH] parsing condensed phase photolysis --- examples/full_configuration.json | 4 - .../mechanism_configuration/validation.hpp | 13 ++ include/open_atmos/types.hpp | 29 ++++- src/parser.cpp | 118 ++++++++++++++++++ test/integration/test_json_parser.cpp | 1 + test/unit/CMakeLists.txt | 1 + .../test_parse_condensed_phase_photolysis.cpp | 79 ++++++++++++ .../bad_reaction_component.json | 48 +++++++ .../missing_aerosol_phase_water.json | 48 +++++++ .../missing_phase.json | 38 ++++++ .../more_than_one_reactant.json | 50 ++++++++ .../species_not_in_aerosol_phase.json | 51 ++++++++ .../unknown_species.json | 40 ++++++ .../condensed_phase_photolysis/valid.json | 68 ++++++++++ .../photolysis/more_than_one_reactant.json | 2 +- 15 files changed, 580 insertions(+), 10 deletions(-) create mode 100644 test/unit/test_parse_condensed_phase_photolysis.cpp create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/bad_reaction_component.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_aerosol_phase_water.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_phase.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/more_than_one_reactant.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/species_not_in_aerosol_phase.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/unknown_species.json create mode 100644 test/unit/unit_configs/reactions/condensed_phase_photolysis/valid.json diff --git a/examples/full_configuration.json b/examples/full_configuration.json index 7c94eaf..104ebbb 100644 --- a/examples/full_configuration.json +++ b/examples/full_configuration.json @@ -207,10 +207,6 @@ { "species name": "H2O2_aq", "coefficient": 1 - }, - { - "species name": "H2O_aq", - "coefficient": 1 } ], "products": [ diff --git a/include/open_atmos/mechanism_configuration/validation.hpp b/include/open_atmos/mechanism_configuration/validation.hpp index e9c7a6b..2736fc8 100644 --- a/include/open_atmos/mechanism_configuration/validation.hpp +++ b/include/open_atmos/mechanism_configuration/validation.hpp @@ -101,6 +101,13 @@ namespace open_atmos const std::string Photolysis_key = "PHOTOLYSIS"; const std::string scaling_factor = "scaling factor"; + // Condensed Phae Photolysis + const std::string CondensedPhasePhotolysis_key = "CONDENSED_PHASE_PHOTOLYSIS"; + // also + // scaling factor + // aerosol phase + // aerosol-phase water + // Emissions const std::string Emission_key = "EMISSION"; // also scaling factor @@ -185,6 +192,12 @@ namespace open_atmos const std::vector optional_keys{ keys.name, keys.scaling_factor }; } photolysis; + struct CondensedPhasePhotolysis + { + const std::vector required_keys{ keys.reactants, keys.products, keys.type, keys.aerosol_phase, keys.aerosol_phase_water }; + const std::vector optional_keys{ keys.name, keys.scaling_factor }; + } condensed_phase_photolysis; + struct Emission { const std::vector required_keys{ keys.products, keys.type, keys.gas_phase }; diff --git a/include/open_atmos/types.hpp b/include/open_atmos/types.hpp index 7ff2b37..4b2c9ba 100644 --- a/include/open_atmos/types.hpp +++ b/include/open_atmos/types.hpp @@ -195,6 +195,24 @@ namespace open_atmos std::unordered_map unknown_properties; }; + struct CondensedPhasePhotolysis + { + /// @brief Scaling factor to apply to user-provided rate constants + double scaling_factor_{ 1.0 }; + /// @brief A list of reactants + std::vector reactants; + /// @brief A list of products + std::vector products; + /// @brief An identifier, optional, uniqueness not enforced + std::string name; + /// @brief An identifier indicating which aerosol phase this reaction takes place in + std::string aerosol_phase; + /// @brief An identifier indicating the species label of aqueous phase water + std::string aerosol_phase_water; + /// @brief Unknown properties, prefixed with two underscores (__) + std::unordered_map unknown_properties; + }; + struct Emission { /// @brief Scaling factor to apply to user-provided rate constants @@ -226,14 +244,15 @@ namespace open_atmos struct Reactions { std::vector arrhenius; - std::vector condensed_phase_arrhenius; - std::vector troe; std::vector branched; - std::vector tunneling; - std::vector surface; - std::vector photolysis; + std::vector condensed_phase_arrhenius; + std::vector condensed_phase_photolysis; std::vector emission; std::vector first_order_loss; + std::vector photolysis; + std::vector surface; + std::vector troe; + std::vector tunneling; }; struct Mechanism diff --git a/src/parser.cpp b/src/parser.cpp index 615ebb0..7fe3aa3 100644 --- a/src/parser.cpp +++ b/src/parser.cpp @@ -1078,6 +1078,114 @@ namespace open_atmos return { status, photolysis }; } + /// @brief Parses a photolysis reaction + /// @param object A json object that should have information containing arrhenius parameters + /// @param existing_species A list of species configured in a mechanism + /// @param existing_phases A list of phases configured in a mechanism + /// @return A pair indicating parsing success and a struct of Photolysis parameters + std::pair + ParseCondensedPhasePhotolysis(const json& object, const std::vector existing_species, const std::vector existing_phases) + { + ConfigParseStatus status = ConfigParseStatus::Success; + types::CondensedPhasePhotolysis condensed_phase_photolysis; + + status = ValidateSchema(object, validation::condensed_phase_photolysis.required_keys, validation::photolysis.optional_keys); + if (status == ConfigParseStatus::Success) + { + std::vector products{}; + for (const auto& reactant : object[validation::keys.products]) + { + auto product_parse = ParseReactionComponent(reactant); + status = product_parse.first; + if (status != ConfigParseStatus::Success) + { + break; + } + products.push_back(product_parse.second); + } + + std::vector reactants{}; + for (const auto& reactant : object[validation::keys.reactants]) + { + auto reactant_parse = ParseReactionComponent(reactant); + status = reactant_parse.first; + if (status != ConfigParseStatus::Success) + { + break; + } + reactants.push_back(reactant_parse.second); + } + + if (object.contains(validation::keys.scaling_factor)) + { + condensed_phase_photolysis.scaling_factor_ = object[validation::keys.scaling_factor].get(); + } + + if (object.contains(validation::keys.name)) + { + condensed_phase_photolysis.name = object[validation::keys.name].get(); + } + + auto comments = GetComments(object, validation::condensed_phase_photolysis.required_keys, validation::photolysis.optional_keys); + + std::unordered_map unknown_properties; + for (const auto& key : comments) + { + std::string val = object[key].dump(); + unknown_properties[key] = val; + } + + std::string aerosol_phase = object[validation::keys.aerosol_phase].get(); + std::string aerosol_phase_water = object[validation::keys.aerosol_phase_water].get(); + + std::vector requested_species; + for (const auto& spec : products) + { + requested_species.push_back(spec.species_name); + } + for (const auto& spec : reactants) + { + requested_species.push_back(spec.species_name); + } + requested_species.push_back(aerosol_phase_water); + + if (status == ConfigParseStatus::Success && RequiresUnknownSpecies(requested_species, existing_species)) + { + status = ConfigParseStatus::ReactionRequiresUnknownSpecies; + } + + if (status == ConfigParseStatus::Success && reactants.size() > 1) + { + status = ConfigParseStatus::TooManyReactionComponents; + } + + auto phase_it = std::find_if( + existing_phases.begin(), existing_phases.end(), [&aerosol_phase](const types::Phase& phase) { return phase.name == aerosol_phase; }); + + if (phase_it != existing_phases.end()) + { + // check if all of the species for this reaction are actually in the aerosol phase + std::vector aerosol_phase_species = { (*phase_it).species.begin(), (*phase_it).species.end() }; + if (status == ConfigParseStatus::Success && RequiresUnknownSpecies(requested_species, aerosol_phase_species)) + { + status = ConfigParseStatus::RequestedAerosolSpeciesNotIncludedInAerosolPhase; + } + } + else + { + status = ConfigParseStatus::UnknownPhase; + } + + condensed_phase_photolysis.aerosol_phase = aerosol_phase; + condensed_phase_photolysis.aerosol_phase_water = aerosol_phase_water; + condensed_phase_photolysis.products = products; + condensed_phase_photolysis.reactants = reactants; + condensed_phase_photolysis.unknown_properties = unknown_properties; + } + + return { status, condensed_phase_photolysis }; + } + /// @brief Parses a emission reaction /// @param object A json object that should have information containing arrhenius parameters /// @param existing_species A list of species configured in a mechanism @@ -1309,6 +1417,16 @@ namespace open_atmos } reactions.photolysis.push_back(photolysis_parse.second); } + else if (type == validation::keys.CondensedPhasePhotolysis_key) + { + auto condensed_phase_photolysis_parse = ParseCondensedPhasePhotolysis(object, existing_species, existing_phases); + status = condensed_phase_photolysis_parse.first; + if (status != ConfigParseStatus::Success) + { + break; + } + reactions.condensed_phase_photolysis.push_back(condensed_phase_photolysis_parse.second); + } else if (type == validation::keys.Emission_key) { auto emission_parse = ParseEmission(object, existing_species, existing_phases); diff --git a/test/integration/test_json_parser.cpp b/test/integration/test_json_parser.cpp index d18f34c..09c419d 100644 --- a/test/integration/test_json_parser.cpp +++ b/test/integration/test_json_parser.cpp @@ -19,6 +19,7 @@ TEST(JsonParser, ParsesFullConfiguration) EXPECT_EQ(mechanism.reactions.tunneling.size(), 1); EXPECT_EQ(mechanism.reactions.surface.size(), 1); EXPECT_EQ(mechanism.reactions.photolysis.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis.size(), 1); EXPECT_EQ(mechanism.reactions.emission.size(), 1); EXPECT_EQ(mechanism.reactions.first_order_loss.size(), 1); } diff --git a/test/unit/CMakeLists.txt b/test/unit/CMakeLists.txt index bc64576..fd94572 100644 --- a/test/unit/CMakeLists.txt +++ b/test/unit/CMakeLists.txt @@ -9,6 +9,7 @@ include(test_util) create_standard_test(NAME parse_arrhenius SOURCES test_parse_arrhenius.cpp) create_standard_test(NAME parse_branched SOURCES test_parse_branched.cpp) create_standard_test(NAME parse_condensed_phase_arrhenius SOURCES test_parse_condensed_phase_arrhenius.cpp) +create_standard_test(NAME parse_condensed_phase_photolysis SOURCES test_parse_condensed_phase_photolysis.cpp) create_standard_test(NAME parse_emission SOURCES test_parse_emission.cpp) create_standard_test(NAME parse_first_order_loss SOURCES test_parse_first_order_loss.cpp) create_standard_test(NAME parse_phases SOURCES test_parse_phases.cpp) diff --git a/test/unit/test_parse_condensed_phase_photolysis.cpp b/test/unit/test_parse_condensed_phase_photolysis.cpp new file mode 100644 index 0000000..acaf4eb --- /dev/null +++ b/test/unit/test_parse_condensed_phase_photolysis.cpp @@ -0,0 +1,79 @@ +#include + +#include + +using namespace open_atmos::mechanism_configuration; + +TEST(JsonParser, CanParseValidCondensedPhasePhotolysisReaction) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/valid.json")); + EXPECT_EQ(status, ConfigParseStatus::Success); + + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis.size(), 2); + + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].aerosol_phase, "aqueous aerosol"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].aerosol_phase_water, "H2O_aq"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].name, "my condensed phase photolysis"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].scaling_factor_, 12.3); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].reactants.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].reactants[0].species_name, "B"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].reactants[0].coefficient, 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].products.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].products[0].species_name, "C"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].products[0].coefficient, 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].unknown_properties.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[0].unknown_properties["__comment"], "\"hi\""); + + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].aerosol_phase, "aqueous aerosol"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].aerosol_phase_water, "H2O_aq"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].scaling_factor_, 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].reactants.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].reactants[0].species_name, "B"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].reactants[0].coefficient, 1.2); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].products.size(), 1); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].products[0].species_name, "C"); + EXPECT_EQ(mechanism.reactions.condensed_phase_photolysis[1].products[0].coefficient, 0.2); +} + +TEST(JsonParser, CondensedPhasePhotolysisDetectsUnknownSpecies) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/unknown_species.json")); + EXPECT_EQ(status, ConfigParseStatus::ReactionRequiresUnknownSpecies); +} + +TEST(JsonParser, CondensedPhasePhotolysisDetectsBadReactionComponent) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/bad_reaction_component.json")); + EXPECT_EQ(status, ConfigParseStatus::InvalidKey); +} + +TEST(JsonParser, CondensedPhasePhotolysisDetectsUnknownPhase) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/missing_phase.json")); + EXPECT_EQ(status, ConfigParseStatus::UnknownPhase); +} + +TEST(JsonParser, CondensedPhasePhotolysisDoesNotAcceptMoreThanOneReactant) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/more_than_one_reactant.json")); + EXPECT_EQ(status, ConfigParseStatus::TooManyReactionComponents); +} + +TEST(JsonParser, CondensedPhasePhotolysisDetectsWhenRequestedSpeciesAreNotInAerosolPhase) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/species_not_in_aerosol_phase.json")); + EXPECT_EQ(status, ConfigParseStatus::RequestedAerosolSpeciesNotIncludedInAerosolPhase); +} + +TEST(JsonParser, CondensedPhaseArrheniusDetectsUnknownAerosolPhaseWater) +{ + JsonParser parser; + auto [status, mechanism] = parser.Parse(std::string("unit_configs/reactions/condensed_phase_photolysis/missing_aerosol_phase_water.json")); + EXPECT_EQ(status, ConfigParseStatus::ReactionRequiresUnknownSpecies); +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/bad_reaction_component.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/bad_reaction_component.json new file mode 100644 index 0000000..de78eb2 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/bad_reaction_component.json @@ -0,0 +1,48 @@ +{ + "version": "1.0.0", + "name": "Bad reaction component", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "B", + "C", + "H2O_aq" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "A", + "Coefficient": 1.2 + } + ], + "products": [ + { + "species name": "B", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_aerosol_phase_water.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_aerosol_phase_water.json new file mode 100644 index 0000000..659654d --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_aerosol_phase_water.json @@ -0,0 +1,48 @@ +{ + "version": "1.0.0", + "name": "Missing condensed phase arrhenius aerosol phase water", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "B", + "C", + "H2O_aq" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_a", + "reactants": [ + { + "species name": "B", + "coefficient": 1.2 + } + ], + "products": [ + { + "species name": "C", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_phase.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_phase.json new file mode 100644 index 0000000..0de7a16 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/missing_phase.json @@ -0,0 +1,38 @@ +{ + "version": "1.0.0", + "name": "Missing phase", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "B", + "coefficient": 1.2 + } + ], + "products": [ + { + "species name": "C", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/more_than_one_reactant.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/more_than_one_reactant.json new file mode 100644 index 0000000..54530f1 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/more_than_one_reactant.json @@ -0,0 +1,50 @@ +{ + "version": "1.0.0", + "name": "more than one reactant", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "B", + "C", + "H2O_aq" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "A" + }, + { + "species name": "B" + } + ], + "products": [ + { + "species name": "C", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/species_not_in_aerosol_phase.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/species_not_in_aerosol_phase.json new file mode 100644 index 0000000..ad9ad21 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/species_not_in_aerosol_phase.json @@ -0,0 +1,51 @@ +{ + "version": "1.0.0", + "name": "Condensed phase photolysis using species not in its requested aerosol phase", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "C", + "H2O_aq" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "A", + "coefficient": 1 + } + ], + "products": [ + { + "species name": "B", + "coefficient": 1.2 + }, + { + "species name": "C", + "coefficient": 0.3 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/unknown_species.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/unknown_species.json new file mode 100644 index 0000000..49a1124 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/unknown_species.json @@ -0,0 +1,40 @@ +{ + "version": "1.0.0", + "name": "Unknown species", + "species": [ + { + "name": "A" + }, + { + "name": "B" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "B" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "A", + "coefficient": 1.2 + } + ], + "products": [ + { + "species name": "B", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/condensed_phase_photolysis/valid.json b/test/unit/unit_configs/reactions/condensed_phase_photolysis/valid.json new file mode 100644 index 0000000..1a907f8 --- /dev/null +++ b/test/unit/unit_configs/reactions/condensed_phase_photolysis/valid.json @@ -0,0 +1,68 @@ +{ + "version": "1.0.0", + "name": "Valid surface", + "species": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + }, + { + "name": "H2O_aq" + } + ], + "phases": [ + { + "name": "aqueous aerosol", + "species": [ + "A", + "B", + "C", + "H2O_aq" + ] + } + ], + "reactions": [ + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "__comment": "hi", + "reactants": [ + { + "species name": "B", + "coefficient": 1 + } + ], + "products": [ + { + "species name": "C", + "coefficient": 1 + } + ], + "name": "my condensed phase photolysis", + "scaling factor": 12.3 + }, + { + "type": "CONDENSED_PHASE_PHOTOLYSIS", + "aerosol phase": "aqueous aerosol", + "aerosol-phase water": "H2O_aq", + "reactants": [ + { + "species name": "B", + "coefficient": 1.2 + } + ], + "products": [ + { + "species name": "C", + "coefficient": 0.2 + } + ] + } + ] +} \ No newline at end of file diff --git a/test/unit/unit_configs/reactions/photolysis/more_than_one_reactant.json b/test/unit/unit_configs/reactions/photolysis/more_than_one_reactant.json index 5a77825..a036923 100644 --- a/test/unit/unit_configs/reactions/photolysis/more_than_one_reactant.json +++ b/test/unit/unit_configs/reactions/photolysis/more_than_one_reactant.json @@ -1,6 +1,6 @@ { "version": "1.0.0", - "name": "Valid surface", + "name": "more than one reactant", "species": [ { "name": "A"