pulse.material package
Contents
pulse.material package¶
Submodules¶
pulse.material.active_model module¶
- class pulse.material.active_model.ActiveModel(activation=None, f0=None, s0=None, n0=None, model: pulse.material.active_model.ActiveModels = ActiveModels.active_strain, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, eta: Optional[float] = None, T_ref: Optional[float] = None, isochoric=True)¶
Bases:
object
- property Fa¶
- Fe(F)¶
- Wactive(F=None, diff=0)¶
Active stress energy
- property activation¶
Return the activation paramter. If regional, this will return one parameter for each segment.
- property activation_field¶
Return the activation field. If regional, this will return a piecewise constant function (DG_0)
- property dim¶
- class pulse.material.active_model.ActiveModels(value)¶
Bases:
str
,enum.Enum
An enumeration.
- active_strain = 'active_strain'¶
- active_stress = 'active_stress'¶
- class pulse.material.active_model.ActiveStressModels(value)¶
Bases:
str
,enum.Enum
An enumeration.
- fully_anisotropic = 'fully_anisotropic'¶
- orthotropic = 'orthotropic'¶
- transversally = 'transversally'¶
- pulse.material.active_model.Wactive(Ta, C, f0, eta, active_isotropy=ActiveStressModels.transversally, s0=None, n0=None)¶
- pulse.material.active_model.Wactive_anisotropic(Ta, C, f0, s0, n0)¶
Return active strain energy for a fully anisotropic acitvation. Note that the three basis vectors are assumed to be orthogonal
- Parameters
Ta (dolfin.Function or dolfin.Constant) – A full tensor function representng the active stress tensor of the active stress in the reference configuration (firt Pioala).
C (ufl.Form) – The right Cauchy-Green deformation tensor
f0 (dolfin.Function) – A vector function representng the direction of the first component
s0 (dolfin.Function) – A vector function representng the direction of the second component
n0 (dolfin.Function) – A vector function representng the direction of the third component
- pulse.material.active_model.Wactive_orthotropic(Ta, C, f0, s0, n0)¶
Return active strain energy for an orthotropic active stress
- Parameters
Ta (dolfin.Function or dolfin.Constant) – A vector function representng the mangnitude of the active stress in the reference configuration (firt Pioala). Ta = (Ta_f0, Ta_s0, Ta_n0)
C (ufl.Form) – The right Cauchy-Green deformation tensor
f0 (dolfin.Function) – A vector function representng the direction of the first component
s0 (dolfin.Function) – A vector function representng the direction of the second component
n0 (dolfin.Function) – A vector function representng the direction of the third component
- pulse.material.active_model.Wactive_transversally(Ta, C, f0, eta=0.0)¶
Return active strain energy when activation is only working along the fibers, with a possible transverse component defined by eta
- Parameters
Ta (dolfin.Function or dolfin.Constant) – A scalar function representng the mangnitude of the active stress in the reference configuration (firt Pioala)
C (ufl.Form) – The right Cauchy-Green deformation tensor
f0 (dolfin.Function) – A vector function representng the direction of the active stress
eta (float) – Amount of active stress in the transverse direction (relative to f0)
pulse.material.guccione module¶
- class pulse.material.guccione.Guccione(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Guccione material model.
- SecondPiolaStress(F, p, *args, **kwargs)¶
- static default_parameters()¶
- is_isotropic()¶
Return True if the material is isotropic.
- name = 'guccione'¶
- strain_energy(F_)¶
UFL form of the strain energy.
pulse.material.holzapfelogden module¶
- class pulse.material.holzapfelogden.HolzapfelOgden(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Orthotropic model by Holzapfel and Ogden
\[\mathcal{W}(I_1, I_{4f_0}) = \frac{a}{2 b} \left( e^{ b (I_1 - 3)} -1 \right) + \frac{a_f}{2 b_f} \left( e^{ b_f (I_{4f_0} - 1)_+^2} -1 \right) + \frac{a_s}{2 b_s} \left( e^{ b_s (I_{4s_0} - 1)_+^2} -1 \right) + \frac{a_fs}{2 b_fs} \left( e^{ b_fs I_{8fs}^2} -1 \right)\]where
\[(\cdot)_+ = \max\{x,0\}\]Reference
[1] Holzapfel, Gerhard A., and Ray W. Ogden. “Constitutive modelling of passive myocardium: a structurally based framework for material characterization. “Philosophical Transactions of the Royal Society of London A: Mathematical, Physical and Engineering Sciences 367.1902 (2009): 3445-3475.
- W_1(I1, diff=0, *args, **kwargs)¶
Isotropic contribution.
If diff = 0, return
\[\frac{a}{2 b} \left( e^{ b (I_1 - 3)} -1 \right)\]If diff = 1, return
\[\frac{a}{b} e^{ b (I_1 - 3)}\]If diff = 2, return
\[\frac{a b}{2} e^{ b (I_1 - 3)}\]
- W_4(I4, direction, diff=0, use_heaviside=False, *args, **kwargs)¶
Anisotropic contribution.
If diff = 0, return
\[\frac{a_f}{2 b_f} \left( e^{ b_f (I_{4f_0} - 1)_+^2} -1 \right)\]If diff = 1, return
\[a_f (I_{4f_0} - 1)_+ e^{ b_f (I_{4f_0} - 1)^2}\]If diff = 2, return
\[a_f h(I_{4f_0} - 1) (1 + 2b(I_{4f_0} - 1)) e^{ b_f (I_{4f_0} - 1)_+^2}\]where
\[h(x) = \frac{\mathrm{d}}{\mathrm{d}x} \max\{x,0\}\]is the Heaviside function.
- W_8(I8, *args, **kwargs)¶
Cross fiber-sheet contribution.
- static default_parameters()¶
Default matereial parameter for the Holzapfel Ogden model
Taken from Table 1 row 3 of [1]
- name = 'holzapfel_ogden'¶
- strain_energy(F)¶
Strain-energy density function.
\[\mathcal{W} = \mathcal{W}_1 + \mathcal{W}_{4f} + \mathcal{W}_{\mathrm{active}}\]where
\[\begin{split}\mathcal{W}_{\mathrm{active}} = \begin{cases} 0 & \text{if acitve strain} \\ \gamma I_{4f} & \text{if active stress} \end{cases}\end{split}\]- Parameters
F (
dolfin.Function
) – Deformation gradient
pulse.material.linearelastic module¶
- class pulse.material.linearelastic.LinearElastic(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for linear elastic material
- static default_parameters()¶
- name = 'linear_elastic'¶
- strain_energy(F_)¶
pulse.material.material_model module¶
- class pulse.material.material_model.Material(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
abc.ABC
Initialize material model
- Parameters
f0 (:py:class`dolfin.Function`) – Fiber field
gamma (:py:class`dolfin.Function`) – Activation parameter
params (dict) – Material parameters
active_model (str) – Active model - active strain or active stress
s0 (:py:class`dolfin.Function`) – Sheets
n0 (:py:class`dolfin.Function`) – Sheet - normal
T_ref (float) – Scale factor for activation parameter (default = 1.0)
dev_iso_split (bool) – Decouple deformation into deviatoric and isochoric deformations
eta (float) – Fraction of transverse active tesion for active stress formulation. 0 = active only along fiber, 1 = equal forces in all directions (default=0.0).
- CauchyStress(F, p=None, deviatoric=False)¶
- property Fa¶
- Fe(F)¶
- FirstPiolaStress(F, p=None, *args, **kwargs)¶
- SecondPiolaStress(F, p=None, deviatoric=False, *args, **kwargs)¶
- property T_ref¶
- Wactive(F=None, diff=0)¶
Active stress energy
- property activation¶
Return the activation paramter. If regional, this will return one parameter for each segment.
- property activation_field¶
Return the activation field. If regional, this will return a piecewise constant function (DG_0)
- property active_model¶
- compressibility(p, J)¶
- copy(geometry=None)¶
- abstract static default_parameters()¶
- property eta¶
- property f0¶
- property isochoric¶
- property material_model¶
- property n0¶
- property name¶
- property s0¶
- abstract strain_energy(F)¶
- update_geometry(geometry)¶
- pulse.material.material_model.compressibility(model, *args, **kwargs)¶
- pulse.material.material_model.incompressible(p, J)¶
pulse.material.neohookean module¶
- class pulse.material.neohookean.NeoHookean(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for Neo Hookean material
- W_1(I_1, diff=0, dim=3, *args, **kwargs)¶
- static default_parameters()¶
- name = 'neo_hookean'¶
- strain_energy(F)¶
Strain-energy density function.
\[\mathcal{W} = \mathcal{W}_1 + \mathcal{W}_{4f} + \mathcal{W}_{\mathrm{active}}\]where
\[\begin{split}\mathcal{W}_{\mathrm{active}} = \begin{cases} 0 & \text{if acitve strain} \\ \gamma I_{4f} & \text{if active stress} \end{cases}\end{split}\]- Parameters
F (
dolfin.Function
) – Deformation gradient
pulse.material.stvenantkirchhoff module¶
- class pulse.material.stvenantkirchhoff.StVenantKirchhoff(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for linear elastic material
- static default_parameters()¶
- name = 'saint_venant_kirchhoff'¶
- strain_energy(F_)¶
Module contents¶
- class pulse.material.ActiveModel(activation=None, f0=None, s0=None, n0=None, model: pulse.material.active_model.ActiveModels = ActiveModels.active_strain, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, eta: Optional[float] = None, T_ref: Optional[float] = None, isochoric=True)¶
Bases:
object
- property Fa¶
- Fe(F)¶
- Wactive(F=None, diff=0)¶
Active stress energy
- property activation¶
Return the activation paramter. If regional, this will return one parameter for each segment.
- property activation_field¶
Return the activation field. If regional, this will return a piecewise constant function (DG_0)
- property dim¶
- class pulse.material.ActiveModels(value)¶
Bases:
str
,enum.Enum
An enumeration.
- active_strain = 'active_strain'¶
- active_stress = 'active_stress'¶
- class pulse.material.Guccione(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Guccione material model.
- SecondPiolaStress(F, p, *args, **kwargs)¶
- static default_parameters()¶
- is_isotropic()¶
Return True if the material is isotropic.
- name = 'guccione'¶
- strain_energy(F_)¶
UFL form of the strain energy.
- class pulse.material.HolzapfelOgden(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Orthotropic model by Holzapfel and Ogden
\[\mathcal{W}(I_1, I_{4f_0}) = \frac{a}{2 b} \left( e^{ b (I_1 - 3)} -1 \right) + \frac{a_f}{2 b_f} \left( e^{ b_f (I_{4f_0} - 1)_+^2} -1 \right) + \frac{a_s}{2 b_s} \left( e^{ b_s (I_{4s_0} - 1)_+^2} -1 \right) + \frac{a_fs}{2 b_fs} \left( e^{ b_fs I_{8fs}^2} -1 \right)\]where
\[(\cdot)_+ = \max\{x,0\}\]Reference
[1] Holzapfel, Gerhard A., and Ray W. Ogden. “Constitutive modelling of passive myocardium: a structurally based framework for material characterization. “Philosophical Transactions of the Royal Society of London A: Mathematical, Physical and Engineering Sciences 367.1902 (2009): 3445-3475.
- W_1(I1, diff=0, *args, **kwargs)¶
Isotropic contribution.
If diff = 0, return
\[\frac{a}{2 b} \left( e^{ b (I_1 - 3)} -1 \right)\]If diff = 1, return
\[\frac{a}{b} e^{ b (I_1 - 3)}\]If diff = 2, return
\[\frac{a b}{2} e^{ b (I_1 - 3)}\]
- W_4(I4, direction, diff=0, use_heaviside=False, *args, **kwargs)¶
Anisotropic contribution.
If diff = 0, return
\[\frac{a_f}{2 b_f} \left( e^{ b_f (I_{4f_0} - 1)_+^2} -1 \right)\]If diff = 1, return
\[a_f (I_{4f_0} - 1)_+ e^{ b_f (I_{4f_0} - 1)^2}\]If diff = 2, return
\[a_f h(I_{4f_0} - 1) (1 + 2b(I_{4f_0} - 1)) e^{ b_f (I_{4f_0} - 1)_+^2}\]where
\[h(x) = \frac{\mathrm{d}}{\mathrm{d}x} \max\{x,0\}\]is the Heaviside function.
- W_8(I8, *args, **kwargs)¶
Cross fiber-sheet contribution.
- static default_parameters()¶
Default matereial parameter for the Holzapfel Ogden model
Taken from Table 1 row 3 of [1]
- name = 'holzapfel_ogden'¶
- strain_energy(F)¶
Strain-energy density function.
\[\mathcal{W} = \mathcal{W}_1 + \mathcal{W}_{4f} + \mathcal{W}_{\mathrm{active}}\]where
\[\begin{split}\mathcal{W}_{\mathrm{active}} = \begin{cases} 0 & \text{if acitve strain} \\ \gamma I_{4f} & \text{if active stress} \end{cases}\end{split}\]- Parameters
F (
dolfin.Function
) – Deformation gradient
- class pulse.material.LinearElastic(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for linear elastic material
- static default_parameters()¶
- name = 'linear_elastic'¶
- strain_energy(F_)¶
- class pulse.material.Material(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
abc.ABC
Initialize material model
- Parameters
f0 (:py:class`dolfin.Function`) – Fiber field
gamma (:py:class`dolfin.Function`) – Activation parameter
params (dict) – Material parameters
active_model (str) – Active model - active strain or active stress
s0 (:py:class`dolfin.Function`) – Sheets
n0 (:py:class`dolfin.Function`) – Sheet - normal
T_ref (float) – Scale factor for activation parameter (default = 1.0)
dev_iso_split (bool) – Decouple deformation into deviatoric and isochoric deformations
eta (float) – Fraction of transverse active tesion for active stress formulation. 0 = active only along fiber, 1 = equal forces in all directions (default=0.0).
- CauchyStress(F, p=None, deviatoric=False)¶
- property Fa¶
- Fe(F)¶
- FirstPiolaStress(F, p=None, *args, **kwargs)¶
- SecondPiolaStress(F, p=None, deviatoric=False, *args, **kwargs)¶
- property T_ref¶
- Wactive(F=None, diff=0)¶
Active stress energy
- property activation¶
Return the activation paramter. If regional, this will return one parameter for each segment.
- property activation_field¶
Return the activation field. If regional, this will return a piecewise constant function (DG_0)
- property active_model¶
- compressibility(p, J)¶
- copy(geometry=None)¶
- abstract static default_parameters()¶
- property eta¶
- property f0¶
- property isochoric¶
- property material_model¶
- property n0¶
- property name¶
- property s0¶
- abstract strain_energy(F)¶
- update_geometry(geometry)¶
- class pulse.material.NeoHookean(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for Neo Hookean material
- W_1(I_1, diff=0, dim=3, *args, **kwargs)¶
- static default_parameters()¶
- name = 'neo_hookean'¶
- strain_energy(F)¶
Strain-energy density function.
\[\mathcal{W} = \mathcal{W}_1 + \mathcal{W}_{4f} + \mathcal{W}_{\mathrm{active}}\]where
\[\begin{split}\mathcal{W}_{\mathrm{active}} = \begin{cases} 0 & \text{if acitve strain} \\ \gamma I_{4f} & \text{if active stress} \end{cases}\end{split}\]- Parameters
F (
dolfin.Function
) – Deformation gradient
- class pulse.material.StVenantKirchhoff(activation: Optional[ufl.coefficient.Coefficient] = None, parameters=None, active_model: Union[pulse.material.active_model.ActiveModel, pulse.material.active_model.ActiveModels] = ActiveModels.active_strain, T_ref: Optional[float] = None, eta: float = 0.0, isochoric: bool = True, compressible_model='incompressible', geometry=None, f0=None, s0=None, n0=None, active_isotropy: pulse.material.active_model.ActiveStressModels = ActiveStressModels.transversally, *args, **kwargs)¶
Bases:
pulse.material.material_model.Material
Class for linear elastic material
- static default_parameters()¶
- name = 'saint_venant_kirchhoff'¶
- strain_energy(F_)¶