dune-grid 2.9.0
Public Types | Public Member Functions | Static Public Attributes | List of all members
Dune::TensorProductCoordinates< ct, dim > Class Template Reference

Coordinate container for a tensor product YaspGrid. More...

#include <dune/grid/yaspgrid/coordinates.hh>

Public Types

typedef ct ctype
 export the coordinate type More...
 

Public Member Functions

 TensorProductCoordinates ()
 the default constructor More...
 
 TensorProductCoordinates (const std::array< std::vector< ct >, dim > &c, const std::array< int, dim > &offset)
 construct a container with all necessary information More...
 
ct meshsize (int d, int i) const
 
ct coordinate (int d, int i) const
 
int size (int d) const
 
TensorProductCoordinates< ct, dim > refine (std::bitset< dim > ovlp_low, std::bitset< dim > ovlp_up, int overlap, bool keep_ovlp) const
 
void print (std::ostream &s) const
 print information on this container More...
 

Static Public Attributes

static const int dimension = dim
 export dimension More...
 

Detailed Description

template<class ct, int dim>
class Dune::TensorProductCoordinates< ct, dim >

Coordinate container for a tensor product YaspGrid.

Template Parameters
ctthe coordinate type
dimthe dimension of the grid

Member Typedef Documentation

◆ ctype

template<class ct , int dim>
typedef ct Dune::TensorProductCoordinates< ct, dim >::ctype

export the coordinate type

Constructor & Destructor Documentation

◆ TensorProductCoordinates() [1/2]

template<class ct , int dim>
Dune::TensorProductCoordinates< ct, dim >::TensorProductCoordinates ( )
inline

the default constructor

◆ TensorProductCoordinates() [2/2]

template<class ct , int dim>
Dune::TensorProductCoordinates< ct, dim >::TensorProductCoordinates ( const std::array< std::vector< ct >, dim > &  c,
const std::array< int, dim > &  offset 
)
inline

construct a container with all necessary information

Parameters
cthe array of coordinate vectors
offsetthe offset between global origin and processor origin the size information is deduced from c. Storing offset allows for use of global coordinates in the YaspGrid code.

Member Function Documentation

◆ coordinate()

template<class ct , int dim>
ct Dune::TensorProductCoordinates< ct, dim >::coordinate ( int  d,
int  i 
) const
inline
Returns
a coordinate given a direction and an index
Parameters
dthe direction to be used
ithe global coordinate index

◆ meshsize()

template<class ct , int dim>
ct Dune::TensorProductCoordinates< ct, dim >::meshsize ( int  d,
int  i 
) const
inline
Returns
the meshsize in given direction at given position
Parameters
dthe direction to be used
ithe global coordinate index where to return the meshsize

◆ print()

template<class ct , int dim>
void Dune::TensorProductCoordinates< ct, dim >::print ( std::ostream &  s) const
inline

print information on this container

◆ refine()

template<class ct , int dim>
TensorProductCoordinates< ct, dim > Dune::TensorProductCoordinates< ct, dim >::refine ( std::bitset< dim >  ovlp_low,
std::bitset< dim >  ovlp_up,
int  overlap,
bool  keep_ovlp 
) const
inline
Returns
a container that represents the same grid after one step of uniform refinement
Parameters
ovlp_lowwhether we have an overlap area at the lower processor boundary
ovlp_upwhether we have an overlap area at the upper processor boundary
overlapthe size of the overlap region
keep_ovlpthe refinement option parameter to be used

◆ size()

template<class ct , int dim>
int Dune::TensorProductCoordinates< ct, dim >::size ( int  d) const
inline
Returns
the size in given direction
Parameters
dthe direction to be used

Member Data Documentation

◆ dimension

template<class ct , int dim>
const int Dune::TensorProductCoordinates< ct, dim >::dimension = dim
static

export dimension


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