SOFA API  fbf4278d
Open source framework for multi-physics simuation
sofa::component::solidmechanics::fem::elastic Namespace Reference

Namespaces

 detail
 

Classes

class  BaseElementLinearFEMForceField
 
struct  _2DMaterials
 
struct  _3DMaterials
 
class  BaseLinearElasticityFEMForceField
 
struct  RotationMethods
 A container for rotation computation methods in corotational formulations. More...
 
struct  RotationMethods< Vec3Real< Real >, sofa::geometry::Triangle >
 
struct  RotationMethods< DataTypes, sofa::geometry::Tetrahedron >
 
struct  RotationMethods< DataTypes, sofa::geometry::Hexahedron >
 
class  ElementCorotationalFEMForceField
 
class  ElementLinearSmallStrainFEMForceField
 
class  FastTetrahedralCorotationalForceField
 
class  FastTetrahedralCorotationalForceFieldData
 This class can be overridden if needed for additional storage within template specializations. More...
 
class  FEMForceField
 
class  HexahedralFEMForceField
 
class  HexahedralFEMForceFieldAndMass
 
class  HexahedronFEMForceField
 
class  HexahedronFEMForceFieldInternalData
 
class  HexahedronFEMForceFieldAndMass
 
struct  FactorizedElementStiffness
 
class  OrthotropicElasticityTensor
 Represents an elasticity tensor for orthotropic materials. More...
 
class  HexahedronRotation
 Computes the orientation matrix for 8-node hexahedral elements. More...
 
struct  IdentityRotation
 
struct  PolarDecomposition
 
class  RotationMethodsContainer
 A container for rotation computation methods in corotational formulations. More...
 
struct  StablePolarDecomposition
 
struct  TriangleRotation
 
struct  StrainDisplacement
 
struct  trait
 
class  QuadBendingFEMForceField
 
class  TetrahedralCorotationalFEMForceField
 
class  TetrahedronFEMForceField
 
class  TetrahedronFEMForceFieldInternalData
 This class can be overridden if needed for additional storage within template specializations. More...
 
class  TriangleFEMForceField
 
class  TriangleFEMUtils
 
class  TriangularAnisotropicFEMForceField
 
class  TriangularFEMForceField
 
class  TriangularFEMForceFieldOptim
 
class  TriangularFEMForceFieldOptimInternalData
 This class can be overridden if needed for additional storage within template specializations. More...
 

Typedefs

template<class Real >
using Vec3Real = sofa::defaulttype::StdVectorTypes< sofa::type::Vec< 3, Real >, sofa::type::Vec< 3, Real >, Real >
 
template<class real >
using YoungModulus = sofa::type::StrongType< real, struct YoungModulusTag, sofa::type::functionality::Arithmetic >
 
template<class real >
using PoissonRatio = sofa::type::StrongType< real, struct PoissonRatioTag, sofa::type::functionality::Arithmetic >
 
template<class real >
using LameLambda = sofa::type::StrongType< real, struct LameLambdaTag, sofa::type::functionality::Arithmetic >
 
template<class real >
using LameMu = sofa::type::StrongType< real, struct LameMuTag, sofa::type::functionality::Arithmetic >
 

Enumerations

enum class  MatrixVectorProductType { Factorization , Dense }
 

Functions

void registerBeamFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerElementCorotationalFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerElementLinearSmallStrainFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerFastTetrahedralCorotationalForceField (sofa::core::ObjectFactory *factory)
 
void registerHexahedralFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerHexahedralFEMForceFieldAndMass (sofa::core::ObjectFactory *factory)
 
void registerHexahedronFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerHexahedronFEMForceFieldAndMass (sofa::core::ObjectFactory *factory)
 
 MAKE_SELECTABLE_ITEMS (ComputeStrategy, sofa::helper::Item{parallelComputeStrategy, "The algorithm is executed in parallel"}, sofa::helper::Item{sequencedComputeStrategy, "The algorithm is executed sequentially"},)
 
template<class DataTypes , class ElementType , MatrixVectorProductType matrixVectorProductType = MatrixVectorProductType::Dense>
FactorizedElementStiffness< DataTypes, ElementType, matrixVectorProductType > integrate (const std::array< sofa::Coord_t< DataTypes >, ElementType::NumberOfNodes > &nodesCoordinates, const sofa::type::FullySymmetric4Tensor< DataTypes::spatial_dimensions, sofa::Real_t< DataTypes >> &elasticityTensor)
 
template<std::size_t spatial_dimensions, class real >
void toLameParameters (YoungModulus< real > youngModulus, PoissonRatio< real > poissonRatio, LameLambda< real > &lambda, LameMu< real > &mu)
 Converts Young's modulus and Poisson's ratio to Lamé parameters. More...
 
template<sofa::Size D, class real >
auto makeIsotropicElasticityTensor (LameMu< real > mu, LameLambda< real > lambda)
 Creates an isotropic elasticity tensor for given material properties. More...
 
template<sofa::Size N, class real >
constexpr sofa::type::Vec< N, real > orthotropicElasticityTensorProduct (const sofa::type::Mat< N, N, real > &tensor, const sofa::type::Vec< N, real > &v)
 
template<class real >
constexpr sofa::type::Vec< 6, real > orthotropicElasticityTensorProduct (const sofa::type::Mat< 6, 6, real > &tensor, const sofa::type::Vec< 6, real > &v)
 
template<class StrainDisplacement >
sofa::type::Vec< StrainDisplacement::nbLines, typename StrainDisplacement::RealstrainDisplacementVectorProduct (const StrainDisplacement &B, const sofa::type::Vec< StrainDisplacement::nbColumns, typename StrainDisplacement::Real > &v)
 
template<class StrainDisplacement >
sofa::type::Vec< StrainDisplacement::nbColumns, typename StrainDisplacement::RealstrainDisplacementTransposedVectorProduct (const StrainDisplacement &B, const sofa::type::Vec< StrainDisplacement::nbLines, typename StrainDisplacement::Real > &v)
 
template<sofa::Size L, sofa::Size C, class real , class DataTypes , class ElementType >
sofa::type::Mat< L, StrainDisplacement< DataTypes, ElementType >::nbColumns, real > operator* (const sofa::type::Mat< L, C, real > &A, const StrainDisplacement< DataTypes, ElementType > &B)
 
template<class DataTypes , class ElementType >
StrainDisplacement< DataTypes, ElementType > makeStrainDisplacement (const sofa::type::Mat< ElementType::NumberOfNodes, DataTypes::spatial_dimensions, sofa::Real_t< DataTypes > > &gradientShapeFunctions)
 
template<class ElementType , class VecCoord >
auto extractRefNodesVectorFromGlobalVector (const sofa::topology::Element< ElementType > &element, const VecCoord &vector)
 
template<class ElementType , class VecCoord >
std::array< typename VecCoord::value_type, ElementType::NumberOfNodes > extractNodesVectorFromGlobalVector (const sofa::topology::Element< ElementType > &element, const VecCoord &vector)
 
void registerQuadBendingFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTetrahedralCorotationalFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTetrahedronFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTriangleFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTriangularAnisotropicFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTriangularFEMForceField (sofa::core::ObjectFactory *factory)
 
void registerTriangularFEMForceFieldOptim (sofa::core::ObjectFactory *factory)
 
SOFA_EXPORT_DYNAMIC_LIBRARY void initExternalModule ()
 
SOFA_EXPORT_DYNAMIC_LIBRARY const chargetModuleName ()
 
SOFA_EXPORT_DYNAMIC_LIBRARY const chargetModuleVersion ()
 
SOFA_EXPORT_DYNAMIC_LIBRARY void registerObjects (sofa::core::ObjectFactory *factory)
 
void init ()
 

Variables

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API FastTetrahedralCorotationalForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API HexahedralFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API HexahedralFEMForceFieldAndMass< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API HexahedronFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API HexahedronFEMForceFieldAndMass< Vec3Types >
 
constexpr std::string_view parallelComputeStrategy = "parallel"
 
constexpr std::string_view sequencedComputeStrategy = "sequenced"
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API QuadBendingFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TetrahedralCorotationalFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TetrahedronFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TriangleFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TriangularAnisotropicFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TriangularFEMForceField< Vec3Types >
 
template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API TriangularFEMForceFieldOptim< Vec3Types >
 

Typedef Documentation

◆ LameLambda

◆ LameMu

◆ PoissonRatio

◆ Vec3Real

◆ YoungModulus

Enumeration Type Documentation

◆ MatrixVectorProductType

Specifies the type of matrix-vector product to be used with the stiffness matrix.

Enumerator
Factorization 

The matrix-vector product is computed using the factorization of the matrix

Dense 

The matrix-vector product is computed using the dense matrix representation

Function Documentation

◆ extractNodesVectorFromGlobalVector()

template<class ElementType , class VecCoord >
std::array<typename VecCoord::value_type, ElementType::NumberOfNodes> sofa::component::solidmechanics::fem::elastic::extractNodesVectorFromGlobalVector ( const sofa::topology::Element< ElementType > &  element,
const VecCoord &  vector 
)

◆ extractRefNodesVectorFromGlobalVector()

template<class ElementType , class VecCoord >
auto sofa::component::solidmechanics::fem::elastic::extractRefNodesVectorFromGlobalVector ( const sofa::topology::Element< ElementType > &  element,
const VecCoord &  vector 
)

◆ getModuleName()

const char * sofa::component::solidmechanics::fem::elastic::getModuleName ( )

◆ getModuleVersion()

const char * sofa::component::solidmechanics::fem::elastic::getModuleVersion ( )

◆ init()

SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API void sofa::component::solidmechanics::fem::elastic::init ( )

◆ initExternalModule()

void sofa::component::solidmechanics::fem::elastic::initExternalModule ( )

◆ integrate()

template<class DataTypes , class ElementType , MatrixVectorProductType matrixVectorProductType = MatrixVectorProductType::Dense>
FactorizedElementStiffness<DataTypes, ElementType, matrixVectorProductType> sofa::component::solidmechanics::fem::elastic::integrate ( const std::array< sofa::Coord_t< DataTypes >, ElementType::NumberOfNodes > &  nodesCoordinates,
const sofa::type::FullySymmetric4Tensor< DataTypes::spatial_dimensions, sofa::Real_t< DataTypes >> &  elasticityTensor 
)

◆ MAKE_SELECTABLE_ITEMS()

sofa::component::solidmechanics::fem::elastic::MAKE_SELECTABLE_ITEMS ( ComputeStrategy  ,
sofa::helper::Item{parallelComputeStrategy, "The algorithm is executed in parallel"}  ,
sofa::helper::Item{sequencedComputeStrategy, "The algorithm is executed sequentially"}   
)

◆ makeIsotropicElasticityTensor()

template<sofa::Size D, class real >
auto sofa::component::solidmechanics::fem::elastic::makeIsotropicElasticityTensor ( LameMu< real >  mu,
LameLambda< real >  lambda 
)

Creates an isotropic elasticity tensor for given material properties.

This function constructs and returns an elasticity tensor for an isotropic material characterized by its Young's modulus and Poisson's ratio. It computes the tensor using the Lamé parameters, which are derived from the given material properties.

Parameters
muLamé's first parameter
lambdaLamé's second parameter
Returns
The isotropic elasticity tensor

◆ makeStrainDisplacement()

template<class DataTypes , class ElementType >
StrainDisplacement<DataTypes, ElementType> sofa::component::solidmechanics::fem::elastic::makeStrainDisplacement ( const sofa::type::Mat< ElementType::NumberOfNodes, DataTypes::spatial_dimensions, sofa::Real_t< DataTypes > > &  gradientShapeFunctions)

Creates a strain-displacement matrix (B-matrix) for finite element calculations.

This function constructs a strain-displacement matrix based on the provided gradient of shape functions. The matrix is filled according to spatial dimensions and the number of nodes in the element.

Parameters
gradientShapeFunctionsA matrix containing the gradient of the shape functions.
Returns
A strain-displacement matrix of type StrainDisplacement<DataTypes, ElementType>, constructed for the finite element with the given gradient shape functions.

◆ operator*()

template<sofa::Size L, sofa::Size C, class real , class DataTypes , class ElementType >
sofa::type::Mat<L, StrainDisplacement<DataTypes, ElementType>::nbColumns, real> sofa::component::solidmechanics::fem::elastic::operator* ( const sofa::type::Mat< L, C, real > &  A,
const StrainDisplacement< DataTypes, ElementType > &  B 
)

Multiplies a matrix by a strain-displacement matrix.

Template Parameters
LNumber of lines in matrix A.
CNumber of columns in matrix A (must match nbLines of B).
Parameters
AMatrix to multiply with B.
BStrain-displacement matrix.
Returns
Resulting matrix product A * B.

◆ orthotropicElasticityTensorProduct() [1/2]

template<class real >
constexpr sofa::type::Vec<6, real> sofa::component::solidmechanics::fem::elastic::orthotropicElasticityTensorProduct ( const sofa::type::Mat< 6, 6, real > &  tensor,
const sofa::type::Vec< 6, real > &  v 
)
constexpr

Specialization for 3D where the operations containing known zeros in the elasticity tensor are omitted.

WARNING: this specialization is only valid for a give Voigt index mapping. If this mapping happens to change, this specialization will need to be updated accordingly.

◆ orthotropicElasticityTensorProduct() [2/2]

template<sofa::Size N, class real >
constexpr sofa::type::Vec<N, real> sofa::component::solidmechanics::fem::elastic::orthotropicElasticityTensorProduct ( const sofa::type::Mat< N, N, real > &  tensor,
const sofa::type::Vec< N, real > &  v 
)
constexpr

◆ registerBeamFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerBeamFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerElementCorotationalFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerElementCorotationalFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerElementLinearSmallStrainFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerElementLinearSmallStrainFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerFastTetrahedralCorotationalForceField()

void sofa::component::solidmechanics::fem::elastic::registerFastTetrahedralCorotationalForceField ( sofa::core::ObjectFactory factory)

◆ registerHexahedralFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerHexahedralFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerHexahedralFEMForceFieldAndMass()

void sofa::component::solidmechanics::fem::elastic::registerHexahedralFEMForceFieldAndMass ( sofa::core::ObjectFactory factory)

◆ registerHexahedronFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerHexahedronFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerHexahedronFEMForceFieldAndMass()

void sofa::component::solidmechanics::fem::elastic::registerHexahedronFEMForceFieldAndMass ( sofa::core::ObjectFactory factory)

◆ registerObjects()

void sofa::component::solidmechanics::fem::elastic::registerObjects ( sofa::core::ObjectFactory factory)

◆ registerQuadBendingFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerQuadBendingFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTetrahedralCorotationalFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerTetrahedralCorotationalFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTetrahedronFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerTetrahedronFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTriangleFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerTriangleFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTriangularAnisotropicFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerTriangularAnisotropicFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTriangularFEMForceField()

void sofa::component::solidmechanics::fem::elastic::registerTriangularFEMForceField ( sofa::core::ObjectFactory factory)

◆ registerTriangularFEMForceFieldOptim()

void sofa::component::solidmechanics::fem::elastic::registerTriangularFEMForceFieldOptim ( sofa::core::ObjectFactory factory)

◆ strainDisplacementTransposedVectorProduct()

template<class StrainDisplacement >
sofa::type::Vec<StrainDisplacement::nbColumns, typename StrainDisplacement::Real> sofa::component::solidmechanics::fem::elastic::strainDisplacementTransposedVectorProduct ( const StrainDisplacement B,
const sofa::type::Vec< StrainDisplacement::nbLines, typename StrainDisplacement::Real > &  v 
)

Computes the product between the transpose of a strain-displacement matrix B and a strain vector v.

This function calculates the nodal force vector f = B^T * v where v is a strain (or stress) vector in Voigt notation.

Template Parameters
StrainDisplacementThe type of the strain-displacement matrix.
Parameters
BThe strain-displacement matrix.
vThe vector to be multiplied by the transpose of B.
Returns
The resulting vector (typically nodal forces).

◆ strainDisplacementVectorProduct()

template<class StrainDisplacement >
sofa::type::Vec<StrainDisplacement::nbLines, typename StrainDisplacement::Real> sofa::component::solidmechanics::fem::elastic::strainDisplacementVectorProduct ( const StrainDisplacement B,
const sofa::type::Vec< StrainDisplacement::nbColumns, typename StrainDisplacement::Real > &  v 
)

Computes the product between a strain-displacement matrix B and a displacement vector v.

This function calculates the strain vector ε = B * v where B is represented in Voigt notation. For diagonal terms (normal strains), it performs a simple dot product. For off-diagonal terms (shear strains), it sums the contributions from both partial derivatives.

Template Parameters
StrainDisplacementThe type of the strain-displacement matrix.
Parameters
BThe strain-displacement matrix.
vThe displacement vector.
Returns
The strain vector in Voigt notation.

◆ toLameParameters()

template<std::size_t spatial_dimensions, class real >
void sofa::component::solidmechanics::fem::elastic::toLameParameters ( YoungModulus< real >  youngModulus,
PoissonRatio< real >  poissonRatio,
LameLambda< real > &  lambda,
LameMu< real > &  mu 
)

Converts Young's modulus and Poisson's ratio to Lamé parameters.

This function calculates and returns the two Lamé parameters, μ (shear modulus) and λ, derived from the given Young’s modulus and Poisson’s ratio of a material. These parameters are fundamental in describing isotropic elastic behavior.

Parameters
youngModulusThe Young's modulus of the material, representing its stiffness.
poissonRatioThe Poisson's ratio of the material, describing its deformation behavior.
Returns
A pair containing the calculated Lamé parameters:
  • First: μ (shear modulus),
  • Second: λ.

Variable Documentation

◆ FastTetrahedralCorotationalForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::FastTetrahedralCorotationalForceField< Vec3Types >

◆ HexahedralFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::HexahedralFEMForceField< Vec3Types >

◆ HexahedralFEMForceFieldAndMass< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::HexahedralFEMForceFieldAndMass< Vec3Types >

◆ HexahedronFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::HexahedronFEMForceField< Vec3Types >

◆ HexahedronFEMForceFieldAndMass< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::HexahedronFEMForceFieldAndMass< Vec3Types >

◆ parallelComputeStrategy

constexpr std::string_view sofa::component::solidmechanics::fem::elastic::parallelComputeStrategy = "parallel"
constexpr

◆ QuadBendingFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::QuadBendingFEMForceField< Vec3Types >

◆ sequencedComputeStrategy

constexpr std::string_view sofa::component::solidmechanics::fem::elastic::sequencedComputeStrategy = "sequenced"
constexpr

◆ TetrahedralCorotationalFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TetrahedralCorotationalFEMForceField< Vec3Types >

◆ TetrahedronFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TetrahedronFEMForceField< Vec3Types >

◆ TriangleFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TriangleFEMForceField< Vec3Types >

◆ TriangularAnisotropicFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TriangularAnisotropicFEMForceField< Vec3Types >

◆ TriangularFEMForceField< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TriangularFEMForceField< Vec3Types >

◆ TriangularFEMForceFieldOptim< Vec3Types >

template class SOFA_COMPONENT_SOLIDMECHANICS_FEM_ELASTIC_API sofa::component::solidmechanics::fem::elastic::TriangularFEMForceFieldOptim< Vec3Types >