OGS
MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim > Class Template Reference

Detailed Description

template<int DisplacementDim>
class MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >

Definition at line 22 of file LinearElasticOrthotropic.h.

#include <LinearElasticOrthotropic.h>

Inheritance diagram for MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >:
[legend]
Collaboration diagram for MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >:
[legend]

Classes

struct  EvaluatedMaterialProperties
 
struct  MaterialProperties
 Variables specific to the material model. More...
 

Public Types

using KelvinVector
 
using KelvinMatrix
 
- Public Types inherited from MaterialLib::Solids::MechanicsBase< DisplacementDim >
using KelvinVector
 
using KelvinMatrix
 

Public Member Functions

 LinearElasticOrthotropic (MaterialProperties material_properties, std::optional< ParameterLib::CoordinateSystem > const &local_coordinate_system)
 
double computeFreeEnergyDensity (double const, ParameterLib::SpatialPosition const &, double const, KelvinVector const &eps, KelvinVector const &sigma, typename MechanicsBase< DisplacementDim >::MaterialStateVariables const &) const override
 
std::optional< std::tuple< typename MechanicsBase< DisplacementDim >::KelvinVector, std::unique_ptr< typename MechanicsBase< DisplacementDim >::MaterialStateVariables >, typename MechanicsBase< DisplacementDim >::KelvinMatrix > > integrateStress (MaterialPropertyLib::VariableArray const &variable_array_prev, MaterialPropertyLib::VariableArray const &variable_array, double const t, ParameterLib::SpatialPosition const &x, double const, typename MechanicsBase< DisplacementDim >::MaterialStateVariables const &material_state_variables) const override
 
KelvinMatrix getElasticTensor (double const t, ParameterLib::SpatialPosition const &x, double const T) const
 
MaterialProperties getMaterialProperties () const
 
double getBulkModulus (double const t, ParameterLib::SpatialPosition const &x, KelvinMatrix const *const) const override
 
- Public Member Functions inherited from MaterialLib::Solids::MechanicsBase< DisplacementDim >
virtual std::unique_ptr< MaterialStateVariablescreateMaterialStateVariables () const
 
virtual void initializeInternalStateVariables (double const, ParameterLib::SpatialPosition const &, typename MechanicsBase< DisplacementDim >::MaterialStateVariables &) const
 
virtual std::optional< std::tuple< KelvinVector, std::unique_ptr< MaterialStateVariables >, KelvinMatrix > > integrateStress (MaterialPropertyLib::VariableArray const &variable_array_prev, MaterialPropertyLib::VariableArray const &variable_array, double const t, ParameterLib::SpatialPosition const &x, double const dt, MaterialStateVariables const &material_state_variables) const =0
 
virtual std::vector< InternalVariablegetInternalVariables () const
 
virtual ConstitutiveModel getConstitutiveModel () const
 Gets the type of constitutive model.
 
virtual double getTemperatureRelatedCoefficient (double const, double const, ParameterLib::SpatialPosition const &, double const, double const) const
 
virtual double computeFreeEnergyDensity (double const t, ParameterLib::SpatialPosition const &x, double const dt, KelvinVector const &eps, KelvinVector const &sigma, MaterialStateVariables const &material_state_variables) const =0
 
virtual ~MechanicsBase ()=default
 

Static Public Attributes

static int const KelvinVectorSize
 

Protected Attributes

MaterialProperties _mp
 
std::optional< ParameterLib::CoordinateSystem > const & _local_coordinate_system
 

Member Typedef Documentation

◆ KelvinMatrix

template<int DisplacementDim>
using MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::KelvinMatrix
Initial value:
Eigen::Matrix< double, kelvin_vector_dimensions(DisplacementDim), kelvin_vector_dimensions(DisplacementDim), Eigen::RowMajor > KelvinMatrixType

Definition at line 130 of file LinearElasticOrthotropic.h.

◆ KelvinVector

template<int DisplacementDim>
using MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::KelvinVector
Initial value:
Eigen::Matrix< double, kelvin_vector_dimensions(DisplacementDim), 1, Eigen::ColMajor > KelvinVectorType

Definition at line 128 of file LinearElasticOrthotropic.h.

Constructor & Destructor Documentation

◆ LinearElasticOrthotropic()

template<int DisplacementDim>
MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::LinearElasticOrthotropic ( MaterialProperties material_properties,
std::optional< ParameterLib::CoordinateSystem > const & local_coordinate_system )
inline

Definition at line 133 of file LinearElasticOrthotropic.h.

137 : _mp(std::move(material_properties)),
138 _local_coordinate_system(local_coordinate_system)
139 {
140 }
std::optional< ParameterLib::CoordinateSystem > const & _local_coordinate_system

Member Function Documentation

◆ computeFreeEnergyDensity()

template<int DisplacementDim>
double MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::computeFreeEnergyDensity ( double const ,
ParameterLib::SpatialPosition const & ,
double const ,
KelvinVector const & eps,
KelvinVector const & sigma,
typename MechanicsBase< DisplacementDim >::MaterialStateVariables const &  ) const
inlineoverride

Definition at line 142 of file LinearElasticOrthotropic.h.

151 {
152 return eps.dot(sigma) / 2;
153 }

◆ getBulkModulus()

template<int DisplacementDim>
double MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::getBulkModulus ( double const t,
ParameterLib::SpatialPosition const & x,
KelvinMatrix const * const  ) const
inlineoverridevirtual

Reimplemented from MaterialLib::Solids::MechanicsBase< DisplacementDim >.

Definition at line 174 of file LinearElasticOrthotropic.h.

177 {
178 auto const& mp = _mp.evaluate(t, x);
179 auto const E = [&mp](int const i) { return mp.E(i); };
180 auto const nu = [&mp](int const i, int const j) { return mp.nu(i, j); };
181 // corresponds to 1/(I:S:I) --> Reuss bound.
182 // Voigt bound would proceed as (I:C:I)/9. Use MFront model if you
183 // prefer that.
184 return E(1) * E(2) * E(3) /
185 (E(1) * E(2) + E(1) * E(3) * (1 - 2 * nu(2, 3)) +
186 E(2) * E(3) * (1 - 2 * nu(1, 2) * nu(1, 3)));
187 }
constexpr double E(int const i) const
Youngs moduli for 1-based indices.
EvaluatedMaterialProperties evaluate(double const t, ParameterLib::SpatialPosition const &x) const

References MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::_mp, MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::EvaluatedMaterialProperties::E(), and MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::MaterialProperties::evaluate().

◆ getElasticTensor()

template<int DisplacementDim>
LinearElasticOrthotropic< DisplacementDim >::KelvinMatrix MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::getElasticTensor ( double const t,
ParameterLib::SpatialPosition const & x,
double const T ) const

Definition at line 55 of file LinearElasticOrthotropic.cpp.

58{
59 using namespace MathLib::KelvinVector;
60
61 auto const& mp = _mp.evaluate(t, x);
62 auto const E = [&mp](int const i) { return mp.E(i); };
63 auto const G = [&mp](int const i, int const j) { return mp.G(i, j); };
64 auto const nu = [&mp](int const i, int const j) { return mp.nu(i, j); };
65
67 // clang-format off
68 S_ortho.template topLeftCorner<3, 3>() <<
69 1. / E(1), -nu(2, 1) / E(2), -nu(3, 1) / E(3),
70 -nu(1, 2) / E(1), 1. / E(2), -nu(3, 2) / E(3),
71 -nu(1, 3) / E(1), -nu(2, 3) / E(2), 1. / E(3);
72
73 S_ortho.template bottomRightCorner<3, 3>().diagonal() <<
74 1. / (2 * G(1, 2)),
75 1. / (2 * G(2, 3)),
76 1. / (2 * G(1, 3));
77 // clang-format on
78
79 KelvinMatrixType<3> const C_ortho = S_ortho.inverse();
80 auto const Q = [this, &x]() -> KelvinMatrixType<3>
81 {
83 {
85 }
86 Eigen::Matrix3d R = Eigen::Matrix3d::Identity();
87 R.template topLeftCorner<DisplacementDim, DisplacementDim>().noalias() =
88 _local_coordinate_system->transformation<DisplacementDim>(x);
90 }();
91
92 // Rotate the forth-order tenser in Kelvin mapping with Q*C_ortho*Q^T and
93 // return the top left corner block of size 4x4 for two-dimensional case or
94 // the full 6x6 matrix is returned in the three-dimensional case.
95 return (Q * C_ortho * Q.transpose())
96 .template topLeftCorner<kelvin_vector_dimensions(DisplacementDim),
97 kelvin_vector_dimensions(DisplacementDim)>();
98}
KelvinMatrixType< DisplacementDim > fourthOrderRotationMatrix(Eigen::Matrix< double, DisplacementDim, DisplacementDim, Eigen::ColMajor, DisplacementDim, DisplacementDim > const &transformation)
constexpr int kelvin_vector_dimensions(int const displacement_dim)
Kelvin vector dimensions for given displacement dimension.

Referenced by MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::integrateStress().

◆ getMaterialProperties()

template<int DisplacementDim>
MaterialProperties MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::getMaterialProperties ( ) const
inline

◆ integrateStress()

template<int DisplacementDim>
std::optional< std::tuple< typename MechanicsBase< DisplacementDim >::KelvinVector, std::unique_ptr< typename MechanicsBase< DisplacementDim >::MaterialStateVariables >, typename MechanicsBase< DisplacementDim >::KelvinMatrix > > MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::integrateStress ( MaterialPropertyLib::VariableArray const & variable_array_prev,
MaterialPropertyLib::VariableArray const & variable_array,
double const t,
ParameterLib::SpatialPosition const & x,
double const ,
typename MechanicsBase< DisplacementDim >::MaterialStateVariables const & material_state_variables ) const
override

Definition at line 27 of file LinearElasticOrthotropic.cpp.

33{
34 auto const& eps_m = std::get<MPL::SymmetricTensor<DisplacementDim>>(
35 variable_array.mechanical_strain);
36 auto const& eps_m_prev = std::get<MPL::SymmetricTensor<DisplacementDim>>(
37 variable_array_prev.mechanical_strain);
38 auto const& sigma_prev = std::get<MPL::SymmetricTensor<DisplacementDim>>(
39 variable_array_prev.stress);
40 auto const& T = variable_array_prev.temperature;
41
43
44 KelvinVector sigma = sigma_prev + C * (eps_m - eps_m_prev);
45
46 return {std::make_tuple(
47 sigma,
48 std::make_unique<
49 typename MechanicsBase<DisplacementDim>::MaterialStateVariables>(),
50 C)};
51}
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > KelvinMatrix
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > KelvinVector
KelvinMatrix getElasticTensor(double const t, ParameterLib::SpatialPosition const &x, double const T) const

References MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::getElasticTensor(), MaterialPropertyLib::VariableArray::mechanical_strain, MaterialPropertyLib::VariableArray::stress, and MaterialPropertyLib::VariableArray::temperature.

Member Data Documentation

◆ _local_coordinate_system

template<int DisplacementDim>
std::optional<ParameterLib::CoordinateSystem> const& MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::_local_coordinate_system
protected

Definition at line 192 of file LinearElasticOrthotropic.h.

◆ _mp

◆ KelvinVectorSize

template<int DisplacementDim>
int const MaterialLib::Solids::LinearElasticOrthotropic< DisplacementDim >::KelvinVectorSize
static
Initial value:

Definition at line 126 of file LinearElasticOrthotropic.h.


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