![]() |
Eigen
3.2.7
|
Pseudo expression providing partial reduction operations.
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:
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
Public Member Functions | |
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 VectorwiseOp < ExpressionType, Direction > ::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 |
|
inline |
true
.
|
inline |
true
.
|
inline |
|
inline |
true
coefficients of each respective column (or row).Example:
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 count of elements larger or equal than 0.5 of each row: 2 2 1
const VectorwiseOp<ExpressionType,Direction>::CrossReturnType cross | ( | const MatrixBase< OtherDerived > & | other | ) | const |
The referenced matrix must have one dimension equal to 3. The result matrix has the same dimensions than the referenced one.
This is defined in the Geometry module.
References DenseBase< Derived >::col(), DenseBase< Derived >::row(), and Eigen::Vertical.
|
inline |
This is defined in the Geometry module.
*this
Example:
Output:
References Eigen::Horizontal, and Eigen::Vertical.
|
inline |
This is defined in the Geometry module.
Example:
Output:
|
inline |
|
inline |
*this
contains NaN.Example:
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 maximum of each column: 0.68 0.823 0.536
|
inline |
|
inline |
*this
contains NaN.Example:
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 minimum of each column: -0.211 -0.605 -0.444
|
inline |
Example:
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 norm of each column: 0.91 1.18 0.771
|
inline |
Normalize in-place each row or columns of the referenced matrix.
|
inline |
|
inline |
Returns the expression where each subvector is the product of the vector other by the corresponding subvector of *this
|
inline |
Multiples each subvector of *this
by the vector other
|
inline |
Returns the expression of the sum of the vector other to each subvector of *this
|
inline |
Adds the vector other to each subvector of *this
|
inline |
Returns the expression of the difference between each subvector of *this
and the vector other
|
inline |
Substracts the vector other to each subvector of *this
|
inline |
Returns the expression where each subvector is the quotient of the corresponding subvector of *this
by the vector other
|
inline |
Divides each subvector of *this
by the vector other
|
inline |
Copies the vector other to each subvector of *this
|
inline |
Example:
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 product of each row: -0.134 -0.0933 0.152
|
inline |
*this
reduxed by func The template parameter BinaryOp is the type of the functor of the custom redux operator. Note that func must be an associative operator.
const VectorwiseOp< ExpressionType, Direction >::ReplicateReturnType replicate | ( | Index | factor | ) | const |
*this
Example:
Output:
Here is the vector v: 7 -2 6 v.rowwise().replicate(5) = ... 7 7 7 7 7 -2 -2 -2 -2 -2 6 6 6 6 6
References Eigen::Horizontal, and Eigen::Vertical.
|
inline |
*this
Example:
Output:
Here is the matrix m: 7 6 9 -2 6 -6 m.colwise().replicate<3>() = ... 7 6 9 -2 6 -6 7 6 9 -2 6 -6 7 6 9 -2 6 -6
References Eigen::Horizontal, and Eigen::Vertical.
|
inline |
Example:
Output:
Here is the matrix m: 7 6 -3 1 -2 9 6 0 6 -6 -5 3 Here is the rowwise reverse of m: 1 -3 6 7 0 6 9 -2 3 -5 -6 6 Here is the colwise reverse of m: 6 -6 -5 3 -2 9 6 0 7 6 -3 1 Here is the coefficient (1,0) in the rowise reverse of m: 0 Let us overwrite this coefficient with the value 4. Now the matrix m is: 7 6 -3 1 -2 9 6 0 6 -6 -5 3
|
inline |
Example:
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 square norm of each row: 0.928 1.01 0.884
|
inline |
|
inline |
Example:
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 row: 0.948 1.15 -0.483