![]() |
Modules | |
CustomMatrix | |
DynamicMatrix | |
HybridMatrix | |
StaticMatrix | |
Expressions | |
Classes | |
struct | blaze::DenseMatrix< MT, SO > |
Base class for dense matrices.The DenseMatrix class is a base class for all dense matrix classes. It provides an abstraction from the actual type of the dense matrix, but enables a conversion back to this type via the Matrix base class. More... | |
Enumerations | |
enum | blaze::InversionFlag { blaze::byDefault = 0, blaze::byLU = 1, blaze::byLDLT = 2, blaze::byLDLH = 3, blaze::byLLH = 4 } |
Inversion flag.The InversionFlag type enumeration represents the different types of matrix inversion algorithms that are available within the Blaze library. The following flags are available: More... | |
Functions | |
template<typename T1 , typename T2 , bool SO> | |
EnableIf< IsNumeric< T1 >, bool >::Type | blaze::operator== (T1 scalar, const DenseMatrix< T2, SO > &mat) |
Equality operator for the comparison of a scalar value and a dense matrix. More... | |
template<typename T1 , typename T2 , bool SO> | |
EnableIf< IsNumeric< T1 >, bool >::Type | blaze::operator!= (T1 scalar, const DenseMatrix< T2, SO > &mat) |
Inequality operator for the comparison of a scalar value and a dense matrix. More... | |
template<typename MT , bool SO> | |
const DMatAbsExpr< MT, SO > | blaze::abs (const DenseMatrix< MT, SO > &dm) |
Returns a matrix containing the absolute values of each single element of dm. More... | |
template<typename MT , bool SO> | |
const DMatConjExpr< MT, SO > | blaze::conj (const DenseMatrix< MT, SO > &dm) |
Returns a matrix containing the complex conjugate of each single element of dm. More... | |
template<typename MT , bool SO> | |
const CTransExprTrait< MT >::Type | blaze::ctrans (const DenseMatrix< MT, SO > &dm) |
Returns the conjugate transpose matrix of dm. More... | |
template<typename T1 , typename T2 , bool SO> | |
const DMatDMatAddExpr< T1, T2, SO > | blaze::operator+ (const DenseMatrix< T1, SO > &lhs, const DenseMatrix< T2, SO > &rhs) |
Addition operator for the addition of two dense matrices with identical storage order ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatDMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of two row-major dense matrices ( ![]() | |
template<typename T1 , typename T2 , bool SO> | |
const DMatDMatSubExpr< T1, T2, SO > | blaze::operator- (const DenseMatrix< T1, SO > &lhs, const DenseMatrix< T2, SO > &rhs) |
Subtraction operator for the subtraction of two dense matrices with identical storage order ( ![]() | |
template<typename MT , bool SO> | |
const DMatEvalExpr< MT, SO > | blaze::eval (const DenseMatrix< MT, SO > &dm) |
Forces the evaluation of the given dense matrix expression dm. More... | |
template<typename MT , bool SO> | |
const ImagExprTrait< MT >::Type | blaze::imag (const DenseMatrix< MT, SO > &dm) |
Returns a matrix containing the imaginary part of each single element of dm. More... | |
template<typename MT , bool SO> | |
const DMatInvExpr< MT, SO > | blaze::inv (const DenseMatrix< MT, SO > &dm) |
Calculation of the inverse of the given dense matrix. More... | |
template<typename MT , bool SO> | |
const RealExprTrait< MT >::Type | blaze::real (const DenseMatrix< MT, SO > &dm) |
Returns a matrix containing the real part of each single element of dm. More... | |
template<typename T1 , bool SO, typename T2 > | |
const EnableIf< IsNumeric< T2 >, typename DivExprTrait< T1, T2 >::Type >::Type | blaze::operator/ (const DenseMatrix< T1, SO > &mat, T2 scalar) |
Division operator for the division of a dense matrix by a scalar value ( ![]() | |
template<typename MT , bool SO> | |
const DMatScalarMultExpr< MT, typename UnderlyingBuiltin< MT >::Type, SO > | blaze::operator- (const DenseMatrix< MT, SO > &dm) |
Unary minus operator for the negation of a dense matrix ( ![]() | |
template<typename T1 , bool SO, typename T2 > | |
const EnableIf< IsNumeric< T2 >, typename MultExprTrait< T1, T2 >::Type >::Type | blaze::operator* (const DenseMatrix< T1, SO > &mat, T2 scalar) |
Multiplication operator for the multiplication of a dense matrix and a scalar value ( ![]() | |
template<typename T1 , typename T2 , bool SO> | |
const EnableIf< IsNumeric< T1 >, typename MultExprTrait< T1, T2 >::Type >::Type | blaze::operator* (T1 scalar, const DenseMatrix< T2, SO > &mat) |
Multiplication operator for the multiplication of a scalar value and a dense matrix ( ![]() | |
template<typename MT , bool SO> | |
const DMatSerialExpr< MT, SO > | blaze::serial (const DenseMatrix< MT, SO > &dm) |
Forces the serial evaluation of the given dense matrix expression dm. More... | |
template<typename T1 , typename T2 , bool SO> | |
const DMatSMatAddExpr< T1, T2, SO > | blaze::operator+ (const DenseMatrix< T1, SO > &lhs, const SparseMatrix< T2, SO > &rhs) |
Addition operator for the addition of a dense matrix and a sparse matrix ( ![]() | |
template<typename T1 , typename T2 , bool SO> | |
const DMatSMatAddExpr< T2, T1, SO > | blaze::operator+ (const SparseMatrix< T1, SO > &lhs, const DenseMatrix< T2, SO > &rhs) |
Addition operator for the addition of a sparse matrix and a dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatSMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, false > &lhs, const SparseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of a row-major dense matrix and a row-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 , bool SO> | |
const DMatSMatSubExpr< T1, T2, SO > | blaze::operator- (const DenseMatrix< T1, SO > &lhs, const SparseMatrix< T2, SO > &rhs) |
Subtraction operator for the subtraction of a dense matrix and a sparse matrix with identical storage order ( ![]() | |
template<typename T1 , typename T2 > | |
EnableIf< And< Not< IsSymmetric< T1 > >, Not< IsSymmetric< T2 > > >, const DMatTDMatAddExpr< T1, T2 > >::Type | blaze::operator+ (const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, true > &rhs) |
Addition operator for the addition of a row-major and a colum-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
EnableIf< And< Not< IsSymmetric< T1 > >, Not< IsSymmetric< T2 > > >, const DMatTDMatAddExpr< T2, T1 > >::Type | blaze::operator+ (const DenseMatrix< T1, true > &lhs, const DenseMatrix< T2, false > &rhs) |
Addition operator for the addition of a column-major and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatTDMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of a row-major dense matrix and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
EnableIf< And< Not< IsSymmetric< T1 > >, Not< IsSymmetric< T2 > > >, const DMatTDMatSubExpr< T1, T2 > >::Type | blaze::operator- (const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, true > &rhs) |
Subtraction operator for the subtraction of a row-major and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
EnableIf< And< Not< IsSymmetric< T1 > >, Not< IsSymmetric< T2 > > >, const DMatTDMatSubExpr< T1, T2 > >::Type | blaze::operator- (const DenseMatrix< T1, true > &lhs, const DenseMatrix< T2, false > &rhs) |
Subtraction operator for the subtraction of a column-major and a row-major dense matrix ( ![]() | |
template<typename MT , bool SO> | |
const DMatTransExpr< MT,!SO > | blaze::trans (const DenseMatrix< MT, SO > &dm) |
Calculation of the transpose of the given dense matrix. More... | |
template<typename T1 , typename T2 > | |
const DMatTSMatAddExpr< T1, T2 > | blaze::operator+ (const DenseMatrix< T1, false > &lhs, const SparseMatrix< T2, true > &rhs) |
Addition operator for the addition of a row-major dense matrix and a column-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatTSMatAddExpr< T1, T2 > | blaze::operator+ (const SparseMatrix< T2, true > &lhs, const DenseMatrix< T1, false > &rhs) |
Addition operator for the addition of a column-major sparse matrix and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatTSMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, false > &lhs, const SparseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of a row-major dense matrix and a column-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DMatTSMatSubExpr< T1, T2 > | blaze::operator- (const DenseMatrix< T1, false > &lhs, const SparseMatrix< T2, true > &rhs) |
Subtraction operator for the subtraction of a row-major dense matrix and a column-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DVecTDVecMultExpr< T1, T2 > | blaze::operator* (const DenseVector< T1, false > &lhs, const DenseVector< T2, true > &rhs) |
Multiplication operator for the outer product of two dense vectors ( ![]() | |
template<typename T1 , typename T2 > | |
const SMatDMatMultExpr< T1, T2 > | blaze::operator* (const SparseMatrix< T1, false > &lhs, const DenseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of a row-major sparse matrix and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 , bool SO> | |
const SMatDMatSubExpr< T1, T2, SO > | blaze::operator- (const SparseMatrix< T1, SO > &lhs, const DenseMatrix< T2, SO > &rhs) |
Subtraction operator for the subtraction of a sparse matrix and a dense matrix with identical storage order ( ![]() | |
template<typename T1 , typename T2 > | |
const SMatTDMatMultExpr< T1, T2 > | blaze::operator* (const SparseMatrix< T1, false > &lhs, const DenseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of a row-major sparse matrix and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const SMatTDMatSubExpr< T1, T2 > | blaze::operator- (const SparseMatrix< T1, false > &lhs, const DenseMatrix< T2, true > &rhs) |
Subtraction operator for the subtraction of a row-major sparse matrix and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatDMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, true > &lhs, const DenseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of a column-major dense matrix and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatSMatAddExpr< T1, T2 > | blaze::operator+ (const DenseMatrix< T1, true > &lhs, const SparseMatrix< T2, false > &rhs) |
Addition operator for the addition of a column-major dense matrix and a row-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatSMatAddExpr< T1, T2 > | blaze::operator+ (const SparseMatrix< T2, false > &lhs, const DenseMatrix< T1, true > &rhs) |
Addition operator for the addition of a row-major sparse matrix and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatSMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, true > &lhs, const SparseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of a column-major dense matrix and a row-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatSMatSubExpr< T1, T2 > | blaze::operator- (const DenseMatrix< T1, true > &lhs, const SparseMatrix< T2, false > &rhs) |
Subtraction operator for the subtraction of a column-major dense matrix and a row-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatTDMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, true > &lhs, const DenseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of two column-major dense matrices ( ![]() | |
template<typename T1 , typename T2 > | |
const TDMatTSMatMultExpr< T1, T2 > | blaze::operator* (const DenseMatrix< T1, true > &lhs, const SparseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of a column-major dense matrix and a column-major sparse matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DisableIf< IsMatMatMultExpr< T2 >, TDVecTDMatMultExpr< T1, T2 > >::Type | blaze::operator* (const DenseVector< T1, true > &vec, const DenseMatrix< T2, true > &mat) |
Multiplication operator for the multiplication of a transpose dense vector and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TSMatDMatMultExpr< T1, T2 > | blaze::operator* (const SparseMatrix< T1, true > &lhs, const DenseMatrix< T2, false > &rhs) |
Multiplication operator for the multiplication of a column-major sparse matrix and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TSMatDMatSubExpr< T1, T2 > | blaze::operator- (const SparseMatrix< T1, true > &lhs, const DenseMatrix< T2, false > &rhs) |
Subtraction operator for the subtraction of a column-major sparse matrix and a row-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const TSMatTDMatMultExpr< T1, T2 > | blaze::operator* (const SparseMatrix< T1, true > &lhs, const DenseMatrix< T2, true > &rhs) |
Multiplication operator for the multiplication of a column-major sparse matrix and a column-major dense matrix ( ![]() | |
template<typename T1 , typename T2 > | |
const DisableIf< IsMatMatMultExpr< T2 >, TSVecDMatMultExpr< T1, T2 > >::Type | blaze::operator* (const SparseVector< T1, true > &vec, const DenseMatrix< T2, false > &mat) |
Multiplication operator for the multiplication of a transpose sparse vector and a row-major dense matrix ( ![]() | |
DenseMatrix operators | |
template<typename T1 , typename T2 > | |
bool | blaze::operator== (const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, false > &rhs) |
Equality operator for the comparison of two rwo-major dense matrices. More... | |
template<typename T1 , typename T2 > | |
bool | blaze::operator== (const DenseMatrix< T1, true > &lhs, const DenseMatrix< T2, true > &rhs) |
Equality operator for the comparison of two column-major dense matrices. More... | |
template<typename T1 , typename T2 , bool SO> | |
bool | blaze::operator== (const DenseMatrix< T1, SO > &lhs, const DenseMatrix< T2,!SO > &rhs) |
Equality operator for the comparison of two dense matrices with different storage order. More... | |
template<typename T1 , typename T2 , bool SO> | |
bool | blaze::operator== (const DenseMatrix< T1, SO > &lhs, const SparseMatrix< T2, false > &rhs) |
Equality operator for the comparison of a dense matrix and a row-major sparse matrix. More... | |
template<typename T1 , typename T2 , bool SO> | |
bool | blaze::operator== (const DenseMatrix< T1, SO > &lhs, const SparseMatrix< T2, true > &rhs) |
Equality operator for the comparison of a dense matrix and a column-major sparse matrix. More... | |
template<typename T1 , bool SO1, typename T2 , bool SO2> | |
bool | blaze::operator== (const SparseMatrix< T1, SO1 > &lhs, const DenseMatrix< T2, SO2 > &rhs) |
Equality operator for the comparison of a sparse matrix and a dense matrix. More... | |
template<typename T1 , typename T2 > | |
EnableIf< IsNumeric< T2 >, bool >::Type | blaze::operator== (const DenseMatrix< T1, false > &mat, T2 scalar) |
Equality operator for the comparison of a row-major dense matrix and a scalar value. More... | |
template<typename T1 , typename T2 > | |
EnableIf< IsNumeric< T2 >, bool >::Type | blaze::operator== (const DenseMatrix< T1, true > &mat, T2 scalar) |
Equality operator for the comparison of a column-major dense matrix and a scalar value. More... | |
template<typename T1 , bool SO1, typename T2 , bool SO2> | |
bool | blaze::operator!= (const DenseMatrix< T1, SO1 > &lhs, const DenseMatrix< T2, SO2 > &rhs) |
Inequality operator for the comparison of two dense matrices. More... | |
template<typename T1 , bool SO1, typename T2 , bool SO2> | |
bool | blaze::operator!= (const DenseMatrix< T1, SO1 > &lhs, const SparseMatrix< T2, SO2 > &rhs) |
Inequality operator for the comparison of a dense matrix and a sparse matrix. More... | |
template<typename T1 , bool SO1, typename T2 , bool SO2> | |
bool | blaze::operator!= (const SparseMatrix< T1, SO1 > &lhs, const DenseMatrix< T2, SO2 > &rhs) |
Inequality operator for the comparison of a sparse matrix and a dense matrix. More... | |
template<typename T1 , typename T2 , bool SO> | |
EnableIf< IsNumeric< T2 >, bool >::Type | blaze::operator!= (const DenseMatrix< T1, SO > &mat, T2 scalar) |
Inequality operator for the comparison of a dense matrix and a scalar value. More... | |
DenseMatrix functions | |
template<typename MT , bool SO> | |
bool | blaze::isnan (const DenseMatrix< MT, SO > &dm) |
Checks the given dense matrix for not-a-number elements. More... | |
template<typename MT , bool SO> | |
bool | blaze::isSymmetric (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is symmetric. More... | |
template<typename MT , bool SO> | |
bool | blaze::isHermitian (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is Hermitian. More... | |
template<typename MT , bool SO> | |
bool | blaze::isUniform (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is a uniform matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isLower (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is a lower triangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isUniLower (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is a lower unitriangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isStrictlyLower (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is a strictly lower triangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isUpper (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is an upper triangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isUniUpper (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is an upper unitriangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isStrictlyUpper (const DenseMatrix< MT, SO > &dm) |
Checks if the given dense matrix is a strictly upper triangular matrix. More... | |
template<typename MT , bool SO> | |
bool | blaze::isDiagonal (const DenseMatrix< MT, SO > &dm) |
Checks if the give dense matrix is diagonal. More... | |
template<typename MT , bool SO> | |
bool | blaze::isIdentity (const DenseMatrix< MT, SO > &dm) |
Checks if the give dense matrix is an identity matrix. More... | |
template<typename MT , bool SO> | |
const MT::ElementType | blaze::min (const DenseMatrix< MT, SO > &dm) |
Returns the smallest element of the dense matrix. More... | |
template<typename MT , bool SO> | |
const MT::ElementType | blaze::max (const DenseMatrix< MT, SO > &dm) |
Returns the largest element of the dense matrix. More... | |
Inversion functions | |
template<typename MT , bool SO> | |
void | blaze::invert (DenseMatrix< MT, SO > &dm) |
In-place inversion of the given dense matrix. More... | |
template<InversionFlag IF, typename MT , bool SO> | |
void | blaze::invert (DenseMatrix< MT, SO > &dm) |
In-place inversion of the given dense matrix. More... | |
LLH decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , bool SO2> | |
void | blaze::llh (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO2 > &L) |
Cholesky (LLH) decomposition of the given dense matrix. More... | |
LQ decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , bool SO2, typename MT3 , bool SO3> | |
void | blaze::lq (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO2 > &L, DenseMatrix< MT3, SO3 > &Q) |
LQ decomposition of the given dense matrix. More... | |
LU decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , typename MT3 , typename MT4 , bool SO2> | |
void | blaze::lu (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO1 > &L, DenseMatrix< MT3, SO1 > &U, Matrix< MT4, SO2 > &P) |
LU decomposition of the given dense matrix. More... | |
QL decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , bool SO2, typename MT3 , bool SO3> | |
void | blaze::ql (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO2 > &Q, DenseMatrix< MT3, SO3 > &L) |
QL decomposition of the given dense matrix. More... | |
QR decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , bool SO2, typename MT3 , bool SO3> | |
void | blaze::qr (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO2 > &Q, DenseMatrix< MT3, SO3 > &R) |
QR decomposition of the given dense matrix. More... | |
RQ decomposition functions | |
template<typename MT1 , bool SO1, typename MT2 , bool SO2, typename MT3 , bool SO3> | |
void | blaze::rq (const DenseMatrix< MT1, SO1 > &A, DenseMatrix< MT2, SO2 > &R, DenseMatrix< MT3, SO3 > &Q) |
RQ decomposition of the given dense matrix. More... | |
Determinant functions | |
template<typename MT , bool SO> | |
MT::ElementType | blaze::det (const DenseMatrix< MT, SO > &dm) |
Computation of the determinant of the given dense square matrix. More... | |
enum blaze::InversionFlag |
Inversion flag.The InversionFlag type enumeration represents the different types of matrix inversion algorithms that are available within the Blaze library. The following flags are available:
L
, an upper triangular matrix U
, and a permutation matrix P
( P
is the identity matrix.U
(or L
) is a product of permutation and unit upper (lower) triangular matrices, and D
is symmetric and block diagonal with 1-by-1 and 2-by-2 diagonal blocks.U
(or L
) is a product of permutation and unit upper (lower) triangular matrices, and D
is Hermitian and block diagonal with 1-by-1 and 2-by-2 diagonal blocks.L
is a lower triangular matrix, or U
is an upper triangular matrix.
|
inline |
Returns a matrix containing the absolute values of each single element of dm.
dm | The input matrix. |
The abs function calculates the absolute value of each element of the input matrix dm. The function returns an expression representing this operation.
The following example demonstrates the use of the abs function:
|
inline |
Returns a matrix containing the complex conjugate of each single element of dm.
dm | The input matrix. |
The conj function calculates the complex conjugate of each element of the input matrix dm. The function returns an expression representing this operation.
The following example demonstrates the use of the conj function:
|
inline |
Returns the conjugate transpose matrix of dm.
dm | The input matrix. |
The ctrans function returns an expression representing the conjugate transpose (also called adjoint matrix, Hermitian conjugate matrix or transjugate matrix) of the given input matrix dm.
The following example demonstrates the use of the ctrans function:
Note that the ctrans function has the same effect as manually applying the conj and trans function in any order:
|
inline |
Computation of the determinant of the given dense square matrix.
dm | The given dense matrix. |
std::invalid_argument | Invalid non-square matrix provided. |
This function computes the determinant of the given dense square matrix. The computation fails if the given matrix is not a square matrix. In this case either a compilation error is created (if possible) or a std::invalid_argument exception is thrown.
|
inline |
Forces the evaluation of the given dense matrix expression dm.
dm | The input matrix. |
The eval function forces the evaluation of the given dense matrix expression dm. The function returns an expression representing the operation.
The following example demonstrates the use of the eval function
|
inline |
Returns a matrix containing the imaginary part of each single element of dm.
dm | The input matrix. |
The imag function calculates the imaginary part of each element of the input matrix dm. The function returns an expression representing this operation.
The following example demonstrates the use of the imag function:
|
inline |
Calculation of the inverse of the given dense matrix.
dm | The dense matrix to be inverted. |
This function returns an expression representing the inverse of the given dense matrix:
float
, double
, complex<float>
or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!inv()
function. Also, it is not possible to access individual elements via the function call operator on the expression object:
|
inline |
In-place inversion of the given dense matrix.
dm | The dense matrix to be inverted. |
std::invalid_argument | Inversion of singular matrix failed. |
std::invalid_argument | Invalid non-square matrix provided. |
This function inverts the given dense square matrix. The matrix inversion fails if ...
In all failure cases either a compilation error is created if the failure can be predicted at compile time or a std::invalid_argument exception is thrown.
float
, double
, complex<float>
or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!
|
inline |
In-place inversion of the given dense matrix.
dm | The dense matrix to be inverted. |
std::invalid_argument | Inversion of singular matrix failed. |
std::invalid_argument | Invalid non-square matrix provided. |
This function inverts the given dense matrix by means of the specified matrix inversion algorithm IF:
The matrix inversion fails if ...
In all failure cases either a compilation error is created if the failure can be predicted at compile time or a std::invalid_argument exception is thrown.
float
, double
, complex<float>
or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!bool blaze::isDiagonal | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the give dense matrix is diagonal.
dm | The dense matrix to be checked. |
This function tests whether the matrix is diagonal, i.e. if the non-diagonal elements are default elements. In case of integral or floating point data types, a diagonal matrix has the form
or
matrices are considered as trivially diagonal. The following example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a diagonal matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isHermitian | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is Hermitian.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is an Hermitian matrix. The matrix is considered to be an Hermitian matrix if it is a square matrix whose conjugate transpose is equal to itself ( ), i.e. each matrix element
is equal to the complex conjugate of the element
. The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in an Hermitian matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isIdentity | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the give dense matrix is an identity matrix.
dm | The dense matrix to be checked. |
This function tests whether the matrix is an identity matrix, i.e. if the diagonal elements are 1 and the non-diagonal elements are 0. In case of integral or floating point data types, an identity matrix has the form
The following example demonstrates the use of the function:
It is also possible to check if a matrix expression results in an identity matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isLower | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is a lower triangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is a lower triangular matrix. The matrix is considered to be lower triangular if it is a square matrix of the form
or
matrices are considered as trivially lower triangular. The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a lower triangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isnan | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks the given dense matrix for not-a-number elements.
dm | The matrix to be checked for not-a-number elements. |
This function checks the dense matrix for not-a-number (NaN) elements. If at least one element of the matrix is not-a-number, the function returns true, otherwise it returns false.
Note that this function only works for matrices with floating point elements. The attempt to use it for a matrix with a non-floating point element type results in a compile time error.
bool blaze::isStrictlyLower | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is a strictly lower triangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is a strictly lower triangular matrix. The matrix is considered to be strictly lower triangular if it is a square matrix of the form
The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a strictly lower triangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isStrictlyUpper | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is a strictly upper triangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is a strictly upper triangular matrix. The matrix is considered to be strictly upper triangular if it is a square matrix of the form
The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a strictly upper triangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isSymmetric | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is symmetric.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is symmetric. The matrix is considered to be symmetric if it is a square matrix whose transpose is equal to itself ( ). The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a symmetric matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isUniform | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is a uniform matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is a uniform matrix. The matrix is considered to be uniform if all its elements are identical. The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a uniform matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isUniLower | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is a lower unitriangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is a lower unitriangular matrix. The matrix is considered to be lower unitriangular if it is a square matrix of the form
The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in a lower unitriangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isUniUpper | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is an upper unitriangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is an upper unitriangular matrix. The matrix is considered to be upper unitriangular if it is a square matrix of the form
The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in an upper unitriangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
bool blaze::isUpper | ( | const DenseMatrix< MT, SO > & | dm | ) |
Checks if the given dense matrix is an upper triangular matrix.
dm | The dense matrix to be checked. |
This function checks if the given dense matrix is an upper triangular matrix. The matrix is considered to be upper triangular if it is a square matrix of the form
or
matrices are considered as trivially upper triangular. The following code example demonstrates the use of the function:
It is also possible to check if a matrix expression results in an upper triangular matrix:
However, note that this might require the complete evaluation of the expression, including the generation of a temporary matrix.
void blaze::llh | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO2 > & | L | ||
) |
Cholesky (LLH) decomposition of the given dense matrix.
A | The matrix to be decomposed. |
L | The resulting lower triangular matrix. |
std::invalid_argument | Invalid non-square matrix provided. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Decomposition of singular matrix failed. |
This function performs the dense matrix Cholesky (LLH) decomposition of a positive definite n-by-n matrix. The resulting decomposition has the form
where L
is a lower triangular n-by-n matrix. The decomposition is written to the matrix L
, which is resized to the correct dimensions (if possible and necessary).
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Example:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!void blaze::lq | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO2 > & | L, | ||
DenseMatrix< MT3, SO3 > & | Q | ||
) |
LQ decomposition of the given dense matrix.
A | The matrix to be decomposed. |
L | The resulting L matrix. |
Q | The resulting Q matrix. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Square matrix cannot be resized to m-by-n. |
This function performs the dense matrix LQ decomposition of a general m-by-n matrix. The resulting decomposition has the form
where L
is a lower trapezoidal m-by-min(m,n) matrix and Q
is a general min(m,n)-by-n matrix. The decomposition is written to the two distinct matrices L
and Q
, which are resized to the correct dimensions (if possible and necessary).
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Example:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!void blaze::lu | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO1 > & | L, | ||
DenseMatrix< MT3, SO1 > & | U, | ||
Matrix< MT4, SO2 > & | P | ||
) |
LU decomposition of the given dense matrix.
A | The matrix to be decomposed. |
L | The resulting lower triangular matrix. |
U | The resulting upper triangular matrix. |
P | The resulting permutation matrix. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Square matrix cannot be resized to m-by-n. |
This function performs the dense matrix (P)LU decomposition of a general m-by-n matrix. The resulting decomposition is written to the three distinct matrices L
, U
, and P
, which are resized to the correct dimensions (if possible and necessary).
In case of a column-major matrix the algorithm performs the decomposition using partial pivoting with row interchanges. The resulting decomposition has the form
where P
is an m-by-m permutation matrix, which represents the pivoting indices for the applied row interchanges, L
is a lower triangular matrix (lower trapezoidal if m > n), and U
is an upper triangular matrix (upper trapezoidal if m < n).
In case of a row-major matrix the algorithm performs the decomposition using partial pivoting with column interchanges. The resulting decomposition has the form
where L
is a lower triangular matrix (lower trapezoidal if m > n), U
is an upper triangular matrix (upper trapezoidal if m < n), and P
is an n-by-n permutation matrix, which represents the pivoting indices for the applied column interchanges.
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Examples:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!const MT::ElementType blaze::max | ( | const DenseMatrix< MT, SO > & | dm | ) |
Returns the largest element of the dense matrix.
dm | The given dense matrix. |
This function returns the largest element of the given dense matrix. This function can only be used for element types that support the smaller-than relationship. In case the matrix currently has either 0 rows or 0 columns, the returned value is the default value (e.g. 0 in case of fundamental data types).
const MT::ElementType blaze::min | ( | const DenseMatrix< MT, SO > & | dm | ) |
Returns the smallest element of the dense matrix.
dm | The given dense matrix. |
This function returns the smallest element of the given dense matrix. This function can only be used for element types that support the smaller-than relationship. In case the matrix currently has either 0 rows or 0 columns, the returned value is the default value (e.g. 0 in case of fundamental data types).
|
inline |
Inequality operator for the comparison of two dense matrices.
lhs | The left-hand side dense matrix for the comparison. |
rhs | The right-hand side dense matrix for the comparison. |
|
inline |
Inequality operator for the comparison of a dense matrix and a sparse matrix.
lhs | The left-hand side dense matrix for the comparison. |
rhs | The right-hand side sparse matrix for the comparison. |
|
inline |
Inequality operator for the comparison of a sparse matrix and a dense matrix.
lhs | The left-hand side sparse matrix for the comparison. |
rhs | The right-hand side dense matrix for the comparison. |
|
inline |
Inequality operator for the comparison of a dense matrix and a scalar value.
mat | The left-hand side dense matrix for the comparison. |
scalar | The right-hand side scalar value for the comparison. |
If one value of the matrix is inequal to the scalar value, the inequality test returns true, otherwise false. Note that this function can only be used with built-in, numerical data types!
|
inline |
Inequality operator for the comparison of a scalar value and a dense matrix.
scalar | The left-hand side scalar value for the comparison. |
mat | The right-hand side dense matrix for the comparison. |
If one value of the matrix is inequal to the scalar value, the inequality test returns true, otherwise false. Note that this function can only be used with built-in, numerical data types!
|
inline |
Multiplication operator for the multiplication of a dense matrix and a scalar value ( ).
mat | The left-hand side dense matrix for the multiplication. |
scalar | The right-hand side scalar value for the multiplication. |
This operator represents the multiplication between a dense matrix and a scalar value:
The operator returns an expression representing a dense matrix of the higher-order element type of the involved data types T1::ElementType and T2. Note that this operator only works for scalar values of built-in data type.
|
inline |
Multiplication operator for the multiplication of a scalar value and a dense matrix ( ).
scalar | The left-hand side scalar value for the multiplication. |
mat | The right-hand side dense matrix for the multiplication. |
This operator represents the multiplication between a a scalar value and dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the involved data types T1 and T2::ElementType. Note that this operator only works for scalar values of built-in data type.
|
inline |
Multiplication operator for the multiplication of a row-major dense matrix and a row-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the multiplication. |
rhs | The right-hand side sparse matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a row-major dense matrix and a row-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the outer product of two dense vectors ( ).
lhs | The left-hand side dense vector for the outer product. |
rhs | The right-hand side transpose dense vector for the outer product. |
This operator represents the outer product between a dense vector and a transpose dense vector:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved element types T1::ElementType and T2::ElementType. Both dense vector types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
|
inline |
Multiplication operator for the multiplication of a transpose sparse vector and a row-major dense matrix ( ).
vec | The left-hand side transpose sparse vector for the multiplication. |
mat | The right-hand side row-major dense matrix for the multiplication. |
std::invalid_argument | Vector and matrix sizes do not match. |
This operator represents the multiplication between a transpose sparse vector and a row-major dense matrix:
The operator returns an expression representing a transpose sparse vector of the higher-order element type of the two involved element types T1::ElementType and T2::ElementType. Both the dense matrix type T1 and the dense vector type T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current size of the vector vec doesn't match the current number of rows of the matrix mat, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a column-major dense matrix and a column-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the multiplication. |
rhs | The right-hand side sparse matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a column-major dense matrix and a column-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a row-major sparse matrix and a row-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the multiplication. |
rhs | The right-hand side dense matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a row-major sparse matrix and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a column-major sparse matrix and a row-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the multiplication. |
rhs | The right-hand side dense matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a column-major sparse matrix and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a row-major dense matrix and a column-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the multiplication. |
rhs | The right-hand side sparse matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a row-major dense matrix and a column-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a row-major sparse matrix and a column-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the multiplication. |
rhs | The right-hand side dense matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a row-major sparse matrix and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a column-major sparse matrix and a column-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the multiplication. |
rhs | The right-hand side dense matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a column-major sparse matrix and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a column-major dense matrix and a row-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the multiplication. |
rhs | The right-hand side sparse matrix for the multiplication. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the multiplication of a column-major dense matrix and a row-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a transpose dense vector and a column-major dense matrix ( ).
vec | The left-hand side transpose dense vector for the multiplication. |
mat | The right-hand side column-major dense matrix for the multiplication. |
std::invalid_argument | Vector and matrix sizes do not match. |
This operator represents the multiplication between a transpose dense vector and a column-major dense matrix:
The operator returns an expression representing a transpose dense vector of the higher-order element type of the two involved element types T1::ElementType and T2::ElementType. Both the dense matrix type T1 and the dense vector type T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current size of the vector vec doesn't match the current number of rows of the matrix mat, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of two row-major dense matrices ( ).
lhs | The left-hand side matrix for the multiplication. |
rhs | The right-hand side matrix for the multiplication. |
This operator represents the multiplication of two row-major dense matrices:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current number of columns of lhs and the current number of rows of rhs don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a row-major dense matrix and a column-major dense matrix ( ).
lhs | The left-hand side matrix for the multiplication. |
rhs | The right-hand side matrix for the multiplication. |
This operator represents the multiplication of a row-major dense matrix and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current number of columns of lhs and the current number of rows of rhs don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of two column-major dense matrices ( ).
lhs | The left-hand side matrix for the multiplication. |
rhs | The right-hand side matrix for the multiplication. |
This operator represents the multiplication of two column-major dense matrices:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current number of columns of lhs and the current number of rows of rhs don't match, a std::invalid_argument is thrown.
|
inline |
Multiplication operator for the multiplication of a column-major dense matrix and a row-major dense matrix ( ).
lhs | The left-hand side matrix for the multiplication. |
rhs | The right-hand side matrix for the multiplication. |
This operator represents the multiplication of a column-major dense matrix and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the MultTrait class template.
In case the current number of columns of lhs and the current number of rows of rhs don't match, a std::invalid_argument is thrown.
|
inline |
Addition operator for the addition of a dense matrix and a sparse matrix ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side sparse matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a dense matrix and a sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
const TDMatSMatAddExpr<T1,T2> blaze::operator+ | ( | const DenseMatrix< T1, true > & | lhs, |
const SparseMatrix< T2, false > & | rhs | ||
) |
Addition operator for the addition of a column-major dense matrix and a row-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side sparse matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a column-major dense matrix and a row-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
const DMatTSMatAddExpr<T1,T2> blaze::operator+ | ( | const DenseMatrix< T1, false > & | lhs, |
const SparseMatrix< T2, true > & | rhs | ||
) |
Addition operator for the addition of a row-major dense matrix and a column-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side sparse matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a row-major dense matrix and a column-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Addition operator for the addition of a sparse matrix and a dense matrix ( ).
lhs | The left-hand side sparse matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a sparse matrix and a dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
const DMatTSMatAddExpr<T1,T2> blaze::operator+ | ( | const SparseMatrix< T2, true > & | lhs, |
const DenseMatrix< T1, false > & | rhs | ||
) |
Addition operator for the addition of a column-major sparse matrix and a row-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a column-major sparse matrix and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
const TDMatSMatAddExpr<T1,T2> blaze::operator+ | ( | const SparseMatrix< T2, false > & | lhs, |
const DenseMatrix< T1, true > & | rhs | ||
) |
Addition operator for the addition of a row-major sparse matrix and a column-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the addition of a row-major sparse matrix and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Addition operator for the addition of a row-major and a colum-major dense matrix ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the addition of a row-major and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Addition operator for the addition of a column-major and a row-major dense matrix ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the addition of a column-major and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Addition operator for the addition of two dense matrices with identical storage order ( ).
lhs | The left-hand side dense matrix for the matrix addition. |
rhs | The right-hand side dense matrix to be added to the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the addition of two dense matrices with identical storage order:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the AddTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a sparse matrix and a dense matrix with identical storage order ( ).
lhs | The left-hand side sparse matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the sparse matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a sparse matrix and a dense matrix with identical storage order:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a column-major sparse matrix and a row-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the sparse matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a column-major sparse matrix and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a row-major sparse matrix and a column-major dense matrix ( ).
lhs | The left-hand side sparse matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the sparse matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a row-major sparse matrix and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a dense matrix and a sparse matrix with identical storage order ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side sparse matrix to be subtracted from the dense matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a dense matrix and a sparse matrix with identical storage order:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a column-major dense matrix and a row-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side sparse matrix to be subtracted from the dense matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a column-major dense matrix and a row-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a row-major dense matrix and a column-major sparse matrix ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side sparse matrix to be subtracted from the dense matrix. |
std::invalid_argument | Matrix sizes do not match. |
This operator represents the subtraction of a row-major dense matrix and a column-major sparse matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current sizes of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a row-major and a column-major dense matrix ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the subtraction of a row-major and a column-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Subtraction operator for the subtraction of a column-major and a row-major dense matrix ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the subtraction of a column-major and a row-major dense matrix:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Unary minus operator for the negation of a dense matrix ( ).
dm | The dense matrix to be negated. |
This operator represents the negation of a dense matrix:
The operator returns an expression representing the negation of the given dense matrix.
|
inline |
Subtraction operator for the subtraction of two dense matrices with identical storage order ( ).
lhs | The left-hand side dense matrix for the matrix subtraction. |
rhs | The right-hand side dense matrix to be subtracted from the left-hand side matrix. |
std::invalid_argument | Matrix sizes do not match |
This operator represents the subtraction of two dense matrices with identical storage order:
The operator returns an expression representing a dense matrix of the higher-order element type of the two involved matrix element types T1::ElementType and T2::ElementType. Both matrix types T1 and T2 as well as the two element types T1::ElementType and T2::ElementType have to be supported by the SubTrait class template.
In case the current number of rows and columns of the two given matrices don't match, a std::invalid_argument is thrown.
|
inline |
Division operator for the division of a dense matrix by a scalar value ( ).
mat | The left-hand side dense matrix for the division. |
scalar | The right-hand side scalar value for the division. |
This operator represents the division of a dense matrix by a scalar value:
The operator returns an expression representing a dense matrix of the higher-order element type of the involved data types T1::ElementType and T2. Note that this operator only works for scalar values of built-in data type.
|
inline |
Equality operator for the comparison of two rwo-major dense matrices.
lhs | The left-hand side matrix for the comparison. |
rhs | The right-hand side matrix for the comparison. |
|
inline |
Equality operator for the comparison of two column-major dense matrices.
lhs | The left-hand side matrix for the comparison. |
rhs | The right-hand side matrix for the comparison. |
|
inline |
Equality operator for the comparison of two dense matrices with different storage order.
lhs | The left-hand side matrix for the comparison. |
rhs | The right-hand side matrix for the comparison. |
|
inline |
Equality operator for the comparison of a dense matrix and a row-major sparse matrix.
lhs | The left-hand side dense matrix for the comparison. |
rhs | The right-hand side row-major sparse matrix for the comparison. |
|
inline |
Equality operator for the comparison of a dense matrix and a column-major sparse matrix.
lhs | The left-hand side dense matrix for the comparison. |
rhs | The right-hand side column-major sparse matrix for the comparison. |
|
inline |
Equality operator for the comparison of a sparse matrix and a dense matrix.
lhs | The left-hand side sparse matrix for the comparison. |
rhs | The right-hand side dense matrix for the comparison. |
|
inline |
Equality operator for the comparison of a row-major dense matrix and a scalar value.
mat | The left-hand side row-major dense matrix for the comparison. |
scalar | The right-hand side scalar value for the comparison. |
If all values of the matrix are equal to the scalar value, the equality test returns true, otherwise false. Note that this function can only be used with built-in, numerical data types!
|
inline |
Equality operator for the comparison of a column-major dense matrix and a scalar value.
mat | The left-hand side column-major dense matrix for the comparison. |
scalar | The right-hand side scalar value for the comparison. |
If all values of the matrix are equal to the scalar value, the equality test returns true, otherwise false. Note that this function can only be used with built-in, numerical data types!
|
inline |
Equality operator for the comparison of a scalar value and a dense matrix.
scalar | The left-hand side scalar value for the comparison. |
mat | The right-hand side dense matrix for the comparison. |
If all values of the matrix are equal to the scalar value, the equality test returns true, otherwise false. Note that this function can only be used with built-in, numerical data types!
void blaze::ql | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO2 > & | Q, | ||
DenseMatrix< MT3, SO3 > & | L | ||
) |
QL decomposition of the given dense matrix.
A | The matrix to be decomposed. |
Q | The resulting Q matrix. |
L | The resulting L matrix. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Square matrix cannot be resized to m-by-n. |
This function performs the dense matrix QL decomposition of a general m-by-n matrix. The resulting decomposition has the form
where Q
is a general m-by-min(m,n) matrix and L
is a lower trapezoidal min(m,n)-by-n matrix. The decomposition is written to the two distinct matrices Q
and L
, which are resized to the correct dimensions (if possible and necessary).
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Example:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!void blaze::qr | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO2 > & | Q, | ||
DenseMatrix< MT3, SO3 > & | R | ||
) |
QR decomposition of the given dense matrix.
A | The matrix to be decomposed. |
Q | The resulting Q matrix. |
R | The resulting R matrix. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Square matrix cannot be resized to m-by-n. |
This function performs the dense matrix QR decomposition of a general m-by-n matrix. The resulting decomposition has the form
where Q
is a general m-by-min(m,n) matrix and R
is an upper trapezoidal min(m,n)-by-n matrix. The decomposition is written to the two distinct matrices Q
and R
, which are resized to the correct dimensions (if possible and necessary).
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Example:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!
|
inline |
Returns a matrix containing the real part of each single element of dm.
dm | The input matrix. |
The real function calculates the real part of each element of the input matrix dm. The function returns an expression representing this operation.
The following example demonstrates the use of the real function:
void blaze::rq | ( | const DenseMatrix< MT1, SO1 > & | A, |
DenseMatrix< MT2, SO2 > & | R, | ||
DenseMatrix< MT3, SO3 > & | Q | ||
) |
RQ decomposition of the given dense matrix.
A | The matrix to be decomposed. |
R | The resulting R matrix. |
Q | The resulting Q matrix. |
std::invalid_argument | Dimensions of fixed size matrix do not match. |
std::invalid_argument | Square matrix cannot be resized to m-by-n. |
This function performs the dense matrix RQ decomposition of a general m-by-n matrix. The resulting decomposition has the form
where R
is an upper trapezoidal m-by-min(m,n) matrix and Q
is a general min(m,n)-by-n matrix. The decomposition is written to the two distinct matrices R
and Q
, which are resized to the correct dimensions (if possible and necessary).
The function fails if ...
In all failure cases a std::invalid_argument exception is thrown.
Example:
float
, double
, complex<float>
, or complex<double>
element type. The attempt to call the function with matrices of any other element type results in a compile time error!
|
inline |
Forces the serial evaluation of the given dense matrix expression dm.
dm | The input matrix. |
The serial function forces the serial evaluation of the given dense matrix expression dm. The function returns an expression representing the operation.
The following example demonstrates the use of the serial function
|
inline |
Calculation of the transpose of the given dense matrix.
dm | The dense matrix to be transposed. |
This function returns an expression representing the transpose of the given dense matrix: