OGS
EquilibriumReactants.cpp
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (c) OpenGeoSys Community (opengeosys.org)
2
// SPDX-License-Identifier: BSD-3-Clause
3
4
#include "
EquilibriumReactants.h
"
5
6
namespace
ChemistryLib
7
{
8
namespace
PhreeqcKernelData
9
{
10
PhaseComponent::PhaseComponent
(std::string&& name_,
11
double
const
initial_amount,
12
double
const
saturation_index)
13
{
14
name = std::move(name_);
15
moles = initial_amount;
16
si = saturation_index;
17
si_org = saturation_index;
18
}
19
20
EquilibriumReactants::EquilibriumReactants
(
21
std::vector<PhaseComponent>
const
& phase_components)
22
{
23
for
(
auto
const
& phase_component : phase_components)
24
{
25
auto
& name = phase_component.getName();
26
pp_assemblage_comps[name] = *phase_component.castToBaseClass();
27
}
28
}
29
}
// namespace PhreeqcKernelData
30
}
// namespace ChemistryLib
EquilibriumReactants.h
ChemistryLib::PhreeqcKernelData::EquilibriumReactants::EquilibriumReactants
EquilibriumReactants(std::vector< PhaseComponent > const &phase_components)
Definition
EquilibriumReactants.cpp:20
ChemistryLib::PhreeqcKernelData::PhaseComponent::PhaseComponent
PhaseComponent(std::string &&name_, double const initial_amount, double const saturation_index)
Definition
EquilibriumReactants.cpp:10
ChemistryLib::PhreeqcKernelData
Definition
PhreeqcKernel.cpp:18
ChemistryLib
Definition
ChemicalSolverInterface.h:108
ChemistryLib
PhreeqcKernelData
EquilibriumReactants.cpp
Generated by
1.14.0