escript  Revision_
Public Member Functions | Protected Attributes
weipa::RipleyNodes Class Reference

Stores and manipulates ripley mesh nodes. More...

#include <RipleyNodes.h>

Inheritance diagram for weipa::RipleyNodes:
weipa::NodeData

List of all members.

Public Member Functions

 RipleyNodes (const std::string &meshName)
 Constructor with mesh name.
 RipleyNodes (RipleyNodes_ptr fullNodes, IntVec &requiredNodes, const std::string &meshName)
 RipleyNodes (const RipleyNodes &m)
 Copy constructor.
virtual ~RipleyNodes ()
 Virtual destructor.
bool initFromRipley (const ripley::RipleyDomain *ripleyDomain)
 Initialises with ripley domain.
bool writeToSilo (DBfile *dbfile)
 Writes node data to a Silo file.
virtual void writeCoordinatesVTK (std::ostream &os, int ownIndex)
 Writes coordinates to a stream in VTK text format.
void setSiloPath (const std::string &path)
 Sets the silo path to be used when saving.
const IntVecgetVarDataByName (const std::string &name) const
 Returns an array of nodal data by the given name.
virtual StringVec getVarNames () const
 Returns a vector with the mesh variable names.
virtual std::string getName () const
 Returns the name of this node mesh.
std::string getFullSiloName () const
 Returns full Silo mesh name, e.g. "/block0000/Nodes".
virtual const IntVecgetNodeIDs () const
 Returns the node ID array.
virtual const IntVecgetNodeDistribution () const
 Returns the node distribution array.
virtual const IntVecgetGlobalNodeIndices () const
 Returns the global node index array.
virtual const CoordArraygetCoords () const
 Returns the coordinates of the mesh nodes.
virtual int getNumDims () const
 Returns the dimensionality of this mesh (2 or 3).
virtual int getNumNodes () const
 Returns the number of mesh nodes.
virtual int getGlobalNumNodes () const
 Returns the total number of mesh nodes for a distributed mesh.

Protected Attributes

CoordArray coords
int numDims
 x, y[, z] coordinates of nodes
int numNodes
 dimensionality (2 or 3)
int globalNumNodes
 number of nodes
IntVec nodeID
 global number of nodes
IntVec nodeTag
 node IDs
IntVec nodeDist
 node tags
std::string name
 node distribution
std::string siloPath
 the name of this node mesh

Detailed Description

Stores and manipulates ripley mesh nodes.

This class provides functionality to manipulate the nodes of a ripley domain. It is able to load node data from dump files or retrieve it from a RipleyDomain instance.


Constructor & Destructor Documentation

weipa::RipleyNodes::RipleyNodes ( const std::string &  meshName)

Constructor with mesh name.

weipa::RipleyNodes::RipleyNodes ( RipleyNodes_ptr  fullNodes,
IntVec requiredNodes,
const std::string &  meshName 
)

Copy constructor.

References coords, paso::util::copy(), globalNumNodes, name, nodeDist, nodeID, nodeTag, numDims, and numNodes.

Virtual destructor.

References coords.


Member Function Documentation

virtual const CoordArray& weipa::RipleyNodes::getCoords ( ) const [inline, virtual]

Returns the coordinates of the mesh nodes.

Implements weipa::NodeData.

References coords.

std::string weipa::RipleyNodes::getFullSiloName ( ) const [inline, virtual]

Returns full Silo mesh name, e.g. "/block0000/Nodes".

Implements weipa::NodeData.

References name, and siloPath.

Referenced by writeToSilo().

virtual const IntVec& weipa::RipleyNodes::getGlobalNodeIndices ( ) const [inline, virtual]

Returns the global node index array.

Implements weipa::NodeData.

References nodeID.

virtual int weipa::RipleyNodes::getGlobalNumNodes ( ) const [inline, virtual]

Returns the total number of mesh nodes for a distributed mesh.

Implements weipa::NodeData.

References globalNumNodes.

virtual std::string weipa::RipleyNodes::getName ( ) const [inline, virtual]

Returns the name of this node mesh.

Implements weipa::NodeData.

References name.

virtual const IntVec& weipa::RipleyNodes::getNodeDistribution ( ) const [inline, virtual]

Returns the node distribution array.

Implements weipa::NodeData.

References nodeDist.

virtual const IntVec& weipa::RipleyNodes::getNodeIDs ( ) const [inline, virtual]

Returns the node ID array.

Implements weipa::NodeData.

References nodeID.

virtual int weipa::RipleyNodes::getNumDims ( ) const [inline, virtual]

Returns the dimensionality of this mesh (2 or 3).

Implements weipa::NodeData.

References numDims.

virtual int weipa::RipleyNodes::getNumNodes ( ) const [inline, virtual]

Returns the number of mesh nodes.

Implements weipa::NodeData.

References numNodes.

const IntVec & weipa::RipleyNodes::getVarDataByName ( const std::string &  name) const

Returns an array of nodal data by the given name.

The name must be one of the names returned by getVarNames().

References nodeID, and nodeTag.

Returns a vector with the mesh variable names.

Implements weipa::NodeData.

void weipa::RipleyNodes::setSiloPath ( const std::string &  path) [inline]

Sets the silo path to be used when saving.

References siloPath.

void weipa::RipleyNodes::writeCoordinatesVTK ( std::ostream &  os,
int  ownIndex 
) [virtual]

Writes coordinates to a stream in VTK text format.

Implements weipa::NodeData.

References coords, nodeDist, nodeID, numDims, and numNodes.

bool weipa::RipleyNodes::writeToSilo ( DBfile *  dbfile)

Writes node data to a Silo file.

References getFullSiloName(), nodeID, nodeTag, numNodes, and siloPath.


Member Data Documentation

number of nodes

Referenced by getGlobalNumNodes(), initFromRipley(), and RipleyNodes().

std::string weipa::RipleyNodes::name [protected]

node distribution

Referenced by getFullSiloName(), getName(), and RipleyNodes().

int weipa::RipleyNodes::numDims [protected]

x, y[, z] coordinates of nodes

Referenced by getNumDims(), initFromRipley(), RipleyNodes(), and writeCoordinatesVTK().

dimensionality (2 or 3)

Referenced by getNumNodes(), initFromRipley(), RipleyNodes(), writeCoordinatesVTK(), and writeToSilo().

std::string weipa::RipleyNodes::siloPath [protected]

the name of this node mesh

Referenced by getFullSiloName(), setSiloPath(), and writeToSilo().


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