Trace.h file
Matrix trace operator for matrix-valued functions.
This file defines the Trace class, which computes the trace (sum of diagonal elements) of matrix-valued functions in variational formulations.
Mathematical Foundation
For a square matrix , the trace is:
Properties
The trace operator satisfies:
- Linearity:
- Scalar multiplication:
- Cyclic property:
- Transpose invariance:
Applications
- Linear elasticity: (volumetric strain)
- Continuum mechanics: invariants of stress/strain tensors
- Fluid dynamics: divergence from velocity gradient
- General tensor operations
Usage Example
// Volumetric strain in linear elasticity auto strain = 0.5 * (Jacobian(u) + Transpose(Jacobian(u))); auto volumetric_strain = Trace(strain); // tr(ε)
Namespaces
- namespace Rodin
- The Rodin library for Shape and Topology Optimization.
- namespace Rodin::FormLanguage
- Module for writing high level abstract expressions.
- namespace Rodin::Variational
- Module which provides the necessary tools for constructing variational problems.
Classes
-
template<class NestedDerived>class Rodin::Variational::Trace<FunctionBase<NestedDerived>>
- Trace of a FunctionBase instance.