DampingMatrixExpression< FP, D > Class Template Reference
|
CPP API
|
represents the coefficient wise matrix (or vector) expression B - D * M where B is a baseline, M is a minimum and D is some time dependent complex damping factor. More...
#include <contact_matrix.h>
Public Types | |
| using | DampingsType = D |
| using | Matrix = typename Shape::Matrix |
| using | Shape = typename DampingsType::Shape |
Public Member Functions | |
| template<class... T> | |
| void | add_damping (T &&... t) |
| adds a damping. More... | |
| void | clear_dampings () |
| remove all dampings. More... | |
| template<class M > | |
| DampingMatrixExpression (const Eigen::MatrixBase< M > &baseline) | |
| construct with only baseline, minimum and dampings is zero. More... | |
| template<class M , class K > | |
| DampingMatrixExpression (const Eigen::MatrixBase< M > &baseline, const Eigen::MatrixBase< K > &minimum) | |
| construct with baseline and minimum contacts and zero dampings. More... | |
| template<class... T> | |
| requires std::is_constructible_v< Shape, T... > | DampingMatrixExpression (T... shape_args) |
| construct with shape. More... | |
| Matrix & | get_baseline () |
| const Matrix & | get_baseline () const |
| get the baseline matrix. More... | |
| auto | get_dampings () |
| auto | get_dampings () const |
| list of dampings. More... | |
| auto | get_matrix_at (SimulationTime< FP > t) const |
| Applies dampings to compute the real contact frequency at a point in time. More... | |
| Matrix & | get_minimum () |
| const Matrix & | get_minimum () const |
| get the minimum matrix. More... | |
| Shape | get_shape () const |
| dimensions of the matrix. More... | |
| bool | operator!= (const DampingMatrixExpression &other) const |
| bool | operator== (const DampingMatrixExpression &other) const |
| equality operators. More... | |
| void | remove_damping (size_t i) |
| remove a damping. More... | |
| template<class IOContext > | |
| void | serialize (IOContext &io) const |
| serialize this. More... | |
| void | set_automatic_cache_update (bool b) |
| Enable/disable automatic cache update of the dampings. More... | |
Static Public Member Functions | |
| template<class IOContext > | |
| static IOResult< DampingMatrixExpression > | deserialize (IOContext &io) |
| deserialize an object of this class. More... | |
Static Protected Member Functions | |
| template<class IOContext , class Derived > | |
| static IOResult< Derived > | deserialize (IOContext &io, Tag< Derived >) |
| deserialize an object of a class derived from this. More... | |
Private Attributes | |
| Matrix | m_baseline |
| DampingsType | m_dampings |
| Matrix | m_minimum |
Friends | |
| void | PrintTo (const DampingMatrixExpression &self, std::ostream *os) |
| gtest printer. More... | |
Detailed Description
template<typename FP, class D>
class mio::DampingMatrixExpression< FP, D >
represents the coefficient wise matrix (or vector) expression B - D * M where B is a baseline, M is a minimum and D is some time dependent complex damping factor.
Base class for e.g. time dependent contact matrices. Coefficient wise expression, so B, D, M matrices must have the same shape.
- See also
- Damping
- ContactMatrix
- Template Parameters
-
FP floating point, e.g. double D instance of Dampings or compatible type
Member Typedef Documentation
◆ DampingsType
| using mio::DampingMatrixExpression< FP, D >::DampingsType = D |
◆ Matrix
| using mio::DampingMatrixExpression< FP, D >::Matrix = typename Shape::Matrix |
◆ Shape
| using mio::DampingMatrixExpression< FP, D >::Shape = typename DampingsType::Shape |
Constructor & Destructor Documentation
◆ DampingMatrixExpression() [1/3]
|
inline |
construct with baseline and minimum contacts and zero dampings.
- Parameters
-
baseline matrix expression minimum matrix expression, must be same size as baseline
- Template Parameters
-
M,K matrix expressions compatible with Matrix type
◆ DampingMatrixExpression() [2/3]
|
inlineexplicit |
construct with only baseline, minimum and dampings is zero.
- Parameters
-
baseline matrix expression
- Template Parameters
-
M matrix expressions compatible with Matrix type
◆ DampingMatrixExpression() [3/3]
|
inlineexplicit |
construct with shape.
baseline, minimum and dampings all zero.
- Parameters
-
shape_args shape arguments.
- Template Parameters
-
T shape arguments.
Member Function Documentation
◆ add_damping()
|
inline |
adds a damping.
- See also
- Dampings::add
◆ clear_dampings()
|
inline |
remove all dampings.
◆ deserialize() [1/2]
|
inlinestatic |
deserialize an object of this class.
- See also
- mio::deserialize
◆ deserialize() [2/2]
|
inlinestaticprotected |
deserialize an object of a class derived from this.
◆ get_baseline() [1/2]
|
inline |
◆ get_baseline() [2/2]
|
inline |
get the baseline matrix.
◆ get_dampings() [1/2]
|
inline |
◆ get_dampings() [2/2]
|
inline |
list of dampings.
◆ get_matrix_at()
|
inline |
Applies dampings to compute the real contact frequency at a point in time.
Uses lazy evaluation, coefficients are calculated on indexed access.
- Parameters
-
t time in the simulation
- Returns
- matrix expression (num_groups x num_groups)
◆ get_minimum() [1/2]
|
inline |
◆ get_minimum() [2/2]
|
inline |
get the minimum matrix.
◆ get_shape()
|
inline |
dimensions of the matrix.
◆ operator!=()
|
inline |
◆ operator==()
|
inline |
equality operators.
◆ remove_damping()
|
inline |
remove a damping.
- Parameters
-
i index to remove.
◆ serialize()
|
inline |
serialize this.
- See also
- mio::serialize
◆ set_automatic_cache_update()
|
inline |
Enable/disable automatic cache update of the dampings.
Friends And Related Function Documentation
◆ PrintTo
|
friend |
gtest printer.
Member Data Documentation
◆ m_baseline
|
private |
◆ m_dampings
|
private |
◆ m_minimum
|
private |
Generated by