CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > Class Template Reference
Matrix expression for element-wise binary operation. More...
#include <Core/Matrix/MatrixExpression.hpp>
Inheritance diagram for CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation >:
Public Member Functions | |
constexpr | MatrixElemWiseBinaryOp (const E1 &mat1, const E2 &mat2) |
constexpr size_t | GetRows () const |
constexpr size_t | GetCols () const |
constexpr T | operator() (size_t i, size_t j) const |
Public Member Functions inherited from CubbyFlow::MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > | |
constexpr size_t | GetRows () const |
Returns the number of rows. More... | |
constexpr size_t | GetCols () const |
Returns the number of columns. More... | |
T | Eval (size_t i, size_t j) const |
Returns the evaluated value for (i, j). More... | |
Matrix< T, Rows, Cols > | Eval () const |
bool | IsSimilar (const MatrixExpression< T, R, C, E > &m, double tol=std::numeric_limits< double >::epsilon()) const |
constexpr bool | IsSquare () const |
Returns true if this matrix is a square matrix. More... | |
ValueType | Sum () const |
ValueType | Avg () const |
ValueType | Min () const |
ValueType | Max () const |
ValueType | AbsMin () const |
ValueType | AbsMax () const |
ValueType | Trace () const |
ValueType | Determinant () const |
std::enable_if_t<(Rows > 4 &&Cols > 4)||IsMatrixSizeDynamic< Rows, Cols >), U > | Determinant (const MatrixExpression &m) |
size_t | DominantAxis () const |
size_t | SubdominantAxis () const |
ValueType | Norm () const |
ValueType | NormSquared () const |
ValueType | FrobeniusNorm () const |
ValueType | Length () const |
ValueType | LengthSquared () const |
ValueType | DistanceTo (const MatrixExpression< T, R, C, E > &other) const |
Returns the distance to the other vector. More... | |
T | DistanceTo (const MatrixExpression< T, R, C, E > &other) const |
ValueType | DistanceSquaredTo (const MatrixExpression< T, R, C, E > &other) const |
Returns the squared distance to the other vector. More... | |
T | DistanceSquaredTo (const MatrixExpression< T, R, C, E > &other) const |
MatrixScalarElemWiseBinaryOp< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &, std::divides< T > > | Normalized () const |
MatrixDiagonal< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | Diagonal () const |
Returns diagonal part of this matrix. More... | |
MatrixOffDiagonal< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | OffDiagonal () const |
Returns off-diagonal part of this matrix. More... | |
MatrixTri< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | StrictLowerTri () const |
Returns strictly lower triangle part of this matrix. More... | |
MatrixTri< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | StrictUpperTri () const |
Returns strictly upper triangle part of this matrix. More... | |
MatrixTri< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | LowerTri () const |
Returns lower triangle part of this matrix (including the diagonal). More... | |
MatrixTri< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | UpperTri () const |
Returns upper triangle part of this matrix (including the diagonal). More... | |
MatrixTranspose< T, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &> | Transposed () const |
Matrix< T, Rows, Cols > | Inverse () const |
Returns inverse matrix. More... | |
void | Inverse (const MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m, std::enable_if_t<(Rows > 4 &&Cols > 4)||IsMatrixSizeDynamic< Rows, Cols >(), M > &result) |
MatrixUnaryOp< U, Rows, Cols, const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > &, TypeCast< T, U > > | CastTo () const |
MatrixTypeCast< T, Rows, Cols, U, const D &> | CastTo () const |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||Cols==1) &&(IsMatrixSizeDynamic< R, C >)||C==1), U > | Dot (const MatrixExpression< T, R, C, E > &expression) const |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||(Rows==2 &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >)||(R==2 &&C==1)), U > | Cross (const MatrixExpression< T, R, C, E > &expression) const |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||(Rows==3 &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >)||(R==3 &&C==1)), Matrix< U, 3, 1 > > | Cross (const MatrixExpression< T, R, C, E > &expression) const |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||((Rows==2||Rows==3) &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >)||((R==2||R==3) &&C==1)), Matrix< U, Rows, 1 > > | Reflected (const MatrixExpression< T, R, C, E > &normal) const |
Returns the reflection vector to the surface with given surface normal. More... | |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||((Rows==2||Rows==3) &&Cols==1)) &&(IsMatrixSizeDynamic< R, C >)||((R==2||R==3) &&C==1)), Matrix< U, Rows, 1 > > | Projected (const MatrixExpression< T, R, C, E > &normal) const |
Returns the projected vector to the surface with given surface normal. More... | |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||(Rows==2 &&Cols==1)), Matrix< U, 2, 1 > > | Tangential () const |
Returns the tangential vector for this vector. More... | |
std::enable_if_t<(IsMatrixSizeDynamic< Rows, Cols >)||(Rows==3 &&Cols==1)), std::tuple< Matrix< U, 3, 1 >, Matrix< U, 3, 1 > > > | Tangentials () const |
Returns the tangential vectors for this vector. More... | |
MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > & | GetDerived () |
Returns actual implementation (the subclass). More... | |
const MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > & | GetDerived () const |
Returns actual implementation (the subclass). More... | |
Additional Inherited Members | |
Public Types inherited from CubbyFlow::MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > | |
using | ValueType = T |
Protected Member Functions inherited from CubbyFlow::MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > | |
MatrixExpression ()=default | |
Static Protected Member Functions inherited from CubbyFlow::MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > | |
static constexpr T | Determinant (const MatrixExpression< T, 1, 1, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m) |
static constexpr T | Determinant (const MatrixExpression< T, 2, 2, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m) |
static constexpr T | Determinant (const MatrixExpression< T, 3, 3, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m) |
static constexpr T | Determinant (const MatrixExpression< T, 4, 4, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m) |
static std::enable_if_t<(Rows > 4 &&Cols > 4)||IsMatrixSizeDynamic< Rows, Cols >), U > | Determinant (const MatrixExpression< T, Rows, Cols, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m) |
static void | Inverse (const MatrixExpression< T, 1, 1, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m, Matrix< T, Rows, Cols > &result) |
static void | Inverse (const MatrixExpression< T, 2, 2, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m, Matrix< T, Rows, Cols > &result) |
static void | Inverse (const MatrixExpression< T, 3, 3, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m, Matrix< T, Rows, Cols > &result) |
static void | Inverse (const MatrixExpression< T, 4, 4, MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation > > &m, Matrix< T, Rows, Cols > &result) |
static void | Inverse (const MatrixExpression &m, std::enable_if_t<(Rows > 4 &&Cols > 4)||IsMatrixSizeDynamic< Rows, Cols >(), M > &result) |
Detailed Description
template<typename T, size_t Rows, size_t Cols, typename E1, typename E2, typename BinaryOperation>
class CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BinaryOperation >
Matrix expression for element-wise binary operation.
This matrix expression represents a binary matrix operation that takes two input matrix expressions.
- Template Parameters
-
T Real number type. E1 First input expression type. E2 Second input expression type. BinaryOperation Binary operation.
Constructor & Destructor Documentation
◆ MatrixElemWiseBinaryOp()
template<typename T, size_t Rows, size_t Cols, typename E1, typename E2, typename BinaryOperation>
|
inline |
Member Function Documentation
◆ GetCols()
template<typename T , size_t Rows, size_t Cols, typename E1 , typename E2 , typename BOp >
constexpr size_t CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BOp >::GetCols | ( | ) | const |
◆ GetRows()
template<typename T , size_t Rows, size_t Cols, typename E1 , typename E2 , typename BOp >
constexpr size_t CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BOp >::GetRows | ( | ) | const |
◆ operator()()
template<typename T , size_t Rows, size_t Cols, typename E1 , typename E2 , typename BOp >
constexpr T CubbyFlow::MatrixElemWiseBinaryOp< T, Rows, Cols, E1, E2, BOp >::operator() | ( | size_t | i, |
size_t | j | ||
) | const |
The documentation for this class was generated from the following files:
- Core/Matrix/MatrixExpression.hpp
- Core/Matrix/MatrixExpression-Impl.hpp