![]() |
Chemical Data Processing Library C++ API - Version 1.4.0
|
Expression-template node combining two matrix expressions E1 and E2 via a binary functor F that is invoked with both expressions plus the (i, j) cell indices. More...
#include <MatrixExpression.hpp>
Inheritance diagram for CDPL::Math::MatrixBinary2< E1, E2, F >:Public Types | |
| typedef F::ResultType | ValueType |
| The element value type of the expression (the functor's result type). More... | |
| typedef const ValueType | ConstReference |
| Constant reference type to an element value. More... | |
| typedef const ValueType | Reference |
Mutable reference type (degrades to const for expression-template results). More... | |
| typedef const SelfType | ConstClosureType |
| Constant closure type used when this expression appears inside another expression. More... | |
| typedef SelfType | ClosureType |
| Closure type used when this expression appears inside another expression. More... | |
| typedef CommonType< typename E1::SizeType, typename E2::SizeType >::Type | SizeType |
| The common size type of the two wrapped expressions. More... | |
| typedef CommonType< typename E1::DifferenceType, typename E2::DifferenceType >::Type | DifferenceType |
| The common signed difference type of the two wrapped expressions. More... | |
Public Types inherited from CDPL::Math::MatrixExpression< MatrixBinary2< E1, E2, F > > | |
| typedef MatrixBinary2< E1, E2, F > | ExpressionType |
| The derived matrix expression type. More... | |
Public Types inherited from CDPL::Math::Expression< E > | |
| typedef E | ExpressionType |
| The derived expression type (made available to expression-template machinery). More... | |
Public Member Functions | |
| MatrixBinary2 (const Expression1Type &e1, const Expression2Type &e2) | |
| Constructs the expression-template node wrapping e1 and e2. More... | |
| SizeType | getSize1 () const |
| Returns the first wrapped expression's first-dimension size (number of rows of the result). More... | |
| SizeType | getSize2 () const |
| Returns the second wrapped expression's second-dimension size (number of columns of the result). More... | |
| ConstReference | operator() (SizeType i, SizeType j) const |
| Invokes the functor with both wrapped expressions and the indices (i, j) and returns the result. More... | |
Public Member Functions inherited from CDPL::Math::MatrixExpression< MatrixBinary2< E1, E2, F > > | |
| const ExpressionType & | operator() () const |
Returns a const reference to the derived matrix expression. More... | |
| ExpressionType & | operator() () |
| Returns a reference to the derived matrix expression. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from CDPL::Math::MatrixExpression< MatrixBinary2< E1, E2, F > > | |
| MatrixExpression () | |
| ~MatrixExpression () | |
Protected Member Functions inherited from CDPL::Math::Expression< E > | |
| Expression () | |
| ~Expression () | |
Expression-template node combining two matrix expressions E1 and E2 via a binary functor F that is invoked with both expressions plus the (i, j) cell indices.
Unlike Math::MatrixBinary1 (which is element-wise), the functor here receives both expressions verbatim along with the cell coordinates — used for matrix products and similar non-element-wise combinations.
| E1 | The first wrapped matrix expression type. |
| E2 | The second wrapped matrix expression type. |
| F | The binary functor type. |
| typedef F::ResultType CDPL::Math::MatrixBinary2< E1, E2, F >::ValueType |
The element value type of the expression (the functor's result type).
| typedef const ValueType CDPL::Math::MatrixBinary2< E1, E2, F >::ConstReference |
Constant reference type to an element value.
| typedef const ValueType CDPL::Math::MatrixBinary2< E1, E2, F >::Reference |
Mutable reference type (degrades to const for expression-template results).
| typedef const SelfType CDPL::Math::MatrixBinary2< E1, E2, F >::ConstClosureType |
Constant closure type used when this expression appears inside another expression.
| typedef SelfType CDPL::Math::MatrixBinary2< E1, E2, F >::ClosureType |
Closure type used when this expression appears inside another expression.
| typedef CommonType<typename E1::SizeType, typename E2::SizeType>::Type CDPL::Math::MatrixBinary2< E1, E2, F >::SizeType |
The common size type of the two wrapped expressions.
| typedef CommonType<typename E1::DifferenceType, typename E2::DifferenceType>::Type CDPL::Math::MatrixBinary2< E1, E2, F >::DifferenceType |
The common signed difference type of the two wrapped expressions.
|
inline |
Constructs the expression-template node wrapping e1 and e2.
| e1 | The first matrix expression. |
| e2 | The second matrix expression. |
|
inline |
Returns the first wrapped expression's first-dimension size (number of rows of the result).
|
inline |
Returns the second wrapped expression's second-dimension size (number of columns of the result).
|
inline |
Invokes the functor with both wrapped expressions and the indices (i, j) and returns the result.
| i | The zero-based row index. |
| j | The zero-based column index. |