Lethe Open-Source Library version 1.2.0
Developer Guide
Loading...
Searching...
No Matches
DensityModel Class Referenceabstract

#include <density_model.h>

Inheritance diagram for DensityModel:
[legend]

Public Member Functions

virtual double get_psi () const =0
virtual double get_density_ref () const =0
bool is_constant_density_model () const
Public Member Functions inherited from PhysicalPropertyModel
 PhysicalPropertyModel ()
virtual ~PhysicalPropertyModel ()=default
bool depends_on (const field &id)
virtual double value (const std::map< field, double > &fields_value)=0
virtual void vector_value (const std::map< field, std::vector< double > > &field_vectors, std::vector< double > &property_vector)=0
virtual double jacobian (const std::map< field, double > &field_values, const field id)=0
virtual void vector_jacobian (const std::map< field, std::vector< double > > &field_vectors, const field id, std::vector< double > &jacobian_vector)=0
void provide_simulation_control (std::shared_ptr< SimulationControl > &p_simulation_control)
double numerical_jacobian (const std::map< field, double > &field_values, const field id)
void vector_numerical_jacobian (const std::map< field, std::vector< double > > &field_vectors, const field id, std::vector< double > &jacobian_vector)

Static Public Member Functions

static std::shared_ptr< DensityModel > model_cast (const Parameters::Material &material_properties)

Protected Attributes

bool constant_density_model = false
Protected Attributes inherited from PhysicalPropertyModel
std::map< field, bool > model_depends_on

Additional Inherited Members

Public Types inherited from PhysicalPropertyModel
enum class  ComplexComponent : std::int8_t { real , imag }
Protected Member Functions inherited from PhysicalPropertyModel
std::shared_ptr< SimulationControl > & get_simulation_control ()

Detailed Description

Abstract class for calculating the density of materials.

Definition at line 14 of file density_model.h.

Member Function Documentation

◆ get_density_ref()

virtual double DensityModel::get_density_ref ( ) const
pure virtual

Get the value of the reference state density used in the density model.

Returns
Value of the reference state density.

Implemented in DensityConstant, and DensityIsothermalIdealGas.

◆ get_psi()

virtual double DensityModel::get_psi ( ) const
pure virtual

Get the value of the compressibility factor used in the density model.

Returns
Value of the compressibility factor.

Implemented in DensityConstant, and DensityIsothermalIdealGas.

◆ is_constant_density_model()

bool DensityModel::is_constant_density_model ( ) const
inline

Check if the model is a constant density model.

Returns
Boolean indicating if the model corresponds to a constant density model.

Definition at line 55 of file density_model.h.

References constant_density_model.

◆ model_cast()

std::shared_ptr< DensityModel > DensityModel::model_cast ( const Parameters::Material & material_properties)
static

Instantiate and return a pointer to a DensityModel object by casting it to the proper child class.

Parameters
[in]material_propertiesProperty parameters of a material (fluid or solid).
Returns
Casted DensityModel object.

Definition at line 7 of file density_model.cc.

References Parameters::Material::density, Parameters::Material::density_model, Parameters::IsothermalIdealGasDensityParameters::density_ref, Parameters::Material::isothermal_ideal_gas, Parameters::Material::isothermal_ideal_gas_density_parameters, Parameters::IsothermalIdealGasDensityParameters::R, and Parameters::IsothermalIdealGasDensityParameters::T.

Member Data Documentation

◆ constant_density_model

bool DensityModel::constant_density_model = false
protected

Boolean indicating if the model corresponds to a constant density model.

Definition at line 62 of file density_model.h.


The documentation for this class was generated from the following files: