SAMRAI::appu::ElevenPatchInterface< DIM > Class Template Reference

This class provides an interface to the Eleven geometry library by Kyle Chand in CASC. The shapes over which the embedded boundary is cut is defined through an XML database, the name of which is specified in the input file. More...

#include <source/apputils/embedded_boundary/ElevenPatchInterface.h>

List of all members.

Public Member Functions

 ElevenPatchInterface (const std::string &object_name, tbox::Pointer< tbox::Database > input_db)
virtual ~ElevenPatchInterface ()
void calculateCutCellInfo (tbox::Pointer< hier::Patch< DIM > > &patch, const int cell_flag_data_id, const int cell_vol_data_id, const int node_flag_data_id, const int cutcell_data_id)
bool isInside (const double *xyz) const
void isInside (const int *nx, const double *dx, const double *origin, int *inout) const
virtual void printClassData (std::ostream &os) const


Detailed Description

template<int DIM>
class SAMRAI::appu::ElevenPatchInterface< DIM >

This class provides an interface to the Eleven geometry library by Kyle Chand in CASC. The shapes over which the embedded boundary is cut is defined through an XML database, the name of which is specified in the input file.

Use of this class first requires that you link with the Eleven library. Next, you must specify a 'ElevenPatchInterface {...}" input entry in the input for the EmbeddedBoundaryGeometry class. In this input you specify the name of the XML database file that defines the surface geometry.

Once an instance of the class is created, SAMRAI will pass patch information to the "calculateCutCellInfo()" class whenever an embedded boundary is constructed on a new level. The eleven interfaces may be used to compute the volume fractions through an inside/outside determination of the nodes of the cell, and also may be used to compute the distance of a particular node from the surface boundary.

Required input keys and data types:

Optional input keys:

A sample input file entry might look like:

 * 
 *   ElevenPatchInterface {
 *      database_file = "circle_r.3.gzxml"
 *      geom_tolerance = 0.01 // 1% of bounding box
 *   }
 * 

See also:
appu::EmbeddedBoundaryGeometry

appu::CutCell


Constructor & Destructor Documentation

template<int DIM>
SAMRAI::appu::ElevenPatchInterface< DIM >::ElevenPatchInterface ( const std::string &  object_name,
tbox::Pointer< tbox::Database input_db 
)

The constructor initializes the eleven library and optionally starts an interactive interface

Parameters:
object_name name of object of this class
input_db the input database which contains radius and center specification.

template<int DIM>
SAMRAI::appu::ElevenPatchInterface< DIM >::~ElevenPatchInterface< DIM > (  )  [virtual]

The destructor does nothing.


Member Function Documentation

template<int DIM>
void SAMRAI::appu::ElevenPatchInterface< DIM >::calculateCutCellInfo ( tbox::Pointer< hier::Patch< DIM > > &  patch,
const int  cell_flag_data_id,
const int  cell_vol_data_id,
const int  node_flag_data_id,
const int  cutcell_data_id 
)

This method computes information about the cut cells on a patch.

template<int DIM>
bool SAMRAI::appu::ElevenPatchInterface< DIM >::isInside ( const double *  xyz  )  const

For a given point, specify whether that point is inside (true) or outside (false) the set of shapes.

Parameters:
xyz double array[DIM] specifying coordinates.

template<int DIM>
void SAMRAI::appu::ElevenPatchInterface< DIM >::isInside ( const int *  nx,
const double *  dx,
const double *  origin,
int *  inout 
) const

For a SET of nodes on a patch, with patch dimensions (number of nodes in each direction) nx[DIM], origin[DIM], and grid spacing dx[DIM], set the integer inout[nx[0]*nx[1]*nx[2]] array to specify whether nodes are inside or outside.

Node is: INSIDE - set inout[ijk] = 1 OUTSIDE - set inout[ijk] = 0

Parameters:
nx integer array [DIM] specifying number of points in each dir
dx double array [DIM] specifying spacing of points in each dir
origin double array [DIM] specifying origin of lower corner
inout int array dimensioned the total number of points (i.e. nx[0]*nx[1]*nx[2]). This is an OUTPUT quantity.

template<int DIM>
void SAMRAI::appu::ElevenPatchInterface< DIM >::printClassData ( std::ostream &  os  )  const [virtual]

Dump data to supplied stream.


The documentation for this class was generated from the following files:
Generated on Thu Jun 18 11:28:21 2009 for SAMRAI by  doxygen 1.5.1