Reaktoro 
A unified framework for modeling chemically reactive systems
ChemicalPropertiesAqueousPhase.hpp
1 // Reaktoro is a unified framework for modeling chemically reactive systems.
2 //
3 // Copyright (C) 2014-2015 Allan Leal
4 //
5 // This program is free software: you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation, either version 3 of the License, or
8 // (at your option) any later version.
9 //
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
14 //
15 // You should have received a copy of the GNU General Public License
16 // along with this program. If not, see <http://www.gnu.org/licenses/>.
17 
18 #pragma once
19 
20 // C++ includes
21 #include <memory>
22 
23 // Reaktoro includes
24 #include <Reaktoro/Common/ChemicalScalar.hpp>
25 #include <Reaktoro/Common/ChemicalVector.hpp>
26 
27 namespace Reaktoro {
28 
29 // Forward declarations
30 class ChemicalProperties;
31 class ChemicalSystem;
32 
35 {
36 public:
38  explicit ChemicalPropertiesAqueousPhase(const ChemicalProperties& properties);
39 
42  auto ionicStrength() const -> ChemicalScalar;
43 
47  auto pH() const -> ChemicalScalar;
48 
53  auto pE() const -> ChemicalScalar;
54 
66  auto pE(std::string reaction) const -> ChemicalScalar;
67 
72  auto Eh() const -> ChemicalScalar;
73 
85  auto Eh(std::string reaction) const -> ChemicalScalar;
86 
96  auto alkalinity() const -> ChemicalScalar;
97 
98 private:
99  struct Impl;
100 
101  std::shared_ptr<Impl> pimpl;
102 };
103 
104 } // namespace Reaktoro
ChemicalPropertiesAqueousPhase(const ChemicalProperties &properties)
Construct a custom ChemicalPropertiesAqueousPhase instance with given ChemicalProperties.
Definition: ChemicalPropertiesAqueousPhase.cpp:373
A class for querying thermodynamic and chemical properties of a chemical system.
Definition: ChemicalProperties.hpp:36
auto pH() const -> ChemicalScalar
Return the pH of the system.
Definition: ChemicalPropertiesAqueousPhase.cpp:382
auto alkalinity() const -> ChemicalScalar
Return the total alkalinity of the aqueous phase (in units of eq/L).
Definition: ChemicalPropertiesAqueousPhase.cpp:407
ChemicalScalarBase< double, Vector > ChemicalScalar
A type that represents a chemical scalar and its derivatives.
Definition: ChemicalScalar.hpp:35
A class for querying aqueous thermodynamic and chemical properties in a chemical system.
Definition: ChemicalPropertiesAqueousPhase.hpp:34
auto pE() const -> ChemicalScalar
Return the pE of the system.
Definition: ChemicalPropertiesAqueousPhase.cpp:387
auto Eh() const -> ChemicalScalar
Return the reduction potential of the system (in units of V).
Definition: ChemicalPropertiesAqueousPhase.cpp:397
auto ionicStrength() const -> ChemicalScalar
Return the ionic strength of the aqueous phase.
Definition: ChemicalPropertiesAqueousPhase.cpp:377
The namespace containing all components of the Reaktoro library.
Definition: ChemicalScalar.hpp:24