OGS
|
This class defines material phases.
The Phase class consists of a vector of components and an array of properties.
#include <Phase.h>
Public Member Functions | |
Phase (std::string &&phase_name, std::vector< std::unique_ptr< Component > > &&components, std::unique_ptr< PropertyArray > &&properties) | |
The Phase constructor is called with the optional phase name. | |
Component const & | component (std::size_t const &index) const |
bool | hasComponent (std::size_t const &index) const |
Component const & | component (std::string const &name) const |
A get-function for a component by component name. | |
Property const & | property (PropertyType const &p) const |
Property const & | operator[] (PropertyType const &p) const |
bool | hasProperty (PropertyType const &p) const |
std::size_t | numberOfComponents () const |
A get-function for retrieving the number of components in this phase. | |
std::string | description () const |
Short description of the phase with its name. | |
Public Attributes | |
std::string const | name |
Private Attributes | |
std::vector< std::unique_ptr< Component > > const | components_ |
PropertyArray | properties_ |
MaterialPropertyLib::Phase::Phase | ( | std::string && | phase_name, |
std::vector< std::unique_ptr< Component > > && | components, | ||
std::unique_ptr< PropertyArray > && | properties ) |
The Phase constructor is called with the optional phase name.
Definition at line 22 of file Phase.cpp.
References MaterialPropertyLib::overwriteExistingProperties(), and properties_.
Component const & MaterialPropertyLib::Phase::component | ( | std::size_t const & | index | ) | const |
A simple get-function for a component. The argument refers to the Index of the component in the components vector.
Definition at line 33 of file Phase.cpp.
References components_.
Referenced by ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::assembleBlockMatrices(), ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::assembleComponentTransportEquation(), ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::assembleKCmCn(), ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::assembleWithJacobianComponentTransportEquation(), component(), ProcessLib::TH2M::ConstitutiveRelations::PhaseTransition::eval(), ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::getIntPtMolarFlux(), ChemistryLib::PhreeqcIOData::anonymous_namespace{PhreeqcIO.cpp}::initializeReactantMolality(), ChemistryLib::PhreeqcIOData::anonymous_namespace{PhreeqcIO.cpp}::initializeSiteMolality(), ChemistryLib::PhreeqcIOData::anonymous_namespace{PhreeqcIO.cpp}::setPorosityPostReaction(), and ChemistryLib::PhreeqcIOData::anonymous_namespace{PhreeqcIO.cpp}::setReactantMolality().
Component const & MaterialPropertyLib::Phase::component | ( | std::string const & | name | ) | const |
A get-function for a component by component name.
Definition at line 43 of file Phase.cpp.
References component(), components_, BaseLib::findElementOrError(), MaterialPropertyLib::Component::name, name, and OGS_FATAL.
std::string MaterialPropertyLib::Phase::description | ( | ) | const |
Short description of the phase with its name.
Definition at line 79 of file Phase.cpp.
References name.
Referenced by property().
bool MaterialPropertyLib::Phase::hasComponent | ( | std::size_t const & | index | ) | const |
Definition at line 38 of file Phase.cpp.
References components_.
bool MaterialPropertyLib::Phase::hasProperty | ( | PropertyType const & | p | ) | const |
Definition at line 69 of file Phase.cpp.
References properties_.
Referenced by ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowLocalAssembler< ShapeFunction, GlobalDim >::assemble(), ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowLocalAssembler< ShapeFunction, GlobalDim >::assembleWithJacobian(), ProcessLib::ThermoRichardsFlow::SimplifiedElasticityModel::bulkCompressibilityFromYoungsModulus(), MaterialPropertyLib::checkRequiredProperties(), ProcessLib::TH2M::ConstitutiveRelations::ThermalConductivityModel< DisplacementDim >::dEval(), ProcessLib::ThermoRichardsMechanics::TRMVaporDiffusionModel< DisplacementDim >::eval(), ProcessLib::LiquidFlow::getFluidDensityAndViscosity(), MaterialPropertyLib::getLiquidThermalExpansivity(), ProcessLib::ThermoRichardsMechanics::ConstitutiveStress_StrainTemperature::ConstitutiveSetting< DisplacementDim >::init(), and ProcessLib::RichardsMechanics::updateSwellingStressAndVolumetricStrain().
std::size_t MaterialPropertyLib::Phase::numberOfComponents | ( | ) | const |
A get-function for retrieving the number of components in this phase.
Definition at line 74 of file Phase.cpp.
References components_.
Property const & MaterialPropertyLib::Phase::operator[] | ( | PropertyType const & | p | ) | const |
Definition at line 64 of file Phase.cpp.
References property().
Property const & MaterialPropertyLib::Phase::property | ( | PropertyType const & | p | ) | const |
A get-function for a property. The argument refers to the name of the property.
Definition at line 53 of file Phase.cpp.
References description(), OGS_FATAL, properties_, property(), and MaterialPropertyLib::property_enum_to_string.
Referenced by ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowLocalAssembler< ShapeFunction, GlobalDim >::assemble(), ProcessLib::ThermoRichardsFlow::ThermoRichardsFlowLocalAssembler< ShapeFunction, GlobalDim >::assembleWithJacobian(), ProcessLib::LargeDeformation::SolidDensityModel::eval(), ProcessLib::SmallDeformation::SolidDensityModel::eval(), ProcessLib::TH2M::ConstitutiveRelations::SolidThermalExpansionModel< DisplacementDim >::eval(), ProcessLib::ThermoRichardsMechanics::LiquidViscosityModel< DisplacementDim >::eval(), ProcessLib::ThermoRichardsMechanics::SolidDensityModel< DisplacementDim >::eval(), ProcessLib::ThermoRichardsMechanics::SolidThermalExpansionModel< DisplacementDim >::eval(), ProcessLib::ThermoRichardsMechanics::TRMHeatStorageAndFluxModel< DisplacementDim >::eval(), ProcessLib::ThermoRichardsMechanics::TRMVaporDiffusionModel< DisplacementDim >::eval(), ProcessLib::LiquidFlow::getFluidDensityAndViscosity(), ProcessLib::ComponentTransport::LocalAssemblerData< ShapeFunction, GlobalDim >::getHeatEnergyCoefficient(), ProcessLib::HT::HTFEM< ShapeFunction, GlobalDim >::getHeatEnergyCoefficient(), MaterialPropertyLib::getLiquidThermalExpansivity(), operator[](), property(), and ProcessLib::RichardsMechanics::updateSwellingStressAndVolumetricStrain().
|
private |
Definition at line 65 of file Phase.h.
Referenced by component(), component(), hasComponent(), and numberOfComponents().
std::string const MaterialPropertyLib::Phase::name |
Definition at line 62 of file Phase.h.
Referenced by MaterialPropertyLib::checkRequiredProperties(), component(), description(), MaterialPropertyLib::Medium::hasPhase(), and MaterialPropertyLib::Medium::phase().
|
private |
Here, all for all properties listed in the Properties enumerator are initialized by mole average functions of value zero. However, 'special-default' properties are allowed to be set.
After this, other special properties can be set as exceptional defaults.
Definition at line 72 of file Phase.h.
Referenced by Phase(), hasProperty(), and property().