Skip to main content

SoftTissue

Struct SoftTissue 

Source
pub struct SoftTissue {
    pub fung_c: f64,
    pub fung_b: [f64; 6],
    pub hgo_mu: f64,
    pub hgo_k1: f64,
    pub hgo_k2: f64,
    pub hgo_kappa: f64,
    pub fiber_angle: f64,
    pub active_stress: f64,
}
Expand description

Biomedical soft-tissue constitutive model.

Implements two hyperelastic frameworks commonly used in biomechanics:

  1. Fung exponential (quasi-linear viscoelastic): strain-energy W = C*(exp(Q) - 1) where Q is a quadratic form in the Green-Lagrange strain components.
  2. Holzapfel-Gasser-Ogden (HGO): fiber-reinforced model for arterial walls, with an isotropic neo-Hookean matrix and two fiber families.
  3. Active stress: additive active-passive decomposition for cardiac muscle.

Fields§

§fung_c: f64

Material parameter C [Pa] for the Fung model ground-matrix stiffness.

§fung_b: [f64; 6]

Fung exponential coefficients [b11, b22, b33, b12, b13, b23] (dimensionless).

§hgo_mu: f64

HGO: neo-Hookean ground-matrix parameter μ [Pa].

§hgo_k1: f64

HGO: fiber stiffness k1 [Pa].

§hgo_k2: f64

HGO: fiber exponential nonlinearity k2 (dimensionless).

§hgo_kappa: f64

HGO: fiber dispersion parameter κ ∈ [0, 1/3].

§fiber_angle: f64

HGO: mean fiber angle θ [rad] relative to the circumferential direction.

§active_stress: f64

Active stress magnitude [Pa] (cardiac muscle).

Implementations§

Source§

impl SoftTissue

Source

pub fn new_fung(fung_c: f64, fung_b: [f64; 6]) -> Self

Construct a new SoftTissue with Fung parameters.

§Arguments
  • fung_c – Ground-matrix stiffness [Pa].
  • fung_b – Exponential coefficients [b11, b22, b33, b12, b13, b23].
Source

pub fn new_hgo(mu: f64, k1: f64, k2: f64, kappa: f64, fiber_angle: f64) -> Self

Construct a new SoftTissue with HGO (fiber-reinforced) parameters.

§Arguments
  • mu – Neo-Hookean ground-matrix shear modulus [Pa].
  • k1 – Fiber stiffness parameter [Pa].
  • k2 – Fiber nonlinearity (dimensionless).
  • kappa – Fiber dispersion parameter ∈ [0, 1/3].
  • fiber_angle – Mean fiber angle relative to circumferential axis [rad].
Source

pub fn fung_strain_energy(&self, strain: &StrainTensor) -> f64

Compute the Fung strain-energy density W [J/m³].

§Formula

W = C * (exp(Q) – 1) where Q = Σ b_ij * E_i * E_j.

Source

pub fn fung_stress_s11(&self, strain: &StrainTensor) -> f64

Compute Fung second Piola-Kirchhoff stress S11 in the 1-direction [Pa].

Computed as ∂W/∂E11 = 2C * (b11*E11 + b12*E22 + b13*E33) * exp(Q).

Source

pub fn hgo_i4(&self, stretch_circ: f64, stretch_axial: f64) -> f64

Compute HGO fiber pseudo-invariant I4 for one fiber family.

I4 = λ_f² = C : (a ⊗ a) where a is the fiber direction unit vector. Returns the stretch squared along the fiber.

Source

pub fn hgo_fiber_energy( &self, stretch_circ: f64, stretch_axial: f64, stretch_radial: f64, ) -> f64

Compute HGO fiber strain-energy density [J/m³].

W_fiber = k1/(2k2) * Σ (exp(k2*(κ*I1 + (1-3κ)*I4 - 1)²) - 1) Only contributes when fibers are under tension (I4 > 1).

Source

pub fn hgo_total_energy( &self, stretch_circ: f64, stretch_axial: f64, stretch_radial: f64, ) -> f64

Compute total HGO strain energy including isotropic neo-Hookean matrix [J/m³].

Source

pub fn total_stress_with_active(&self, strain: &StrainTensor) -> f64

Compute total stress including passive hyperelastic and active components.

Returns Cauchy stress σ_11 in the fiber direction.

Source

pub fn set_active_stress(&mut self, sigma_a: f64)

Set the active stress magnitude (for cardiac simulation).

Trait Implementations§

Source§

impl Clone for SoftTissue

Source§

fn clone(&self) -> SoftTissue

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for SoftTissue

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.