Dune::ALUSimplexGrid< 2, 2 > Class Template Reference
[ALUSimplexGrid]

#include <alugrid.hh>

Inheritance diagram for Dune::ALUSimplexGrid< 2, 2 >:

Dune::ALU2dGrid< 2, 2 > Dune::GridDefaultImplementation< dim, dimworld, alu2d_ctype, ALU2dGridFamily< dim, dimworld > > Dune::Grid< dim, dimworld, ct, GridFamily > List of all members.

Detailed Description

template<>
class Dune::ALUSimplexGrid< 2, 2 >

[ provides Dune::Grid ] grid with support for simplicial mesh in 2d.

[ provides Dune::Grid ] grid with support for simplicial mesh in 2d and 3d.

The ALUSimplexGrid implements the Dune GridInterface for 2d triangular and 3d tetrahedral meshes. This grid can be locally adapted (non-conforming) and used in parallel computations using dynamcic load balancing.

Note:
Adaptive parallel grid supporting dynamic load balancing, written mainly by Bernard Schupp. This grid supports triangular/tetrahedral elements - a 3d cube grid is also available via the grid implementation ALUCubeGrid or ALUConformGrid.
(see ALUGrid homepage: http://www.mathematik.uni-freiburg.de/IAM/Research/alugrid/)

Two tools are available for partitioning :

For installation instructions see http://www.dune-project.org/doc/contrib-software.html#alugrid .


Public Types

typedef BaseType::ctype ctype
 Define type used for coordinates in grid module.
typedef BaseType::GridFamily GridFamily
 my Traits class
typedef GridFamily::Traits Traits
 my Traits class
typedef BaseType::LocalIdSetImp LocalIdSetImp
 Type of the local id set.
typedef Traits::GlobalIdSet GlobalIdSet
 Type of the global id set.
typedef Traits::LocalIdSet LocalIdSet
 Type of the local id set.
typedef GridFamily::LevelIndexSetImp LevelIndexSetImp
 Type of the level index set.
typedef GridFamily::LeafIndexSetImp LeafIndexSetImp
 Type of the leaf index set.
typedef BaseType::LeafIteratorImp LeafIteratorImp
 a standard leaf iterator
enum  
 maximal number of levels
enum  
 element chunk for refinement
enum  
 upper estimate on number of elements that could be created when a new element is created
typedef ALU2dGridObjectStream ObjectStreamType
 dummy object stream
typedef ALU2dGridHierarchicIndexSet<
dim, dimworld > 
HierarchicIndexSet
 Type of the hierarchic index set.
typedef ALU2dGridLevelIterator<
0, All_Partition, const ThisType
LevelIteratorImp
 a standard leaf iterator
Exported constants
enum  { dimension = dim }
 A constant that exports the template parameter dim. More...
enum  { dimensionworld = dimworld }
 A constant that exports the template parameter dimworld. More...

Public Member Functions

 ALUSimplexGrid (const std::string macroName)
 constructor for creating ALUSimplexGrid from given macro grid file
 ALUSimplexGrid ()
 constructor creating empty grid
std::string name () const
 for grid identification
int maxLevel () const
Traits::template Codim< cd
>::template Partition< pitype
>::LevelIterator 
lbegin (int level) const
Traits::template Codim< cd
>::template Partition< All_Partition
>::LevelIterator 
lbegin (int level) const
 Iterator to first entity of given codim on level.
LevelIteratorType lbegin (int level) const
 Iterator to first entity of codim 0 on level.
Traits::template Codim< cd
>::template Partition< pitype
>::LevelIterator 
lend (int level) const
 one past the end on this level
Traits::template Codim< cd
>::template Partition< All_Partition
>::LevelIterator 
lend (int level) const
 one past the end on this level
LevelIteratorType lend (int level) const
 last entity of codim 0 on level
Traits::template Codim< codim
>::template Partition< pitype
>::LeafIterator 
leafbegin () const
 General definiton for a leaf iterator.
Traits::template Codim< codim
>::LeafIterator 
leafbegin () const
 General definiton for a leaf iterator.
Traits::template Codim< codim
>::template Partition< pitype
>::LeafIterator 
leafend () const
 General definition for an end iterator on leaf level.
Traits::template Codim< codim
>::LeafIterator 
leafend () const
 General definition for an end iterator on leaf level.
int size (int level, int cd) const
 number of grid entities per level and codim
int size (int codim) const
 number of leaf entities per codim in this process
int size (int level, GeometryType type) const
 number of entities per level, codim and geometry type in this process
int size (GeometryType type) const
 number of leaf entities per codim and geometry type in this process
const std::vector< GeometryType > & geomTypes (int codim) const
 deliver all geometry types used in this grid
const GlobalIdSetglobalIdSet () const
 get global id set of grid
const LocalIdSetlocalIdSet () const
 get global id set of grid
int hierSetSize (int cd) const
 number of grid entities in the entire grid for given codim
const HierarchicIndexSethierarchicIndexSet () const
 get hierarchic index set of the grid
const Traits::LeafIndexSetleafIndexSet () const
 get leaf index set of the grid
const Traits::LevelIndexSetlevelIndexSet (int level) const
 get level index set of the grid
bool globalRefine (int refCount)
 refine grid refCount times
bool preAdapt ()
 returns if a least one entity was marked for coarsening
void postAdapt ()
 clear all entity new markers
bool adapt ()
bool adapt (DofManagerType &, RestrictProlongOperatorType &, bool verbose=false)
 adapt with DofManager
bool mark (int refCount, const typename Traits::template Codim< 0 >::EntityPointer &ep)
int getMark (const typename Traits::template Codim< 0 >::EntityPointer &) const
 return current adaptation marker for entity pointer
int getMark (const typename Traits::template Codim< 0 >::Entity &) const
 return current adaptation marker for entity pointer
const CollectiveCommunicationType & comm () const
 return dummy communication
ALU2dGridMarkerVector & getMarkerVector (int level) const
ALU2dGridLeafMarkerVectorType & getLeafMarker () const
bool writeGrid (const std::string filename, alu2d_ctype time) const
 write Grid to file in specified FileFormatType
bool readGrid (const std::string filename, alu2d_ctype &time)
 read Grid from file filename and store time of mesh in time
void communicate (CommDataHandleIF< DataHandleImp, DataTypeImp > &data, InterfaceType iftype, CommunicationDirection dir, int level) const
 Communicate information on distributed entities on a given level Template parameter is a model of Dune::CommDataHandleIF.
void communicate (CommDataHandleIF< DataHandleImp, DataTypeImp > &data, InterfaceType iftype, CommunicationDirection dir) const
 Communicate information on distributed entities on the leaf grid. Template parameter is a model of Dune::CommDataHandleIF.
bool loadBalance ()
 Re-balances the load each process has to handle for a parallel grid, if grid has changed , true is returned.
bool loadBalance (DataHandle &data)
 Re-balances the load each process has to handle for a parallel grid, if grid has changed , true is returned.
int ghostSize (int level, int codim) const
 ghostSize is zero by default
int ghostSize (int codim) const
 ghostSize is zero by default
int overlapSize (int level, int codim) const
 overlapSize is zero by default
int overlapSize (int codim) const
 overlapSize is zero by default
Adaptivity and grid refinement
bool mark (int refCount, const typename Codim< 0 >::EntityPointer &e)
 Marks an entity to be refined/coarsened in a subsequent adapt.
int getMark (const typename Codim< 0 >::EntityPointer &e) const
 returns adaptation mark for given entity pointer

Protected Member Functions

bool nonConform () const
ReturnImplementationType<
InterfaceType >::ImplementationType & 
getRealImplementation (InterfaceType &i) const
 return real implementation of interface class
GridImp & asImp ()
 Barton-Nackman trick.
const GridImp & asImp () const
 Barton-Nackman trick.

Member Enumeration Documentation

template<int dim, int dimworld, class ct, class GridFamily>
anonymous enum [inherited]

A constant that exports the template parameter dim.

Enumerator:
dimension  The dimension of the grid.

template<int dim, int dimworld, class ct, class GridFamily>
anonymous enum [inherited]

A constant that exports the template parameter dimworld.

Enumerator:
dimensionworld  The dimension of the world the grid lives in.


Constructor & Destructor Documentation

Dune::ALUSimplexGrid< 2, 2 >::ALUSimplexGrid ( const std::string  macroName  )  [inline]

constructor for creating ALUSimplexGrid from given macro grid file

Parameters:
macroName filename for macro grid in ALUGrid triangle format


Member Function Documentation

int Dune::ALU2dGrid< dim, dimworld >::maxLevel (  )  const [inherited]

Return maximum level defined in this grid. Levels are numbered 0 ... maxLevel with 0 the coarsest level.

Reimplemented from Dune::Grid< dim, dimworld, ct, GridFamily >.

Traits::template Codim<cd>::template Partition<pitype>::LevelIterator Dune::ALU2dGrid< dim, dimworld >::lbegin ( int  level  )  const [inline, inherited]

Iterator to first entity of codim 0 on level.

--Leveliterator Iterator to first entity of given codim on level

Reimplemented from Dune::Grid< dim, dimworld, ct, GridFamily >.

bool Dune::ALU2dGrid< dim, dimworld >::adapt (  )  [inherited]

! refine all positive marked leaf entities, return true if a least one entity was refined

Reimplemented from Dune::GridDefaultImplementation< dim, dimworld, alu2d_ctype, ALU2dGridFamily< dim, dimworld > >.

bool Dune::ALU2dGrid< dim, dimworld >::mark ( int  refCount,
const typename Traits::template Codim< 0 >::EntityPointer ep 
) [inherited]

mark entities for refinement or coarsening, refCount < 0 will mark the entity for one coarsen step and refCount > 0 will mark for one refinement, one refinement will create 8 children per element

Reimplemented from Dune::GridDefaultImplementation< dim, dimworld, alu2d_ctype, ALU2dGridFamily< dim, dimworld > >.

template<int dim, int dimworld, class ct, class GridFamily>
bool Dune::Grid< dim, dimworld, ct, GridFamily >::mark ( int  refCount,
const typename Codim< 0 >::EntityPointer e 
) [inline, inherited]

Marks an entity to be refined/coarsened in a subsequent adapt.

Parameters:
[in] refCount Number of subdivisions that should be applied. Negative value means coarsening.
[in] e EntityPointer to Entity that should be refined
Returns:
true if Entity was marked, false otherwise.

template<int dim, int dimworld, class ct, class GridFamily>
int Dune::Grid< dim, dimworld, ct, GridFamily >::getMark ( const typename Codim< 0 >::EntityPointer e  )  const [inline, inherited]

returns adaptation mark for given entity pointer

Parameters:
[in] e EntityPointer for which adaptation mark should be determined
Returns:
int adaptation mark currently set for given EntityPointer e

ALU2dGridMarkerVector& Dune::ALU2dGrid< dim, dimworld >::getMarkerVector ( int  level  )  const [inline, inherited]

return reference to vector telling on which element a face is visted for this level

ALU2dGridLeafMarkerVectorType& Dune::ALU2dGrid< dim, dimworld >::getLeafMarker (  )  const [inline, inherited]

return reference to vector determing on which element a face is visited

bool Dune::ALU2dGrid< dim, dimworld >::nonConform (  )  const [inline, protected, inherited]

return true if grid allows hanging nodes on leaf level i.e. returns true for ALUSimplexGrid and returns false for ALUConformGrid


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

Generated on 9 Apr 2008 with Doxygen (ver 1.5.2) [logfile].