template<typename ExpressionType, int Direction>
class Eigen::VectorwiseOp< ExpressionType, Direction >
Pseudo expression providing partial reduction operations.
- Parameters
-
ExpressionType | the type of the object on which to do partial reductions |
Direction | indicates the direction of the redux (#Vertical or #Horizontal) |
This class represents a pseudo expression with partial reduction features. It is the return type of DenseBase::colwise() and DenseBase::rowwise() and most of the time this is the only way it is used.
Example:
cout << "Here is the matrix m:" << endl << m << endl;
cout << "Here is the sum of each column:" << endl << m.colwise().sum() << endl;
cout << "Here is the maximum absolute value of each column:"
<< endl << m.cwiseAbs().colwise().maxCoeff() << endl;
Output:
Here is the matrix m:
0.68 0.597 -0.33
-0.211 0.823 0.536
0.566 -0.605 -0.444
Here is the sum of each column:
1.04 0.815 -0.238
Here is the maximum absolute value of each column:
0.68 0.823 0.536
- See also
- DenseBase::colwise(), DenseBase::rowwise(), class PartialReduxExpr
|
const ReturnType< internal::member_all >::Type | all () const |
|
const ReturnType< internal::member_any >::Type | any () const |
|
const ReturnType< internal::member_blueNorm, RealScalar >::Type | blueNorm () const |
|
const PartialReduxExpr< ExpressionType, internal::member_count< Index >, Direction > | count () const |
|
template<typename OtherDerived > |
const CrossReturnType | cross (const MatrixBase< OtherDerived > &other) const |
|
const HNormalizedReturnType | hnormalized () const |
|
Homogeneous< ExpressionType, Direction > | homogeneous () const |
|
const ReturnType< internal::member_hypotNorm, RealScalar >::Type | hypotNorm () const |
|
const ReturnType< internal::member_maxCoeff >::Type | maxCoeff () const |
|
const ReturnType< internal::member_mean >::Type | mean () const |
|
const ReturnType< internal::member_minCoeff >::Type | minCoeff () const |
|
const ReturnType< internal::member_norm, RealScalar >::Type | norm () const |
|
void | normalize () |
|
CwiseBinaryOp< internal::scalar_quotient_op< Scalar >, const ExpressionTypeNestedCleaned, const typename OppositeExtendedType< typename ReturnType< internal::member_norm, RealScalar >::Type >::Type > | normalized () const |
|
template<typename OtherDerived > |
CwiseBinaryOp< internal::scalar_product_op< Scalar >, const ExpressionTypeNestedCleaned, const typename ExtendedType< OtherDerived >::Type > | operator* (const DenseBase< OtherDerived > &other) const |
|
template<typename OtherDerived > |
ExpressionType & | operator*= (const DenseBase< OtherDerived > &other) |
|
template<typename OtherDerived > |
CwiseBinaryOp< internal::scalar_sum_op< Scalar >, const ExpressionTypeNestedCleaned, const typename ExtendedType< OtherDerived >::Type > | operator+ (const DenseBase< OtherDerived > &other) const |
|
template<typename OtherDerived > |
ExpressionType & | operator+= (const DenseBase< OtherDerived > &other) |
|
template<typename OtherDerived > |
CwiseBinaryOp< internal::scalar_difference_op< Scalar >, const ExpressionTypeNestedCleaned, const typename ExtendedType< OtherDerived >::Type > | operator- (const DenseBase< OtherDerived > &other) const |
|
template<typename OtherDerived > |
ExpressionType & | operator-= (const DenseBase< OtherDerived > &other) |
|
template<typename OtherDerived > |
CwiseBinaryOp< internal::scalar_quotient_op< Scalar >, const ExpressionTypeNestedCleaned, const typename ExtendedType< OtherDerived >::Type > | operator/ (const DenseBase< OtherDerived > &other) const |
|
template<typename OtherDerived > |
ExpressionType & | operator/= (const DenseBase< OtherDerived > &other) |
|
template<typename OtherDerived > |
ExpressionType & | operator= (const DenseBase< OtherDerived > &other) |
|
const ReturnType< internal::member_prod >::Type | prod () const |
|
template<typename BinaryOp > |
const ReduxReturnType< BinaryOp >::Type | redux (const BinaryOp &func=BinaryOp()) const |
|
const ReplicateReturnType | replicate (Index factor) const |
|
template<int Factor> |
const Replicate< ExpressionType,(IsVertical?Factor:1),(IsHorizontal?Factor:1)> | replicate (Index factor=Factor) const |
|
const Reverse< ExpressionType, Direction > | reverse () const |
|
const ReturnType< internal::member_squaredNorm, RealScalar >::Type | squaredNorm () const |
|
const ReturnType< internal::member_stableNorm, RealScalar >::Type | stableNorm () const |
|
const ReturnType< internal::member_sum >::Type | sum () const |
|