API Reference#

kinematics#

invariants#

This module defines invariants of the deformation gradient.

The deformation gradient \(\mathbf{F}\) is a tensor field that describes the deformation of a material. The invariants of the deformation gradient are scalar quantities that are invariant under rigid body motion.

The invariants are defined as follows:

  • First principal invariant

    \(I_1 = \text{tr}(\mathbf{C})\)

  • Second principal invariant

    \(I_2 = \left( I_1^2 - \text{tr}(\mathbf{C}\cdot\mathbf{C})\right)\)

  • Third principal invariant

    \(I_3 = \text{det}(\mathbf{C})\)

  • Fourth quasi invariant

    \(I_{4\mathbf{a_0}} = \mathbf{C}\mathbf{a}_0 \cdot \mathbf{a}_0\)

  • Fifth quasi invariant

    \(I_{5\mathbf{a_0}} = \mathbf{C}\mathbf{a}_0 \cdot \mathbf{C}\mathbf{a}_0\)

  • Eight quasi invariant

    \(I_{8\mathbf{a_0}\mathbf{b_0}} = \mathbf{F}\mathbf{a}_0 \cdot \mathbf{F}\mathbf{b}_0\)

where \(\mathbf{C} = \mathbf{F}^T\mathbf{F}\) is the right Cauchy-Green tensor.

material_model#

This module defines the material model interface and some common material models.

The material model describes the mechanical behavior of a material. The material model is used to compute the stress tensor given the deformation gradient.

The material model interface defines two methods:

  • sigma(F): The Cauchy stress tensor

  • P(F): The first Piola-Kirchhoff stress tensor

The sigma method computes the Cauchy stress tensor given the deformation gradient. The P method computes the first Piola-Kirchhoff stress tensor given the deformation gradient.

The HyperElasticMaterial class is a base class for hyperelastic material models. Hyperelastic materials are materials that have a strain energy density function that depends only on the deformation gradient. The strain_energy method computes the strain energy density function given the deformation gradient.

active_model#

This module defines the ActiveModel class which is an abstract class for active models. Active models are used to incorporate active stress or active strain in the material model.

The ActiveModel class defines two methods:

  • Fe(F): Transforming the deformation gradient to an active deformation gradient

  • strain_energy(F): Active strain energy density function

The Fe method transforms the deformation gradient to an active deformation gradient. For example in the active strain approach we perform a multiplicative decomposition of the deformation gradient into an elastic and an active part, i.e

\[\mathbf{F} = \mathbf{F}_e \mathbf{F}_a\]

In which case the active model can be incorporated by transforming the full deformation gradient into a pure elastic component.

The strain_energy method defines the active strain energy density function. For example in the active stress approach, the active stress is added as an extra stress component

\[\mathbf{P} = \frac{\partial \Psi}{\partial \mathbf{F}} + \mathbf{P}_a\]

where \(\mathbf{P}_a\). Now we can instead rewrite this as a total strain energy by considering the following equation

\[\mathbf{P} = \frac{\partial \Psi}{\partial \mathbf{F}} = \frac{\partial \Psi_p}{\partial \mathbf{F}} + \frac{\partial \Psi_a}{\partial \mathbf{F}}\]

where \(\Psi_p\) is the passive (classical) strain energy density function and \(\Psi_a\) is the corresponding active strain energy density function.

The Passive class is a simple active model with no active component. This model could for example be used if you want to use a pure passive model.

This module contains the active stress model for the cardiac mechanics problem. The active stress model is used to describe the active contraction of the heart. The active stress model is used to compute the active stress given the deformation gradient.

compressibility#

This module defines compressibility models for the material models. We define two compressibility models: Incompressible and Compressible.

An incompressible material is a material that does not change its volume under deformation. The volume change is described by the Jacobian \(J = \det(F)\), where \(F\) is the deformation gradient.

The Incompressible model is defined by the strain energy density function \(\Psi = p (J - 1)\), where \(p\) is a function representing the Lagrange multiplier. The Compressible model is defined by the strain energy density function \(\Psi = \kappa (J \ln(J) - J + 1)\), where \(\kappa\) is a material parameter representing the bulk modulus. Higher values of \(\kappa\) correspond to more incompressible material.

viscoelasticity#

cardiac_model#

This module defines the cardiac model.

The cardiac model is a combination of a material model, an active model, and a compressibility model.

geometry#

problem#

boundary conditions#

This module defines boundary conditions.

Boundary conditions are used to specify the behavior of the solution on the boundary of the domain. The boundary conditions can be Dirichlet, Neumann, or Robin boundary conditions.

Dirichlet boundary conditions are used to specify the solution on the boundary of the domain. Neumann boundary conditions are used to specify the traction on the boundary of the domain. Robin boundary conditions are used to specify a Robin type boundary condition on the boundary of the domain.

The boundary conditions are collected in a BoundaryConditions object.

units#

utils#