v0.15.0
Loading...
Searching...
No Matches
NeoHookean.hpp
/** \file NeoHookean.hpp
* \ingroup nonlinear_elastic_elem
* \brief Implementation of Neo-Hookean elastic material
* \example NeoHookean.hpp
*/
#ifndef __NEOHOOKEAN_HPP__
#define __NEOHOOKEAN_HPP__
/** \brief NeoHookan equation
* \ingroup nonlinear_elastic_elem
*/
template <typename TYPE>
struct NeoHookean
TYPE> {
TYPE detC;
TYPE logJ;
MatrixBoundedArray<TYPE, 9> invC;
FTensor::Index<'i', 3> i;
FTensor::Index<'j', 3> j;
FTensor::Index<'k', 3> k;
/** \brief calculate second Piola Kirchhoff
*
* \f$\mathbf{S} =
\mu(\mathbf{I}-\mathbf{C}^{-1})+\lambda(\ln{J})\mathbf{C}^{-1}\f$
For details look to: <br>
NONLINEAR CONTINUUM MECHANICS FOR FINITE ELEMENT ANALYSIS, Javier Bonet,
Richard D. Wood
*/
MoFEMErrorCode NeoHooke_PiolaKirchhoffII() {
detC = determinantTensor3by3(this->C);
CHKERR invertTensor3by3(this->C, detC, invC);
this->J = determinantTensor3by3(this->F);
logJ = log(sqrt(this->J * this->J));
this->t_S(i, j) = this->mu * (t_kd(i, j) - t_invC(i, j)) +
(this->lambda * logJ) * t_invC(i, j);
}
virtual MoFEMErrorCode calculateP_PiolaKirchhoffI(
boost::shared_ptr<const NumeredEntFiniteElement> fe_ptr) {
this->lambda = LAMBDA(block_data.E, block_data.PoissonRatio);
this->mu = MU(block_data.E, block_data.PoissonRatio);
this->t_P(i, j) = this->t_F(i, k) * this->t_S(k, j);
}
/** \brief calculate elastic energy density
*
For details look to: <br>
NONLINEAR CONTINUUM MECHANICS FOR FINITE ELEMENT ANALYSIS, Javier Bonet,
Richard D. Wood
*/
MoFEMErrorCode NeoHookean_ElasticEnergy() {
this->eNergy = this->t_C(i, i);
this->eNergy = 0.5 * this->mu * (this->eNergy - 3);
logJ = log(sqrt(this->J * this->J));
this->eNergy += -this->mu * logJ + 0.5 * this->lambda * pow(logJ, 2);
}
MoFEMErrorCode calculateElasticEnergy(
boost::shared_ptr<const NumeredEntFiniteElement> fe_ptr) {
this->lambda = LAMBDA(block_data.E, block_data.PoissonRatio);
this->mu = MU(block_data.E, block_data.PoissonRatio);
this->J = determinantTensor3by3(this->F);
}
};
#endif
Kronecker Delta class.
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
#define MU(E, NU)
Definition fem_tools.h:23
#define LAMBDA(E, NU)
Definition fem_tools.h:22
constexpr auto t_kd
NeoHookan equation.
MoFEMErrorCode NeoHooke_PiolaKirchhoffII()
calculate second Piola Kirchhoff
MoFEMErrorCode NeoHookean_ElasticEnergy()
calculate elastic energy density
NonlinearElasticElement::FunctionsToCalculatePiolaKirchhoffI< TYPE > PiolaKirchoffI
MoFEMErrorCode calculateElasticEnergy(const NonlinearElasticElement::BlockData block_data, boost::shared_ptr< const NumeredEntFiniteElement > fe_ptr)
Calculate elastic energy density.
FTensor::Index< 'i', 3 > i
MatrixBoundedArray< TYPE, 9 > invC
virtual MoFEMErrorCode calculateP_PiolaKirchhoffI(const NonlinearElasticElement::BlockData block_data, boost::shared_ptr< const NumeredEntFiniteElement > fe_ptr)
Function overload to implement user material.
FTensor::Index< 'j', 3 > j
FTensor::Index< 'k', 3 > k
FTensor::Tensor2< FTensor::PackPtr< TYPE *, 0 >, 3, 3 > t_invC
data for calculation heat conductivity and heat capacity elements
Implementation of elastic (non-linear) St. Kirchhoff equation.
FTensor::Tensor2< FTensor::PackPtr< TYPE *, 0 >, 3, 3 > t_C
FTensor::Tensor2< FTensor::PackPtr< TYPE *, 0 >, 3, 3 > t_F
FTensor::Tensor2< FTensor::PackPtr< TYPE *, 0 >, 3, 3 > t_P
FTensor::Tensor2< FTensor::PackPtr< TYPE *, 0 >, 3, 3 > t_S