cheshirekow  v0.1.0
fiber::_Normalize< Scalar, Exp > Class Template Reference

Expression template presents a view of a matrix where each element is normalized, such that the sum of the elements is 1.0. More...

#include <fiber/normalize.h>

Inheritance diagram for fiber::_Normalize< Scalar, Exp >:
fiber::_RValue< Scalar, _Normalize< Scalar, Exp > >

Public Types

enum  { ROWS_ = Exp::ROWS_, COLS_ = Exp::COLS_, SIZE_ = ROWS_ * COLS_ }
 

Public Member Functions

 _Normalize (Exp const &A)
 
Size cols () const
 
Scalar operator() (Index i, Index j) const
 
Scalar operator[] (Index i) const
 
Size rows () const
 
Size size () const
 
- Public Member Functions inherited from fiber::_RValue< Scalar, _Normalize< Scalar, Exp > >
Size cols () const
 
Scalar operator() (Size i, Size j) const
 
Scalar operator[] (Size i) const
 
Size rows () const
 
Size size () const
 

Private Attributes

Scalar norm_
 2-norm of elements in the expression More...
 
Exp const & v_
 underlying expression More...
 

Detailed Description

template<typename Scalar, class Exp>
class fiber::_Normalize< Scalar, Exp >

Expression template presents a view of a matrix where each element is normalized, such that the sum of the elements is 1.0.

Definition at line 58 of file normalize.h.

Member Enumeration Documentation

template<typename Scalar , class Exp >
anonymous enum
Enumerator
ROWS_ 
COLS_ 
SIZE_ 

Definition at line 63 of file normalize.h.

Constructor & Destructor Documentation

template<typename Scalar , class Exp >
fiber::_Normalize< Scalar, Exp >::_Normalize ( Exp const &  A)
inline

Definition at line 69 of file normalize.h.

Member Function Documentation

template<typename Scalar , class Exp >
Size fiber::_Normalize< Scalar, Exp >::cols ( ) const
inline

Definition at line 73 of file normalize.h.

template<typename Scalar , class Exp >
Scalar fiber::_Normalize< Scalar, Exp >::operator() ( Index  i,
Index  j 
) const
inline

Definition at line 79 of file normalize.h.

template<typename Scalar , class Exp >
Scalar fiber::_Normalize< Scalar, Exp >::operator[] ( Index  i) const
inline

Definition at line 75 of file normalize.h.

template<typename Scalar , class Exp >
Size fiber::_Normalize< Scalar, Exp >::rows ( ) const
inline

Definition at line 72 of file normalize.h.

template<typename Scalar , class Exp >
Size fiber::_Normalize< Scalar, Exp >::size ( ) const
inline

Definition at line 71 of file normalize.h.

Member Data Documentation

template<typename Scalar , class Exp >
Scalar fiber::_Normalize< Scalar, Exp >::norm_
private

2-norm of elements in the expression

Definition at line 59 of file normalize.h.

template<typename Scalar , class Exp >
Exp const& fiber::_Normalize< Scalar, Exp >::v_
private

underlying expression

Definition at line 60 of file normalize.h.


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