doxy-label
Doxygen: :cppSofaCaribou::mass::CaribouMass
Implementation of a consistent Mass matrix. The assembly of this mass matrix takes the form of
MIK = ∫Ωeρ0NINKdΩI
where I and K are a pair of indices of the element K nodes. Here, ρ0 is the mass density as the mass per volume unit (ie
A diagonal consistent mass matrix is also constructed by scaling down the diagonal terms in a way that the mass is constant within the element. The procedure is the following:
MIIdiag = seMIII with MII = ∫eρ0NI2dΩ
With the scaling factor being
- See the following book for more information:
Peter Wriggers, Nonlinear finite element methods (2008), DOI: 10.1007/978-3-540-71001-1_2
Requires a mechanical object. Requires a topology container.
Attribute | Format | Default | Description |
---|---|---|---|
printLog | bool | false | Output informative messages at the initialization and during the simulation. |
lumped | bool | false | Whether or not the mass matrix should be lumped by scaling the diagonal entries such that the mass is constant per element. Note that the lumped matrix is always computed. But this parameter will determine if it (the lumped) matrix should be used to solve the acceleration (a = M^(-1).f). |
density | double | 1 | Mass density of the material at the undeformed state formulated as the mass per volume unit, ie ρ0 = m/v. |
topology | path | Path to a either a SOFA mesh topology container (such as an HexahedronSetTopologyContainer or TetrahedronSetTopologyContainer) or a CaribouTopology component that contains the elements. | |
template | option | The template argument is used to specified the element type on which to compute the mass. By default, the component will try to deduce its element type from the given topology.
|
tab1
<Node>
<RegularGridTopology name="grid" min="-7.5 -7.5 0" max="7.5 7.5 80" n="9 9 21" />
<MechanicalObject src="@grid" />
<HexahedronSetTopologyContainer name="topology" src="@grid" />
<CaribouMass density="2.5" lumped="true" topology="@topology" />
</Node>
tab2
node.addObject("RegularGridTopology", name="grid", min=[-7.5, -7.5, 0], max=[7.5, 7.5, 80], n=[9, 9, 21])
node.addObject("MechanicalObject", src="@grid")
node.addObject("HexahedronSetTopologyContainer", name="topology", src="@grid")
node.addObject("CaribouMass", density=2.5, lumped=True, topology="@topology")