ActivityModel.hpp
45 // Declare this so that Model understands ActivityPropsRef as reference type for ActivityProps instead of ActivityProps&.
63 auto chain(ActivityModelGenerator const& model, Models const&... models) -> ActivityModelGenerator
Definition: Model.hpp:30
The namespace containing all components of the Reaktoro library.
Definition: Algorithms.hpp:29
Fn< ActivityModel(SpeciesList const &species)> ActivityModelGenerator
The type for functions that construct an ActivityModel for a phase.
Definition: ActivityModel.hpp:53
auto chain(const Vec< ActivityModelGenerator > &models) -> ActivityModelGenerator
Return an activity model resulting from chaining other activity models.
Model< ActivityProps(ActivityModelArgs)> ActivityModel
The function type for the calculation of activity and corrective thermodynamic properties of a phase.
Definition: ActivityModel.hpp:49
autodiff::real real
The number type used throughout the library.
Definition: Real.hpp:26
std::tuple< Args... > Tuple
Convenient alias for std::tuple<Args...>.
Definition: Types.hpp:94
std::function< F > Fn
Convenient alias for std::function<R(Args...)>.
Definition: Types.hpp:110
Eigen::Ref< const ArrayXr > ArrayXrConstRef
Convenient alias to Eigen type.
Definition: Matrix.hpp:89
ActivityPropsBase< TypeOpIdentity > ActivityProps
The activity and corrective thermodynamic properties of a phase.
Definition: ActivityProps.hpp:159
The arguments in an function for calculation of activity properties of a phase.
Definition: ActivityModel.hpp:34
real const & T
The temperature for the calculation (in K).
Definition: ActivityModel.hpp:36
real const & P
The pressure for the calculation (in Pa).
Definition: ActivityModel.hpp:39
ArrayXrConstRef x
The mole fractions of the species in the phase.
Definition: ActivityModel.hpp:42
The base type for the primary activity and corrective thermodynamic properties of a phase.
Definition: ActivityProps.hpp:59
Tuple< real, real, ArrayXr > CacheType
The type used instead to cache an ActivityModelArgs object.
Definition: ActivityModel.hpp:87
Used to enable function arguments of a type T to be cached in a memoized version of the function.
Definition: Memoization.hpp:30
static auto assign(CacheType &a, const Type &b)
Assign the value of b, of type T, into a, of type CacheType.
Definition: Memoization.hpp:64
static auto equal(const CacheType &a, const Type &b)
Check if a, of type CacheType, is equal to b, of type T.
Definition: Memoization.hpp:56