Dense row-major matrix with optional GPU storage.
Backend enum for linear algebra operations.
Backend
Selects which backend handles a linalg operation.
real lu_det(const LUResult &f)
Determinant of A from its LU factorization.
constexpr Backend lapack_backend
Matrix lu_inv(const LUResult &f)
Inverse of A from its LU factorization.
void lu_solve(const LUResult &f, const Vector &b, Vector &x)
Solve A*x = b using a precomputed LU factorization.
LUResult lu(const Matrix &A, Backend backend=lapack_backend)
LU factorization of a square matrix A with partial pivoting.
Result of an LU factorization with partial pivoting (PA = LU)