5#ifndef DUNE_ALBERTA_ALBERTAREADER_HH
6#define DUNE_ALBERTA_ALBERTAREADER_HH
8#include <dune/geometry/type.hh>
20 template<
class Gr
id >
35 "AlbertaReader: world dimension must match ALBERTA's world dimension.");
51 macroData_.
read( fileName,
false );
55 for(
int i = 0; i < numVertices; ++i )
57 FieldVector< ctype, dimensionworld > v;
65 std::vector< unsigned int > vertices(
dimension+1 );
67 for(
int i = 0; i < numElements; ++i )
71 vertices[ j ] =
id[ j ];
provides a wrapper for ALBERTA's macro_data structure
Include standard header files.
Definition agrid.hh:60
static const int dimWorld
Definition misc.hh:46
ALBERTA REAL_D GlobalVector
Definition misc.hh:50
Definition albertareader.hh:22
Grid::ctype ctype
Definition albertareader.hh:28
static const int dimensionworld
Definition albertareader.hh:31
static const int dimension
Definition albertareader.hh:30
Dune::GridFactory< Grid > GridFactory
Definition albertareader.hh:26
AlbertaReader()
Definition albertareader.hh:45
void readGrid(const std::string &fileName, GridFactory &factory)
Definition albertareader.hh:48
int ElementId[numVertices]
Definition macrodata.hh:48
void release()
release the macro data structure
Definition macrodata.hh:127
int elementCount() const
Definition macrodata.hh:68
GlobalVector & vertex(int i) const
Definition macrodata.hh:255
int vertexCount() const
Definition macrodata.hh:63
ElementId & element(int i) const
Definition macrodata.hh:246
void read(const std::string &filename, bool binary=false)
Definition macrodata.hh:413
static constexpr int dimension
The dimension of the grid.
Definition common/grid.hh:387
static constexpr int dimensionworld
The dimension of the world the grid lives in.
Definition common/grid.hh:390
ct ctype
Define type used for coordinates in grid module.
Definition common/grid.hh:518
virtual void insertElement(const GeometryType &type, const std::vector< unsigned int > &vertices)
Insert an element into the coarse grid.
Definition common/gridfactory.hh:307
virtual void insertVertex(const FieldVector< ctype, dimworld > &pos)
Insert a vertex into the coarse grid.
Definition common/gridfactory.hh:296
Provide a generic factory class for unstructured grids.
Different resources needed by all grid implementations.