dune-grid 2.9.0
Classes | Public Types | Public Member Functions | Static Public Attributes | List of all members
Dune::Alberta::MacroData< dim > Class Template Reference

#include <dune/grid/albertagrid/macrodata.hh>

Inheritance diagram for Dune::Alberta::MacroData< dim >:
Inheritance graph

Classes

struct  Library
 

Public Types

typedef int ElementId[numVertices]
 

Public Member Functions

 MacroData ()
 
 operator Data * () const
 
int vertexCount () const
 
int elementCount () const
 
ElementIdelement (int i) const
 
GlobalVectorvertex (int i) const
 
int & neighbor (int element, int i) const
 
BoundaryIdboundaryId (int element, int i) const
 
void create ()
 create a new macro data structure More...
 
void finalize ()
 compress macro data structure More...
 
void markLongestEdge ()
 mark the longest edge of all elements as refinement edges More...
 
void setOrientation (const Real orientation)
 set the orientation of all elements More...
 
bool checkNeighbors () const
 check the neighbor information More...
 
void release ()
 release the macro data structure More...
 
int insertElement (const ElementId &id)
 insert element More...
 
int insertVertex (const GlobalVector &coords)
 insert vertex More...
 
int insertVertex (const FieldVector< Real, dimWorld > &coords)
 insert vertex More...
 
void insertWallTrafo (const GlobalMatrix &m, const GlobalVector &t)
 
void insertWallTrafo (const FieldMatrix< Real, dimWorld, dimWorld > &matrix, const FieldVector< Real, dimWorld > &shift)
 
void checkCycles ()
 
void read (const std::string &filename, bool binary=false)
 
bool write (const std::string &filename, bool binary=false) const
 

Static Public Attributes

static const int supportPeriodicity = 1
 

Member Typedef Documentation

◆ ElementId

template<int dim>
typedef int Dune::Alberta::MacroData< dim >::ElementId[numVertices]

Constructor & Destructor Documentation

◆ MacroData()

template<int dim>
Dune::Alberta::MacroData< dim >::MacroData ( )
inline

Member Function Documentation

◆ boundaryId()

template<int dim>
BoundaryId & Dune::Alberta::MacroData< dim >::boundaryId ( int  element,
int  i 
) const
inline

◆ checkCycles()

template<int dim>
void Dune::Alberta::MacroData< dim >::checkCycles
inline

◆ checkNeighbors()

template<int dim>
bool Dune::Alberta::MacroData< dim >::checkNeighbors
inline

check the neighbor information

This method allows the verification of neighbor information in a finalized (and possibly postprecessed) macro triangulation.

Note
On unfinalized macro triangulations there is no neighbor information. Hence this check will succeed in this case.
Returns
true, if all generated neighbor information is correct.

◆ create()

template<int dim>
void Dune::Alberta::MacroData< dim >::create
inline

create a new macro data structure

A new macro data structure is created and put into insert mode.

◆ element()

template<int dim>
MacroData< dim >::ElementId & Dune::Alberta::MacroData< dim >::element ( int  i) const
inline

◆ elementCount()

template<int dim>
int Dune::Alberta::MacroData< dim >::elementCount ( ) const
inline

◆ finalize()

template<int dim>
void Dune::Alberta::MacroData< dim >::finalize
inline

compress macro data structure

Compress the macro data structure to its minimum size and leave insert mode.

Note
This method may always be called. It does nothing outside of insert mode.

◆ insertElement()

template<int dim>
int Dune::Alberta::MacroData< dim >::insertElement ( const ElementId id)
inline

insert element

Insert an element into the macro data structure. This may only be done in insert mode.

◆ insertVertex() [1/2]

template<int dim>
int Dune::Alberta::MacroData< dim >::insertVertex ( const FieldVector< Real, dimWorld > &  coords)
inline

insert vertex

Insert a vertex into the macro data structure. This may only be done in insert mode.

◆ insertVertex() [2/2]

template<int dim>
int Dune::Alberta::MacroData< dim >::insertVertex ( const GlobalVector coords)
inline

insert vertex

Insert a vertex into the macro data structure. This may only be done in insert mode.

◆ insertWallTrafo() [1/2]

template<int dim>
void Dune::Alberta::MacroData< dim >::insertWallTrafo ( const FieldMatrix< Real, dimWorld, dimWorld > &  matrix,
const FieldVector< Real, dimWorld > &  shift 
)
inline

◆ insertWallTrafo() [2/2]

template<int dim>
void Dune::Alberta::MacroData< dim >::insertWallTrafo ( const GlobalMatrix m,
const GlobalVector t 
)
inline

◆ markLongestEdge()

template<int dim>
void Dune::Alberta::MacroData< dim >::markLongestEdge
inline

mark the longest edge of all elements as refinement edges

This is a postprocessing step and should be done after finalizing the triangulation.

Note
Though it is possible to call markLongestEdge in insert mode, you must make sure that all required vertices have been set.

◆ neighbor()

template<int dim>
int & Dune::Alberta::MacroData< dim >::neighbor ( int  element,
int  i 
) const
inline

◆ operator Data *()

template<int dim>
Dune::Alberta::MacroData< dim >::operator Data * ( ) const
inline

◆ read()

template<int dim>
void Dune::Alberta::MacroData< dim >::read ( const std::string &  filename,
bool  binary = false 
)
inline

◆ release()

template<int dim>
void Dune::Alberta::MacroData< dim >::release ( )
inline

release the macro data structure

◆ setOrientation()

template<int dim>
void Dune::Alberta::MacroData< dim >::setOrientation ( const Real  orientation)
inline

set the orientation of all elements

This is a postprocessing step and should be done after finalizing the triangulation.

Note
Though it is possible to call setOrientation in insert mode, you must make sure that all required vertices have been set.

◆ vertex()

template<int dim>
GlobalVector & Dune::Alberta::MacroData< dim >::vertex ( int  i) const
inline

◆ vertexCount()

template<int dim>
int Dune::Alberta::MacroData< dim >::vertexCount ( ) const
inline

◆ write()

template<int dim>
bool Dune::Alberta::MacroData< dim >::write ( const std::string &  filename,
bool  binary = false 
) const
inline

Member Data Documentation

◆ supportPeriodicity

template<int dim>
const int Dune::Alberta::MacroData< dim >::supportPeriodicity = 1
static

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