10 template <
class T,
int Dim, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
13 for (
int i = 1; i < Dim; ++i) {
20 template <
class T,
int Dim, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
26 for (
int i = 1; i < U.RowCount(); ++i) {
33 template <
class T,
int Rows,
int Columns, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
34 Matrix<T, Columns, Rows, Order, Layout, Packed> Transpose(
const Matrix<T, Rows, Columns, Order, Layout, Packed>& m) {
36 for (
int i = 0; i < m.
RowCount(); ++i) {
38 result(j, i) = m(i, j);
45 template <
class T,
int Dim, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
46 Matrix<T, Dim, Dim, Order, Layout, Packed> Inverse(
const Matrix<T, Dim, Dim, Order, Layout, Packed>& m) {
53 for (
int col = 0; col < Dim; ++col) {
54 b(std::max(0, col - 1)) = 0;
57 for (
int i = 0; i < Dim; ++i) {
66 template <
class T,
int Rows,
int Columns, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
69 for (
auto& stripe : m.
stripes) {
77 template <
class T,
int Rows,
int Columns, eMatrixOrder Order, eMatrixLayout Layout,
bool Packed>
Matrix< T, Dim, Dim, Order, Layout, Packed > Inverse(const Matrix< T, Dim, Dim, Order, Layout, Packed > &m)
Returns the inverse of the matrix.
Definition: MatrixFunction.hpp:46
Matrix< T, Columns, Rows, Order, Layout, Packed > Transpose(const Matrix< T, Rows, Columns, Order, Layout, Packed > &m)
Transposes the matrix in-place.
Definition: MatrixFunction.hpp:34
Represents a vector in N-dimensional space.
Definition: Definitions.hpp:57
T NormSquared(const Matrix< T, Rows, Columns, Order, Layout, Packed > &m)
Calculates the square of the Frobenius norm of the matrix.
Definition: MatrixFunction.hpp:67
std::array< Vector< T, StripeDim, Packed >, StripeCount > stripes
Definition: MatrixImpl.hpp:46
Definition: Approx.hpp:11
T Trace(const Matrix< T, Dim, Dim, Order, Layout, Packed > &m)
Returns the trace (sum of diagonal elements) of the matrix.
Definition: MatrixFunction.hpp:11
auto DecomposeLUP(const Matrix< T, Dim, Dim, Order, Layout, Packed > &m, int &parity)
Implements LU decomposition with partial pivoting.
Definition: DecomposeLU.hpp:151
constexpr int ColumnCount() const
Returns the number of columns of the matrix.
Definition: MatrixImpl.hpp:27
T Norm(const Matrix< T, Rows, Columns, Order, Layout, Packed > &m)
Calculates the Frobenius norm of the matrix.
Definition: MatrixFunction.hpp:78
T LengthSquared(const Quaternion< T, Packed > &q)
Returns the square of the absolute value.
Definition: QuaternionFunction.hpp:53
T Determinant(const Matrix< T, Dim, Dim, Order, Layout, Packed > &m)
Returns the determinant of the matrix.
Definition: MatrixFunction.hpp:21
constexpr int RowCount() const
Returns the number of rows of the matrix.
Definition: MatrixImpl.hpp:31