Dune::cpgrid::SignedEntityVariable< T, codim > Class Template Reference

A class design to hold a variable with a value for each entity of the given codimension, where the variable is changing in sign with orientation. An example is velocity fields. More...

#include <EntityRep.hpp>

Inheritance diagram for Dune::cpgrid::SignedEntityVariable< T, codim >:
Inheritance graph

Public Types

typedef std::vector< T > V
 
typedef std::vector< T >::iterator iterator
 
typedef std::vector< T >::const_iterator const_iterator
 

Public Member Functions

 SignedEntityVariable ()
 Default constructor. More...
 
const T operator[] (const EntityRep< codim > &e) const
 Random access to the variable through an EntityRep. Note that this operator always returns a copy, not a reference, since we may need to flip the sign. More...
 
const T & get (int i) const
 
T & get (int i)
 

Detailed Description

template<typename T, int codim>
class Dune::cpgrid::SignedEntityVariable< T, codim >

A class design to hold a variable with a value for each entity of the given codimension, where the variable is changing in sign with orientation. An example is velocity fields.

Template Parameters
TA value type for the variable, such as double for pressure etc.
codimCodimension.

Member Typedef Documentation

◆ const_iterator

template<typename T >
typedef std::vector<T>::const_iterator Dune::cpgrid::EntityVariableBase< T >::const_iterator
inherited

◆ iterator

template<typename T >
typedef std::vector<T>::iterator Dune::cpgrid::EntityVariableBase< T >::iterator
inherited

◆ V

template<typename T >
typedef std::vector<T> Dune::cpgrid::EntityVariableBase< T >::V
inherited

Constructor & Destructor Documentation

◆ SignedEntityVariable()

template<typename T , int codim>
Dune::cpgrid::SignedEntityVariable< T, codim >::SignedEntityVariable ( )
inline

Default constructor.

Member Function Documentation

◆ get() [1/2]

template<typename T >
T & Dune::cpgrid::EntityVariableBase< T >::get ( int  i)
inlineinherited

◆ get() [2/2]

template<typename T >
const T & Dune::cpgrid::EntityVariableBase< T >::get ( int  i) const
inlineinherited

◆ operator[]()

template<typename T , int codim>
const T Dune::cpgrid::SignedEntityVariable< T, codim >::operator[] ( const EntityRep< codim > &  e) const
inline

Random access to the variable through an EntityRep. Note that this operator always returns a copy, not a reference, since we may need to flip the sign.

References Dune::cpgrid::EntityVariableBase< T >::get(), Dune::cpgrid::EntityRep< codim >::index(), and Dune::cpgrid::EntityRep< codim >::orientation().


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