![]() |
Shamrock 2025.10.0
Astrophysical Code
|
Matrix class based on std::array storage and mdspan. More...
#include <shammath/include/shammath/matrix.hpp>
Collaboration diagram for shammath::mat< T, m, n >:Public Member Functions | |
| constexpr auto | get_mdspan () |
| Get the matrix data as a mdspan. | |
| constexpr auto | get_mdspan () const |
| const overload | |
| constexpr T & | operator() (int i, int j) |
| Access the matrix entry at position (i, j) | |
| constexpr const T & | operator() (int i, int j) const |
| const overload | |
| bool | operator== (const mat< T, m, n > &other) const |
| Check if this matrix is equal to another one. | |
| mat & | operator+= (const mat &other) |
| bool | equal_at_precision (const mat< T, m, n > &other, const T precision) const |
| check if this matrix is equal to another one at a given precison | |
Public Attributes | |
| std::array< T, m *n > | data |
| The matrix data. | |
Matrix class based on std::array storage and mdspan.
| T | the type of the matrix entries |
| m | the number of rows |
| n | the number of columns |
Definition at line 36 of file matrix.hpp.
|
inline |
check if this matrix is equal to another one at a given precison
Definition at line 69 of file matrix.hpp.
|
inlineconstexpr |
Get the matrix data as a mdspan.
Definition at line 42 of file matrix.hpp.
|
inlineconstexpr |
const overload
Definition at line 47 of file matrix.hpp.
|
inlineconstexpr |
Access the matrix entry at position (i, j)
Definition at line 52 of file matrix.hpp.
Here is the call graph for this function:
|
inlineconstexpr |
|
inline |
Definition at line 60 of file matrix.hpp.
|
inline |
Check if this matrix is equal to another one.
Definition at line 58 of file matrix.hpp.
| std::array<T, m * n> shammath::mat< T, m, n >::data |
The matrix data.
Definition at line 39 of file matrix.hpp.