MechanicalPropagateOnlyPositionVisitor
Propagate positions to all the levels of the hierarchy. At each level, the mappings form the parent to the child is applied. Note that this visitor only propagate through the mappings, and does not apply projective constraints as was previously done by MechanicalPropagatePositionVisitor. Use MechanicalProjectPositionVisitor before this visitor if projection is needed.
The `MechanicalPropagateOnlyPositionVisitor` propagates positions through the simulation hierarchy by applying mappings from parent to child nodes without enforcing projective constraints.
- module
- Sofa.framework.Simulation.Core
- namespace
- sofa::simulation::mechanicalvisitor
- include
- sofa/simulation/mechanicalvisitor/MechanicalPropagateOnlyPositionVisitor.h
- inherits
-
- MechanicalVisitor
- description
The MechanicalPropagateOnlyPositionVisitor is a SOFA mechanical visitor designed to propagate positions through the hierarchy levels of a simulation, applying mappings from parent to child nodes. This visitor focuses specifically on position propagation and does not apply projective constraints as done by other visitors like MechanicalPropagatePositionVisitor. Here is a detailed mathematical and physical description:
Governing Equations or Operators
- Role: The component propagates positions through the hierarchy of mechanical states, applying mappings. It ensures that the position vector $ oldsymbol{x} $ is updated at each level.
- Propagation Mechanism: Positions are propagated from parent to child nodes using mappings defined between them. This can be represented as:
$$ \boldsymbol{x}_{child}(t) = M_{parent\rightarrow child}(oldsymbol{x}_{parent}(t)) $$
where $ M_{parent\rightarrow child} $ is the mapping function from parent to child.
Constitutive or Kinematic Laws Involved
- Kinematics: The visitor does not modify kinematics beyond propagating positions. It assumes that mappings are defined in terms of position vectors only, which may include linear transformations, corotational maps, or more complex nonlinear mappings depending on the specific application.
Role in the Global FEM Pipeline
- Assembly Phase: During assembly, this visitor ensures that the mechanical state at each level is updated by applying mappings to propagate positions from parent to child nodes. This step is crucial for maintaining consistency across different levels of detail or resolutions within a simulation.
- Time Integration: The propagation occurs at each time step and does not directly contribute to the time integration scheme but ensures that positions are consistent throughout the hierarchy before further processing (e.g., constraints, forces).
Numerical Methods or Discretization Choices Encoded
- Mapping Application: The visitor applies mappings defined between mechanical states. These mappings can be linear transformations or more complex functions depending on the physical model and discretization choices in the simulation.
- Example mapping: Corotational mapping for large deformations, where rotations are separated from deformations to maintain numerical stability.
Fit into the Broader Variational / Lagrangian Mechanics Framework
- Position Propagation: In variational mechanics, positions are key variables that define the configuration of a system. The visitor ensures that these configurations are propagated consistently across different levels or resolutions within the hierarchy.
- Consistency Maintenance: By ensuring consistent propagation of positions through mappings, this component helps maintain mechanical consistency and integrity in simulations involving hierarchical models or multi-resolution coupling.
In summary, MechanicalPropagateOnlyPositionVisitor plays a crucial role in position propagation and maintaining consistency across different levels within the SOFA simulation framework.
Methods
Result
fwdMechanicalState
(simulation::Node * , sofa::core::behavior::BaseMechanicalState * mm)
virtual
Result
fwdMechanicalMapping
(simulation::Node * , sofa::core::BaseMapping * map)
virtual
void
bwdMechanicalState
(simulation::Node * , sofa::core::behavior::BaseMechanicalState * mm)
virtual
bool
stopAtMechanicalMapping
(simulation::Node * , sofa::core::BaseMapping * )
virtual
int
getInfos
()
bool
isThreadSafe
()
virtual
{
"name": "MechanicalPropagateOnlyPositionVisitor",
"namespace": "sofa::simulation::mechanicalvisitor",
"module": "Sofa.framework.Simulation.Core",
"include": "sofa/simulation/mechanicalvisitor/MechanicalPropagateOnlyPositionVisitor.h",
"doc": "Propagate positions to all the levels of the hierarchy.\nAt each level, the mappings form the parent to the child is applied.\nNote that this visitor only propagate through the mappings, and does\nnot apply projective constraints as was previously done by\nMechanicalPropagatePositionVisitor.\nUse MechanicalProjectPositionVisitor before this visitor if projection\nis needed.",
"inherits": [
"MechanicalVisitor"
],
"templates": [],
"data_fields": [],
"links": [],
"methods": [
{
"name": "fwdMechanicalState",
"return_type": "Result",
"params": [
{
"name": "",
"type": "simulation::Node *"
},
{
"name": "mm",
"type": "sofa::core::behavior::BaseMechanicalState *"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "fwdMechanicalMapping",
"return_type": "Result",
"params": [
{
"name": "",
"type": "simulation::Node *"
},
{
"name": "map",
"type": "sofa::core::BaseMapping *"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "bwdMechanicalState",
"return_type": "void",
"params": [
{
"name": "",
"type": "simulation::Node *"
},
{
"name": "mm",
"type": "sofa::core::behavior::BaseMechanicalState *"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "stopAtMechanicalMapping",
"return_type": "bool",
"params": [
{
"name": "",
"type": "simulation::Node *"
},
{
"name": "",
"type": "sofa::core::BaseMapping *"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getInfos",
"return_type": "int",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "isThreadSafe",
"return_type": "bool",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
}
],
"description": "The `MechanicalPropagateOnlyPositionVisitor` is a SOFA mechanical visitor that propagates positions through the hierarchy levels of a simulation, applying mappings from parent to child nodes. This visitor specifically focuses on position propagation and does not apply projective constraints as done by other visitors like `MechanicalPropagatePositionVisitor`. It inherits from `MechanicalVisitor`, indicating its role in processing mechanical states and mappings within the SOFA framework.\n\nInteractions with other components are primarily through API methods such as `fwdMechanicalState`, which propagates positions forward, `fwdMechanicalMapping` that applies mappings to propagate positions, and `bwdMechanicalState`, which processes backward but does not modify data. The visitor also overrides `stopAtMechanicalMapping` to ensure it continues through all mechanical mappings.\n\nPractical usage involves ensuring this visitor is used in scenarios where only position propagation through mappings is needed without additional constraints. Data fields include time (`t`) and a multi-vector coordinate identifier (`x`).",
"maths": "The `MechanicalPropagateOnlyPositionVisitor` is a SOFA mechanical visitor designed to propagate positions through the hierarchy levels of a simulation, applying mappings from parent to child nodes. This visitor focuses specifically on position propagation and does not apply projective constraints as done by other visitors like `MechanicalPropagatePositionVisitor`. Here is a detailed mathematical and physical description:\n\n### Governing Equations or Operators\n- **Role**: The component propagates positions through the hierarchy of mechanical states, applying mappings. It ensures that the position vector \\( \boldsymbol{x} \\) is updated at each level.\n- **Propagation Mechanism**: Positions are propagated from parent to child nodes using mappings defined between them. This can be represented as:\n \\[\n \\boldsymbol{x}_{child}(t) = M_{parent\\rightarrow child}(\boldsymbol{x}_{parent}(t))\n \\]\n where \\( M_{parent\\rightarrow child} \\) is the mapping function from parent to child.\n\n### Constitutive or Kinematic Laws Involved\n- **Kinematics**: The visitor does not modify kinematics beyond propagating positions. It assumes that mappings are defined in terms of position vectors only, which may include linear transformations, corotational maps, or more complex nonlinear mappings depending on the specific application.\n\n### Role in the Global FEM Pipeline\n- **Assembly Phase**: During assembly, this visitor ensures that the mechanical state at each level is updated by applying mappings to propagate positions from parent to child nodes. This step is crucial for maintaining consistency across different levels of detail or resolutions within a simulation.\n- **Time Integration**: The propagation occurs at each time step and does not directly contribute to the time integration scheme but ensures that positions are consistent throughout the hierarchy before further processing (e.g., constraints, forces).\n\n### Numerical Methods or Discretization Choices Encoded\n- **Mapping Application**: The visitor applies mappings defined between mechanical states. These mappings can be linear transformations or more complex functions depending on the physical model and discretization choices in the simulation.\n - Example mapping: Corotational mapping for large deformations, where rotations are separated from deformations to maintain numerical stability.\n\n### Fit into the Broader Variational / Lagrangian Mechanics Framework\n- **Position Propagation**: In variational mechanics, positions are key variables that define the configuration of a system. The visitor ensures that these configurations are propagated consistently across different levels or resolutions within the hierarchy.\n- **Consistency Maintenance**: By ensuring consistent propagation of positions through mappings, this component helps maintain mechanical consistency and integrity in simulations involving hierarchical models or multi-resolution coupling.\n\nIn summary, `MechanicalPropagateOnlyPositionVisitor` plays a crucial role in position propagation and maintaining consistency across different levels within the SOFA simulation framework.",
"abstract": "The `MechanicalPropagateOnlyPositionVisitor` propagates positions through the simulation hierarchy by applying mappings from parent to child nodes without enforcing projective constraints.",
"sheet": "# MechanicalPropagateOnlyPositionVisitor\n\n## Overview\nThe `MechanicalPropagateOnlyPositionVisitor` is a SOFA mechanical visitor that propagates positions through the hierarchy levels of a simulation, applying mappings from parent to child nodes. It ensures consistent position propagation across different levels or resolutions within the hierarchy without enforcing projective constraints.\n\n## Dependencies and Connections\nThis component typically requires `BaseMechanicalState` and `BaseMapping` components for its operation. The visitor fits into the scene graph by ensuring that positions are propagated consistently through mappings, maintaining mechanical consistency and integrity in simulations involving hierarchical models or multi-resolution coupling."
}