Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType > Class Template Reference

Generic lvalue expression of a coefficient-wise unary operator of a matrix or a vector. More...

+ Inheritance diagram for Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >:

Public Types

typedef CwiseUnaryViewImpl< ViewOp, MatrixType, StrideType, typename internal::traits< MatrixType >::StorageKind >::Base Base
 
typedef internal::ref_selector< MatrixType >::non_const_type MatrixTypeNested
 
typedef internal::remove_all_t< MatrixTypeNestedExpression
 

Public Member Functions

EIGEN_CONSTEXPR Index cols () const EIGEN_NOEXCEPT
 
 CwiseUnaryView (MatrixType &mat, const ViewOp &func=ViewOp())
 
const ViewOp & functor () const
 
std::remove_reference_t< MatrixTypeNested > & nestedExpression ()
 
const internal::remove_all_t< MatrixTypeNested > & nestedExpression () const
 
EIGEN_CONSTEXPR Index rows () const EIGEN_NOEXCEPT
 

Protected Attributes

ViewOp m_functor
 
MatrixTypeNested m_matrix
 

Detailed Description

template<typename ViewOp, typename MatrixType, typename StrideType>
class Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >

Generic lvalue expression of a coefficient-wise unary operator of a matrix or a vector.

Template Parameters
ViewOptemplate functor implementing the view
MatrixTypethe type of the matrix we are applying the unary operator

This class represents a lvalue expression of a generic unary view operator of a matrix or a vector. It is the return type of real() and imag(), and most of the time this is the only way it is used.

See also
MatrixBase::unaryViewExpr(const CustomUnaryOp &) const, class CwiseUnaryOp

Definition at line 65 of file CwiseUnaryView.h.

Member Typedef Documentation

◆ Base

template<typename ViewOp , typename MatrixType , typename StrideType >
typedef CwiseUnaryViewImpl<ViewOp, MatrixType, StrideType, typename internal::traits<MatrixType>::StorageKind>::Base Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::Base

Definition at line 69 of file CwiseUnaryView.h.

◆ MatrixTypeNested

template<typename ViewOp , typename MatrixType , typename StrideType >
typedef internal::ref_selector<MatrixType>::non_const_type Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::MatrixTypeNested

Definition at line 71 of file CwiseUnaryView.h.

◆ NestedExpression

template<typename ViewOp , typename MatrixType , typename StrideType >
typedef internal::remove_all_t<MatrixType> Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::NestedExpression

Definition at line 72 of file CwiseUnaryView.h.

Constructor & Destructor Documentation

◆ CwiseUnaryView()

template<typename ViewOp , typename MatrixType , typename StrideType >
Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::CwiseUnaryView ( MatrixType mat,
const ViewOp &  func = ViewOp() 
)
inlineexplicit

Definition at line 74 of file CwiseUnaryView.h.

Member Function Documentation

◆ cols()

template<typename ViewOp , typename MatrixType , typename StrideType >
EIGEN_CONSTEXPR Index Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::cols ( ) const
inline

Definition at line 82 of file CwiseUnaryView.h.

82 { return m_matrix.cols(); }

◆ functor()

template<typename ViewOp , typename MatrixType , typename StrideType >
const ViewOp& Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::functor ( ) const
inline
Returns
the functor representing unary operation

Definition at line 85 of file CwiseUnaryView.h.

85 { return m_functor; }

◆ nestedExpression() [1/2]

template<typename ViewOp , typename MatrixType , typename StrideType >
std::remove_reference_t<MatrixTypeNested>& Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::nestedExpression ( )
inline
Returns
the nested expression

Definition at line 93 of file CwiseUnaryView.h.

93 { return m_matrix; }

◆ nestedExpression() [2/2]

template<typename ViewOp , typename MatrixType , typename StrideType >
const internal::remove_all_t<MatrixTypeNested>& Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::nestedExpression ( ) const
inline
Returns
the nested expression

Definition at line 89 of file CwiseUnaryView.h.

89 { return m_matrix; }

◆ rows()

template<typename ViewOp , typename MatrixType , typename StrideType >
EIGEN_CONSTEXPR Index Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::rows ( ) const
inline

Definition at line 80 of file CwiseUnaryView.h.

80 { return m_matrix.rows(); }

Member Data Documentation

◆ m_functor

template<typename ViewOp , typename MatrixType , typename StrideType >
ViewOp Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::m_functor
protected

Definition at line 97 of file CwiseUnaryView.h.

◆ m_matrix

template<typename ViewOp , typename MatrixType , typename StrideType >
MatrixTypeNested Eigen::CwiseUnaryView< ViewOp, MatrixType, StrideType >::m_matrix
protected

Definition at line 96 of file CwiseUnaryView.h.


The documentation for this class was generated from the following file: