SuperDex Physics C++ API
Loading...
Searching...
No Matches
superdex::SoftMaterialParams Struct Reference

Material parameters for soft body simulation. More...

#include <material_params.h>

Public Member Functions

bool operator== (SoftMaterialParams const &) const =default

Public Attributes

ActiveNeoHookeanMaterialParams activeNeoHookean = {}
 Parameters for the Active Neo-Hookean material model.
ActiveShapeTargetingArapMaterialParams activeShapeTargetingArap = {}
 Parameters for the Active Shape Targeting ARAP material model.
ArapMaterialParams arap = {}
 Parameters for the ARAP material model.
real density = kDefaultDensity
 Material density in the undeformed configuration [kg/m³].
LinearElasticMaterialParams linearElastic = {}
 Parameters for the Linear Elastic material model.
real massDampingCoefficient = 0_r
 Mass damping coefficient [1/s].
NeoHookeanMaterialParams neoHookean = {}
 Parameters for the Neo-Hookean material model.
real stiffnessDampingCoefficient = 0_r
 Stiffness damping coefficient β [s].
bool stiffnessDampingIncludeGeometricTerm = false
 [Experimental] Include the geometric term in the stiffness-damping tangent.
StVenantKirchhoffMaterialParams stVenantKirchhoff = {}
 Parameters for the St.
SoftMaterialType type = SoftMaterialType::NeoHookean
 Material constitutive model.

Detailed Description

Material parameters for soft body simulation.

Contains the material type discriminant, one instance of each supported material model's parameters, and shared properties (density). The type field selects which material model's parameters are active.

Note
Mochi uses the International System of Units (SI) by default. Other units can be used, but require overwriting all dimensional default parameters (material, contact, constraints, solver, etc.) to ensure consistency.
See also
SoftMaterialType

Definition at line 54 of file material_params.h.

Member Function Documentation

◆ operator==()

bool superdex::SoftMaterialParams::operator== ( SoftMaterialParams const & ) const
default

Member Data Documentation

◆ activeNeoHookean

ActiveNeoHookeanMaterialParams superdex::SoftMaterialParams::activeNeoHookean = {}

Parameters for the Active Neo-Hookean material model.

Definition at line 68 of file material_params.h.

◆ activeShapeTargetingArap

ActiveShapeTargetingArapMaterialParams superdex::SoftMaterialParams::activeShapeTargetingArap = {}

Parameters for the Active Shape Targeting ARAP material model.

Definition at line 71 of file material_params.h.

◆ arap

ArapMaterialParams superdex::SoftMaterialParams::arap = {}

Parameters for the ARAP material model.

Definition at line 74 of file material_params.h.

◆ density

real superdex::SoftMaterialParams::density = kDefaultDensity

Material density in the undeformed configuration [kg/m³].

Must be positive.

Definition at line 77 of file material_params.h.

◆ linearElastic

LinearElasticMaterialParams superdex::SoftMaterialParams::linearElastic = {}

Parameters for the Linear Elastic material model.

Definition at line 65 of file material_params.h.

◆ massDampingCoefficient

real superdex::SoftMaterialParams::massDampingCoefficient = 0_r

Mass damping coefficient [1/s].

Applies a velocity-proportional force α·M·v.

Must be non-negative. Active only when the actor has inertia. A nonzero value with no inertia is valid but inactive (logged as a warning at actor initialization).

Definition at line 85 of file material_params.h.

◆ neoHookean

NeoHookeanMaterialParams superdex::SoftMaterialParams::neoHookean = {}

Parameters for the Neo-Hookean material model.

Definition at line 59 of file material_params.h.

◆ stiffnessDampingCoefficient

real superdex::SoftMaterialParams::stiffnessDampingCoefficient = 0_r

Stiffness damping coefficient β [s].

Adds a strain-rate-proportional viscous stress.

Must be non-negative. Active only when the actor has stress. A nonzero value with no stress is valid but inactive (logged as a warning at actor initialization).

This is a total-Lagrangian variant of Kelvin–Voigt damping: it adds a viscous second Piola–Kirchhoff stress

S_visc = β · C₀ : Ė

where Ė is the material time derivative of the Green–Lagrange strain, and C₀ = ∂²Ψ/∂E² is the Lagrangian material stiffness evaluated at zero deformation.

Note
While the parameterization in terms of a timescale β is similar, this differs from standard Rayleigh damping using the global assembled stiffness matrix; it depends only on strain rate, therefore dissipating energy only during deformation.

Definition at line 105 of file material_params.h.

◆ stiffnessDampingIncludeGeometricTerm

bool superdex::SoftMaterialParams::stiffnessDampingIncludeGeometricTerm = false

[Experimental] Include the geometric term in the stiffness-damping tangent.

Defaults to false.

Only affects the Jacobian for Newton iteration, not the energy, residual, or converged solution. When false (default), the viscous tangent uses a cheaper quasi-Newton approximation. When true, the Newton Jacobian includes a geometric term, which is proportional to the per-stage strain increment and may improve nonlinear solver convergence in certain scenarios.

Warning
This is an experimental feature. It may be changed or removed in the future. Use at your own risk.

Definition at line 120 of file material_params.h.

◆ stVenantKirchhoff

StVenantKirchhoffMaterialParams superdex::SoftMaterialParams::stVenantKirchhoff = {}

Parameters for the St.

Venant-Kirchhoff material model.

Definition at line 62 of file material_params.h.

◆ type

SoftMaterialType superdex::SoftMaterialParams::type = SoftMaterialType::NeoHookean

Material constitutive model.

Definition at line 56 of file material_params.h.


The documentation for this struct was generated from the following file: