Diffpack Documentation


Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Search  

Prepro Class Reference

base class for finite element preprocessors. More...

#include <Prepro.h>

Inheritance diagram for Prepro::

HandleId PreproBox PreproGeomPack PreproGrummp2D PreproLaplace PreproStdGeom PreproSupEl PreproSupElSet PreproTriangle List of all members.

Public Methods

virtual ~Prepro ()
virtual bool ok () const=0
virtual void generateMesh (Grid &grid)=0
virtual const Geometrygeometry () const=0
virtual Geometrygeometry ()=0
virtual const Partitionpartition () const=0
virtual Partitionpartition ()=0
virtual void define (MenuSystem &, int=MAIN)
virtual void scan (MenuSystem &)
CLASS_INFO DEF_VIRTUAL_CAST (PreproBox) DEF_VIRTUAL_CAST(PreproSupEl) DEF_VIRTUAL_CAST(PreproSupElSet) DEF_VIRTUAL_CAST(PreproGeomPack) DEF_VIRTUAL_CAST(PreproStdGeom) DEF_VIRTUAL_CAST(PreproLaplace) static void smooth(GridFE &grid, int nrepetitions)

Static Public Methods

void randomNodePerturbation (GridFE &grid, int percent_distortion, real seed=0.123456)
void triangle2tetra (GridFE &grid_triang, GridFE &grid_tetra, FieldFE &zbottom, FieldFE &ztop, int element_layers=1, real grading=1.0, bool newbind=true)
void triangle2tetra (GridFE &grid_triang, GridFE &grid_tetra, real zbottom=0.0, real ztop=1.0, int element_layers=1, real grading=1.0, bool newbind=true)
void triangle2prism (GridFE &grid_triang, GridFE &grid_prism, FieldFE &zbottom, FieldFE &ztop, int element_layers=1, real grading=1.0, bool newbind=true)
void triangle2prism (GridFE &grid_triang, GridFE &grid_prism, real zbottom=0.0, real ztop=1.0, int element_layers=1, real grading=1.0, bool newbind=true)
void triang2PrismOrTetra (GridFE &grid_triang, GridFE &grid, FieldFE &zbottom, FieldFE &ztop, int element_layers=1, bool tetragrid=true, real grading=1.0, bool newbind=true)
void triang2PrismOrTetra (GridFE &grid_triang, GridFE &grid, real zbottom=0.0, real ztop=1.0, int element_layers=1, bool tetragrid=true, real grading=1.0, bool newbind=true)

Protected Methods

 Prepro ()

Detailed Description

base class for finite element preprocessors.

NAME: Prepro - base class for finite element preprocessors

DESCRIPTION:

The class serves as a base class for preprocessors (that is, finite element mesh generators). By having a unified interface for all preprocessors, it is easy to write programs that enables the user to choose the preprocessor method at run time.

The basic idea of the "Prepro" hierarchy is that the mesh generation consists of three basic steps: 1) defining the geometry, 2) defining the partition, and 3) running the mesh generation algorithm. These three steps are reflected in the virtual functions of class "Prepro". Two functions gives the programmer access to a geometry object and a partition object. To initialize the geometry and partition one simply calls the "scan" functions of these two objects. Thereafter step 3 is carried out by the virtual function "Prepro generateMesh".


Constructor & Destructor Documentation

Prepro::Prepro ( ) [inline, protected]
 

The constructor takes no arguments. There is no further initialization of this base class.

Prepro::~Prepro ( ) [virtual]
 


Member Function Documentation

CLASS_INFO Prepro::DEF_VIRTUAL_CAST ( PreproBox )
 

void Prepro::define ( MenuSystem & menu,
int level = MAIN ) [inline, virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

void Prepro::generateMesh ( Grid & grid ) [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

Geometry & Prepro::geometry ( ) [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

const Geometry & Prepro::geometry ( ) const [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

bool Prepro::ok ( ) const [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

Partition & Prepro::partition ( ) [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

const Partition & Prepro::partition ( ) const [pure virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

static void Prepro::randomNodePerturbation ( GridFE & grid,
int percent_distortion,
real seed = 0.123456 ) [static]
 

each node in the mesh, not lying on the boundary, is given a random displacement. The size of the displacement is maximum "percent_distortion*hmin/100", where "hmin" is the minimum grid size found in the mesh.

void Prepro::scan ( MenuSystem & menu ) [inline, virtual]
 

Reimplemented in PreproBox, PreproGeomPack, PreproGrummp2D, PreproLaplace, PreproStdGeom, PreproSupEl, PreproSupElSet, and PreproTriangle.

void Prepro::triang2PrismOrTetra ( GridFE & grid_triang,
GridFE & grid,
real zbottom = 0.0,
real ztop = 1.0,
int element_layers = 1,
bool tetragrid = true,
real grading = 1.0,
bool newbind = true ) [static]
 

void Prepro::triang2PrismOrTetra ( GridFE & grid_triang,
GridFE & grid,
FieldFE & zbottom,
FieldFE & ztop,
int element_layers = 1,
bool tetragrid = true,
real grading = 1.0,
bool newbind = true ) [static]
 

static void Prepro::triangle2prism ( GridFE & grid_triang,
GridFE & grid_prism,
real zbottom = 0.0,
real ztop = 1.0,
int element_layers = 1,
real grading = 1.0,
bool newbind = true ) [static]
 

See documentation of one of the overloaded functions.

static void Prepro::triangle2prism ( GridFE & grid_triang,
GridFE & grid_prism,
FieldFE & zbottom,
FieldFE & ztop,
int element_layers = 1,
real grading = 1.0,
bool newbind = true ) [static]
 

see documentation of function "triangle2tetra"

static void Prepro::triangle2tetra ( GridFE & grid_triang,
GridFE & grid_tetra,
real zbottom = 0.0,
real ztop = 1.0,
int element_layers = 1,
real grading = 1.0,
bool newbind = true ) [static]
 

See documentation of one of the overloaded functions.

static void Prepro::triangle2tetra ( GridFE & grid_triang,
GridFE & grid_tetra,
FieldFE & zbottom,
FieldFE & ztop,
int element_layers = 1,
real grading = 1.0,
bool newbind = true ) [static]
 

given a finite element mesh in 2D with triangle ("ElmT3n2D") elements, these functions construct 3D finite element meshes of prisms ("ElmBT6n3D") and tetrahedrals ("ElmT4n3D"), respectively. The nodes in the constructed meshes are obtained by translating the nodes in the triangle mesh in layers. The prism mesh is then obtained by joining the translated triangles in the layers. The tetrahedral mesh can then be obtained by dividing each prism into three tetrahedra. The 3D mesh is between the z values defined by zbottom and ztop which are constants or "fieldFE"s on the original triangular grid. Note that the function is static so that it can be called for any mesh consisting of "ElmT3n2D" elements. The parameter "grading" defines the position of the nodes in intermediate layers, the "grading" parameter is analogous to the grading in "PreproBox". Material types and (boundary) indicators are set from the values given by the triangular grid. The material type of an element in the triangular grid will be set to all elements above the element. Similarly, the nodes above the nodes in the triangular grid will get the same boundary indicator. In addition to this: If the "newbind" parameter is set to "true", then all nodes in the nodal layer number n will get the boundary indicator bind + n, where bind is the number of indicators in the triangular grid, and the nodal layers are counted from below. Consequently the nodes on the nodal surface will get the number "nbind + 1 + element_layers".


The documentation for this class was generated from the following file:
Copyright © 2003 inuTech GmbH. All rights reserved.