TetrahedronSetTopologyContainer
Topology container dedicated to a tetrahedral topology. a class that stores a set of tetrahedra and provides access with adjacent triangles, edges and vertices */
The `TetrahedronSetTopologyContainer` manages tetrahedral meshes by storing adjacency information for vertices, edges, triangles, and tetrahedra, facilitating efficient mesh operations in FEM simulations.
- module
- Sofa.Component.Topology.Container.Dynamic
- namespace
- sofa::component::topology::container::dynamic
- include
- sofa/component/topology/container/dynamic/TetrahedronSetTopologyContainer.h
- inherits
-
- TriangleSetTopologyContainer
- description
The TetrahedronSetTopologyContainer is a topology container in the SOFA framework designed specifically for managing tetrahedral meshes. This component plays a fundamental role in spatial discretization and serves as an essential part of the FEM simulation pipeline by providing necessary information about the connectivity between elements. Here's a detailed mathematical and physical description covering its functionalities, numerical methods, and integration within the broader variational mechanics framework:
Governing Equations or Operators
The TetrahedronSetTopologyContainer does not directly contribute to governing equations such as mass matrix $M$, stiffness matrix $K$, internal forces $f_{int}$, residual $R$, etc. Instead, it serves as a data structure that stores and manages the topology of tetrahedral elements within a mesh. It facilitates subsequent operations by providing access to various topological relationships.
Constitutive or Kinematic Laws Involved
While this component does not directly involve constitutive laws (e.g., stress-strain relations), it plays a crucial role in ensuring that these laws are applied correctly by maintaining the correct connectivity information. The container stores and provides adjacency data for:
- Vertices: Each vertex is connected to several tetrahedra.
- Edges: Each edge connects two vertices and is part of multiple tetrahedra.
- Triangles (Faces): Each face connects three vertices and is shared by two neighboring tetrahedra.
- Tetrahedra: The main elements forming the mesh, each connected to other tetrahedra through shared faces or edges.
Role in the Global FEM Pipeline
The TetrahedronSetTopologyContainer plays a critical role during the discretization phase of the FEM simulation pipeline. Its primary responsibilities include:
- Mesh Management: Storing and managing the connectivity information for tetrahedral elements, ensuring that subsequent operations (e.g., assembly of element matrices) can be performed efficiently.
- Topological Queries: Providing methods to query adjacency relationships between different mesh entities (vertices, edges, triangles, tetrahedra), which are essential for tasks such as computing shape functions and numerical integration over elements.
Numerical Methods or Discretization Choices
The component is designed with the following numerical methods in mind:
- Mesh Representation: The container stores a list of tetrahedra, each defined by four vertices (indices). This representation aligns well with common FEM discretization practices where tetrahedral elements are used for 3D simulations.
- Adjacency Information: It maintains arrays for adjacency relationships such as which tetrahedra share edges or faces. These arrays facilitate efficient access to neighboring elements, a critical requirement for operations like assembling global matrices and applying constraints.
Integration into the Variational Mechanics Framework
Although TetrahedronSetTopologyContainer itself does not directly involve variational formulations, it provides the necessary data structures that underpin the weak form of the governing equations. For example:
- Shape Functions: The connectivity information managed by this container is used to define shape functions for interpolation within each tetrahedral element.
- Element Operators: The adjacency relationships provided are essential for assembling element operators (mass matrix, stiffness matrix) and applying boundary conditions or constraints in the global system.
Summary
In summary, TetrahedronSetTopologyContainer is a critical component that manages tetrahedral mesh topology. While it does not directly contribute to governing equations, its role in storing and providing adjacency information ensures the proper application of constitutive laws and supports efficient numerical operations within the FEM simulation pipeline.
Data Fields
| Name | Type | Default | Help |
|---|---|---|---|
d_createTriangleArray |
bool | |
Force the creation of a set of triangles associated with each tetrahedron |
Methods
void
init
()
virtual
void
addRemovedTetraIndex
(int & tetrahedra)
int &
getRemovedTetraIndex
()
void
clear
()
virtual
void
addTriangle
(Index , Index , Index )
virtual
void
addTetra
(Index a, Index b, Index c, Index d)
virtual
const SeqTetrahedra &
getTetrahedra
()
const Tetrahedron
getTetrahedron
(TetraID i)
virtual
TetrahedronID
getTetrahedronIndex
(PointID v1, PointID v2, PointID v3, PointID v4)
virtual
const EdgesInTetrahedron &
getEdgesInTetrahedron
(TetraID id)
virtual
const TrianglesInTetrahedron &
getTrianglesInTetrahedron
(TetraID id)
virtual
const TetrahedraAroundVertex &
getTetrahedraAroundVertex
(PointID id)
virtual
const TetrahedraAroundEdge &
getTetrahedraAroundEdge
(EdgeID id)
virtual
const TetrahedraAroundTriangle &
getTetrahedraAroundTriangle
(TriangleID id)
virtual
int
getVertexIndexInTetrahedron
(const Tetrahedron & t, PointID vertexIndex)
virtual
int
getEdgeIndexInTetrahedron
(const EdgesInTetrahedron & t, EdgeID edgeIndex)
virtual
int
getTriangleIndexInTetrahedron
(const TrianglesInTetrahedron & t, TriangleID triangleIndex)
virtual
Edge
getLocalEdgesInTetrahedron
(const EdgeID i)
virtual
Triangle
getLocalTrianglesInTetrahedron
(const TriangleID i)
virtual
void
computeCrossElementBuffers
()
virtual
bool
checkTopology
()
virtual
bool
checkConnexity
()
virtual
int
getNumberOfConnectedComponent
()
const VecTetraID
getConnectedElement
(TetraID elem)
const VecTetraID
getElementAroundElement
(TetraID elem)
const VecTetraID
getElementAroundElements
(VecTetraID elems)
const VecTetraID
getOppositeElement
(TetraID elemID)
int
getNumberOfTetrahedra
()
int
getNumberOfElements
()
const int &
getTetrahedronArray
()
const int &
getEdgesInTetrahedronArray
()
const int &
getTrianglesInTetrahedronArray
()
const int &
getTetrahedraAroundVertexArray
()
const int &
getTetrahedraAroundEdgeArray
()
const int &
getTetrahedraAroundTriangleArray
()
bool
hasTetrahedra
()
bool
hasEdgesInTetrahedron
()
bool
hasTrianglesInTetrahedron
()
bool
hasTetrahedraAroundVertex
()
bool
hasTetrahedraAroundEdge
()
bool
hasTetrahedraAroundTriangle
()
sofa::geometry::ElementType
getTopologyType
()
virtual
bool
linkTopologyHandlerToData
(core::topology::TopologyHandler * topologyHandler, sofa::geometry::ElementType elementType)
virtual
bool
unlinkTopologyHandlerToData
(core::topology::TopologyHandler * topologyHandler, sofa::geometry::ElementType elementType)
virtual
void
createEdgeSetArray
()
virtual
void
createTriangleSetArray
()
virtual
void
createTetrahedronSetArray
()
virtual
void
createEdgesInTetrahedronArray
()
virtual
void
createTrianglesInTetrahedronArray
()
virtual
void
createTetrahedraAroundVertexArray
()
virtual
void
createTetrahedraAroundEdgeArray
()
virtual
void
createTetrahedraAroundTriangleArray
()
virtual
void
clearTetrahedra
()
void
clearEdgesInTetrahedron
()
void
clearTrianglesInTetrahedron
()
void
clearTetrahedraAroundVertex
()
void
clearTetrahedraAroundEdge
()
void
clearTetrahedraAroundTriangle
()
TetrahedraAroundVertex &
getTetrahedraAroundVertexForModification
(const PointID vertexIndex)
virtual
TetrahedraAroundEdge &
getTetrahedraAroundEdgeForModification
(const EdgeID edgeIndex)
virtual
TetrahedraAroundTriangle &
getTetrahedraAroundTriangleForModification
(const TriangleID triangleIndex)
virtual
void
setTetrahedronTopologyToDirty
()
void
cleanTetrahedronTopologyFromDirty
()
const bool &
isTetrahedronTopologyDirty
()
{
"name": "TetrahedronSetTopologyContainer",
"namespace": "sofa::component::topology::container::dynamic",
"module": "Sofa.Component.Topology.Container.Dynamic",
"include": "sofa/component/topology/container/dynamic/TetrahedronSetTopologyContainer.h",
"doc": "Topology container dedicated to a tetrahedral topology.\n\na class that stores a set of tetrahedra and provides access with adjacent triangles, edges and vertices */",
"inherits": [
"TriangleSetTopologyContainer"
],
"templates": [],
"data_fields": [
{
"name": "d_createTriangleArray",
"type": "bool",
"xmlname": "createTriangleArray",
"help": "Force the creation of a set of triangles associated with each tetrahedron"
}
],
"links": [],
"methods": [
{
"name": "init",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "addRemovedTetraIndex",
"return_type": "void",
"params": [
{
"name": "tetrahedra",
"type": "int &"
}
],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getRemovedTetraIndex",
"return_type": "int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "clear",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "addTriangle",
"return_type": "void",
"params": [
{
"name": "",
"type": "Index"
},
{
"name": "",
"type": "Index"
},
{
"name": "",
"type": "Index"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "addTetra",
"return_type": "void",
"params": [
{
"name": "a",
"type": "Index"
},
{
"name": "b",
"type": "Index"
},
{
"name": "c",
"type": "Index"
},
{
"name": "d",
"type": "Index"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedra",
"return_type": "const SeqTetrahedra &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedron",
"return_type": "const Tetrahedron",
"params": [
{
"name": "i",
"type": "TetraID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedronIndex",
"return_type": "TetrahedronID",
"params": [
{
"name": "v1",
"type": "PointID"
},
{
"name": "v2",
"type": "PointID"
},
{
"name": "v3",
"type": "PointID"
},
{
"name": "v4",
"type": "PointID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getEdgesInTetrahedron",
"return_type": "const EdgesInTetrahedron &",
"params": [
{
"name": "id",
"type": "TetraID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTrianglesInTetrahedron",
"return_type": "const TrianglesInTetrahedron &",
"params": [
{
"name": "id",
"type": "TetraID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundVertex",
"return_type": "const TetrahedraAroundVertex &",
"params": [
{
"name": "id",
"type": "PointID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundEdge",
"return_type": "const TetrahedraAroundEdge &",
"params": [
{
"name": "id",
"type": "EdgeID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundTriangle",
"return_type": "const TetrahedraAroundTriangle &",
"params": [
{
"name": "id",
"type": "TriangleID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getVertexIndexInTetrahedron",
"return_type": "int",
"params": [
{
"name": "t",
"type": "const Tetrahedron &"
},
{
"name": "vertexIndex",
"type": "PointID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getEdgeIndexInTetrahedron",
"return_type": "int",
"params": [
{
"name": "t",
"type": "const EdgesInTetrahedron &"
},
{
"name": "edgeIndex",
"type": "EdgeID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTriangleIndexInTetrahedron",
"return_type": "int",
"params": [
{
"name": "t",
"type": "const TrianglesInTetrahedron &"
},
{
"name": "triangleIndex",
"type": "TriangleID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getLocalEdgesInTetrahedron",
"return_type": "Edge",
"params": [
{
"name": "i",
"type": "const EdgeID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getLocalTrianglesInTetrahedron",
"return_type": "Triangle",
"params": [
{
"name": "i",
"type": "const TriangleID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "computeCrossElementBuffers",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "checkTopology",
"return_type": "bool",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "checkConnexity",
"return_type": "bool",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getNumberOfConnectedComponent",
"return_type": "int",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getConnectedElement",
"return_type": "const VecTetraID",
"params": [
{
"name": "elem",
"type": "TetraID"
}
],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getElementAroundElement",
"return_type": "const VecTetraID",
"params": [
{
"name": "elem",
"type": "TetraID"
}
],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getElementAroundElements",
"return_type": "const VecTetraID",
"params": [
{
"name": "elems",
"type": "VecTetraID"
}
],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getOppositeElement",
"return_type": "const VecTetraID",
"params": [
{
"name": "elemID",
"type": "TetraID"
}
],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getNumberOfTetrahedra",
"return_type": "int",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getNumberOfElements",
"return_type": "int",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedronArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getEdgesInTetrahedronArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTrianglesInTetrahedronArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundVertexArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundEdgeArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTetrahedraAroundTriangleArray",
"return_type": "const int &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasTetrahedra",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasEdgesInTetrahedron",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasTrianglesInTetrahedron",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasTetrahedraAroundVertex",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasTetrahedraAroundEdge",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "hasTetrahedraAroundTriangle",
"return_type": "bool",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "getTopologyType",
"return_type": "sofa::geometry::ElementType",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "linkTopologyHandlerToData",
"return_type": "bool",
"params": [
{
"name": "topologyHandler",
"type": "core::topology::TopologyHandler *"
},
{
"name": "elementType",
"type": "sofa::geometry::ElementType"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "unlinkTopologyHandlerToData",
"return_type": "bool",
"params": [
{
"name": "topologyHandler",
"type": "core::topology::TopologyHandler *"
},
{
"name": "elementType",
"type": "sofa::geometry::ElementType"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "public"
},
{
"name": "createEdgeSetArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTriangleSetArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTetrahedronSetArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createEdgesInTetrahedronArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTrianglesInTetrahedronArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTetrahedraAroundVertexArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTetrahedraAroundEdgeArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "createTetrahedraAroundTriangleArray",
"return_type": "void",
"params": [],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearTetrahedra",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearEdgesInTetrahedron",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearTrianglesInTetrahedron",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearTetrahedraAroundVertex",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearTetrahedraAroundEdge",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "clearTetrahedraAroundTriangle",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "getTetrahedraAroundVertexForModification",
"return_type": "TetrahedraAroundVertex &",
"params": [
{
"name": "vertexIndex",
"type": "const PointID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "getTetrahedraAroundEdgeForModification",
"return_type": "TetrahedraAroundEdge &",
"params": [
{
"name": "edgeIndex",
"type": "const EdgeID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "getTetrahedraAroundTriangleForModification",
"return_type": "TetrahedraAroundTriangle &",
"params": [
{
"name": "triangleIndex",
"type": "const TriangleID"
}
],
"is_virtual": true,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "setTetrahedronTopologyToDirty",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "cleanTetrahedronTopologyFromDirty",
"return_type": "void",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
},
{
"name": "isTetrahedronTopologyDirty",
"return_type": "const bool &",
"params": [],
"is_virtual": false,
"is_pure_virtual": false,
"is_static": false,
"access": "protected"
}
],
"description": "The `TetrahedronSetTopologyContainer` is a topology container within the SOFA framework dedicated to managing tetrahedral topologies. It inherits from `TriangleSetTopologyContainer`, which implies it extends functionalities for handling triangles, edges, and vertices associated with tetrahedra.\n\nThis component stores a set of tetrahedra and provides methods for accessing adjacent triangles, edges, and vertices. The container facilitates the initialization and manipulation of tetrahedral meshes, including creating and clearing tetrahedron arrays, managing cross-element buffers, and maintaining adjacency information for efficient mesh operations.\n\nThe `TetrahedronSetTopologyContainer` interacts with other SOFA components via its API by providing topology data and methods to modify or query the tetrahedral structure. It is used in conjunction with various other components that require knowledge of the underlying mesh's connectivity, such as those involved in finite element simulations.\n\nA key data field of this component is `d_createTriangleArray`, which forces the creation of a set of triangles associated with each tetrahedron if needed. The container offers numerous methods for operations like adding or removing tetrahedra, checking topology integrity, and maintaining adjacency lists for vertices, edges, and triangles.\n\nTo use the `TetrahedronSetTopologyContainer`, one must ensure proper initialization through methods such as `init()`, which sets up essential topology elements. Additionally, the component provides utility functions to inspect and modify the tetrahedral structure, enabling complex mesh operations required in simulation and modeling tasks within SOFA.",
"maths": "The `TetrahedronSetTopologyContainer` is a topology container in the SOFA framework designed specifically for managing tetrahedral meshes. This component plays a fundamental role in spatial discretization and serves as an essential part of the FEM simulation pipeline by providing necessary information about the connectivity between elements. Here's a detailed mathematical and physical description covering its functionalities, numerical methods, and integration within the broader variational mechanics framework:\n\n### Governing Equations or Operators\nThe `TetrahedronSetTopologyContainer` does not directly contribute to governing equations such as mass matrix \\(M\\), stiffness matrix \\(K\\), internal forces \\(f_{int}\\), residual \\(R\\), etc. Instead, it serves as a data structure that stores and manages the topology of tetrahedral elements within a mesh. It facilitates subsequent operations by providing access to various topological relationships.\n\n### Constitutive or Kinematic Laws Involved\nWhile this component does not directly involve constitutive laws (e.g., stress-strain relations), it plays a crucial role in ensuring that these laws are applied correctly by maintaining the correct connectivity information. The container stores and provides adjacency data for:\n- **Vertices:** Each vertex is connected to several tetrahedra.\n- **Edges:** Each edge connects two vertices and is part of multiple tetrahedra.\n- **Triangles (Faces):** Each face connects three vertices and is shared by two neighboring tetrahedra.\n- **Tetrahedra:** The main elements forming the mesh, each connected to other tetrahedra through shared faces or edges.\n\n### Role in the Global FEM Pipeline\nThe `TetrahedronSetTopologyContainer` plays a critical role during the discretization phase of the FEM simulation pipeline. Its primary responsibilities include:\n- **Mesh Management:** Storing and managing the connectivity information for tetrahedral elements, ensuring that subsequent operations (e.g., assembly of element matrices) can be performed efficiently.\n- **Topological Queries:** Providing methods to query adjacency relationships between different mesh entities (vertices, edges, triangles, tetrahedra), which are essential for tasks such as computing shape functions and numerical integration over elements.\n\n### Numerical Methods or Discretization Choices\nThe component is designed with the following numerical methods in mind:\n- **Mesh Representation:** The container stores a list of tetrahedra, each defined by four vertices (indices). This representation aligns well with common FEM discretization practices where tetrahedral elements are used for 3D simulations.\n- **Adjacency Information:** It maintains arrays for adjacency relationships such as which tetrahedra share edges or faces. These arrays facilitate efficient access to neighboring elements, a critical requirement for operations like assembling global matrices and applying constraints.\n\n### Integration into the Variational Mechanics Framework\nAlthough `TetrahedronSetTopologyContainer` itself does not directly involve variational formulations, it provides the necessary data structures that underpin the weak form of the governing equations. For example:\n- **Shape Functions:** The connectivity information managed by this container is used to define shape functions for interpolation within each tetrahedral element.\n- **Element Operators:** The adjacency relationships provided are essential for assembling element operators (mass matrix, stiffness matrix) and applying boundary conditions or constraints in the global system.\n\n### Summary\nIn summary, `TetrahedronSetTopologyContainer` is a critical component that manages tetrahedral mesh topology. While it does not directly contribute to governing equations, its role in storing and providing adjacency information ensures the proper application of constitutive laws and supports efficient numerical operations within the FEM simulation pipeline.",
"abstract": "The `TetrahedronSetTopologyContainer` manages tetrahedral meshes by storing adjacency information for vertices, edges, triangles, and tetrahedra, facilitating efficient mesh operations in FEM simulations.",
"sheet": "<h1>TetrahedronSetTopologyContainer</h1>\n\n<h2>Overview</h2>\n<p>The `TetrahedronSetTopologyContainer` is a topology container dedicated to managing tetrahedral meshes. It inherits from `TriangleSetTopologyContainer`, extending functionalities for handling triangles, edges, and vertices associated with tetrahedra. This component stores adjacency information essential for FEM simulations.</p>\n\n<h2>Parameters and Data</h2>\n<p>The significant data field exposed by this component is:</p>\n<ul>\n<li><strong>d_createTriangleArray (bool)</strong>: Forces the creation of a set of triangles associated with each tetrahedron. Default: <code>false</code>.</li>\n</ul>\n\n<h2>Dependencies and Connections</h2>\n<p>The `TetrahedronSetTopologyContainer` typically requires or exchanges data with other SOFA components that handle mesh initialization, manipulation, and simulation operations. It fits into the scene graph by providing essential topology information for subsequent FEM simulations.</p>"
}