20 template <etl_expr AT, etl_expr LT, etl_expr UT, etl_expr PT>
21 bool lu(
const AT& A, LT& L, UT& U, PT& P);
31 template <etl_expr AT>
35 const auto n = etl::dim<0>(A);
40 for (
size_t i = 0; i < n; ++i) {
41 for (
size_t j = 0; j < n; ++j) {
42 if (A(i, j) != 0.0 && i != j) {
54 for (
size_t i = 0; i < n; ++i) {
auto pow(E &&value, T v)
Apply pow(x, v) on each element x of the ETL expression.
Definition: expression_builder.hpp:127
bool is_triangular(E &&expr)
Indicates if the given expression is a triangular matrix or not.
Definition: adapters.hpp:308
value_t< AT > det(const AT &A)
Compute the determinant of the given matrix.
Definition: det.hpp:32
bool is_permutation_matrix(E &&expr)
Indicates if the given expression represents a permutation matrix.
Definition: globals.hpp:112
Root namespace for the ETL library.
Definition: adapter.hpp:15
bool lu(const AT &A, LT &L, UT &U, PT &P)
Decomposition the matrix so that P * A = L * U.
Definition: globals.hpp:308
typename decay_traits< E >::value_type value_t
Traits to extract the value type out of an ETL type.
Definition: tmp.hpp:81
decltype(auto) force_temporary_dim_only(E &&expr)
Force a temporary out of the expression with the same dimensions, but the content is not defined...
Definition: temporary.hpp:156