Dune::YGrid< d, ct >::TransformingIterator Class Reference

#include <grids.hh>

Inheritance diagram for Dune::YGrid< d, ct >::TransformingIterator:

Dune::YGrid< d, ct >::Iterator List of all members.

Detailed Description

template<int d, typename ct>
class Dune::YGrid< d, ct >::TransformingIterator

TransformingIterator is an Iterator providing in addition a linear transformation of the coordinates of the grid in the form $ y_i = x_i h_i + s_i $. This can be used to interpret the grid cells as vertices, edges, faces, etc.


Public Member Functions

 TransformingIterator (const YGrid< d, ct > &r)
 Make iterator pointing to first cell in a grid.
 TransformingIterator (const YGrid< d, ct > &r, iTupel &coord)
 Make iterator pointing to given cell in a grid.
 TransformingIterator (Iterator i)
 Make transforming iterator from iterator (used for automatic conversion of end).
TransformingIteratoroperator++ ()
 Increment iterator to next cell with position.
ct position (int i) const
 Return position of current cell in direction i.
const fTupel & position () const
 Return position of current cell as reference.
ct meshsize (int i) const
 Return meshsize in direction i.
const fTupel & meshsize () const
 Return meshsize of current cell as reference.
void move (int i, int dist)
 Move cell position by dist cells in direction i.
void print (std::ostream &s) const
 Print contents of iterator.
void reinit (const YGrid< d, ct > &r, const iTupel &coord)
 reinitialize iterator to given position
bool operator== (const Iterator &i) const
 Return true when two iterators over the same grid are equal (!).
bool operator!= (const Iterator &i) const
 Return true when two iterators over the same grid are not equal (!).
int index () const
 Return index of the current cell in the consecutive numbering.
int coord (int i) const
 Return coordinate of the cell in direction i.
const iTupelcoord () const
 Return coordinate of the cell as reference (do not modify).
int neighbor (int i, int dist) const
 Get index of cell which is dist cells away in direction i.
int down (int i) const
 Get index of neighboring cell which is -1 away in direction i.
int up (int i) const
 Get index of neighboring cell which is +1 away in direction i.

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

Generated on 12 Dec 2007 with Doxygen (ver 1.5.1)