Go to the documentation of this file.
17 #ifndef __WEIPA_SPECKLEYNODES_H__
18 #define __WEIPA_SPECKLEYNODES_H__
20 #include <weipa/NodeData.h>
45 const std::string& meshName);
74 virtual std::string
getName()
const {
return name; }
116 if (result.length() == 0 || *result.rbegin() !=
'/')
124 #endif // __WEIPA_SPECKLEYNODES_H__
IntVec nodeTag
node IDs
Definition: SpeckleyNodes.h:105
int numDims
x, y[, z] coordinates of nodes
Definition: SpeckleyNodes.h:101
virtual double getLocalCoordinate(dim_t index, int dim) const =0
returns the index'th coordinate value in given dimension for this rank
CoordArray coords
Definition: SpeckleyNodes.h:100
std::string siloPath
the name of this node mesh
Definition: SpeckleyNodes.h:108
IntVec nodeID
global number of nodes
Definition: SpeckleyNodes.h:104
boost::shared_ptr< SpeckleyNodes > SpeckleyNodes_ptr
Definition: SpeckleyNodes.h:29
virtual StringVec getVarNames() const
Returns a vector with the mesh variable names.
Definition: SpeckleyNodes.cpp:193
Definition: DataVar.cpp:49
const IntVec & getVarDataByName(const std::string &name) const
Returns an array of nodal data by the given name.
Definition: SpeckleyNodes.cpp:180
bool writeToSilo(DBfile *dbfile)
Writes node data to a Silo file.
Definition: SpeckleyNodes.cpp:225
Definition: AbstractAssembler.cpp:17
void copy(dim_t N, double *out, const double *in)
out = in
Definition: PasoUtil.h:110
Definition: NodeData.h:37
IntVec nodeDist
node tags
Definition: SpeckleyNodes.h:106
void setSiloPath(const std::string &path)
Sets the silo path to be used when saving.
Definition: SpeckleyNodes.h:62
index_t dim_t
Definition: DataTypes.h:87
const index_t * borrowSampleReferenceIDs(int fsType) const =0
returns the array of reference numbers for a function space type
std::map< int, size_t > IndexMap
Definition: weipa.h:61
std::vector< float * > CoordArray
Definition: weipa.h:60
virtual int getGlobalNumNodes() const
Returns the total number of mesh nodes for a distributed mesh.
Definition: SpeckleyNodes.h:97
int globalNumNodes
number of nodes
Definition: SpeckleyNodes.h:103
virtual const IntVec & getGlobalNodeIndices() const
Returns the global node index array.
Definition: SpeckleyNodes.h:85
virtual ~SpeckleyNodes()
Virtual destructor.
Definition: SpeckleyNodes.cpp:109
bool initFromSpeckley(const speckley::SpeckleyDomain *speckleyDomain)
Initialises with speckley domain.
Definition: SpeckleyNodes.cpp:119
virtual const IntVec & getNodeIDs() const
Returns the node ID array.
Definition: SpeckleyNodes.h:79
SpeckleyDomain extends the AbstractContinuousDomain interface for the Speckley library and is the bas...
Definition: speckley/src/SpeckleyDomain.h:95
int numNodes
dimensionality (2 or 3)
Definition: SpeckleyNodes.h:102
virtual const CoordArray & getCoords() const
Returns the coordinates of the mesh nodes.
Definition: SpeckleyNodes.h:88
virtual IndexVector getNodeDistribution() const =0
returns the node distribution vector
virtual const dim_t * getNumNodesPerDim() const =0
returns the number of nodes per MPI rank in each dimension
virtual std::string getName() const
Returns the name of this node mesh.
Definition: SpeckleyNodes.h:73
virtual std::pair< int, dim_t > getDataShape(int fsType) const
returns the number of data points per sample, and the number of samples as a pair.
Definition: speckley/src/SpeckleyDomain.cpp:120
virtual void writeCoordinatesVTK(std::ostream &os, int ownIndex)
Writes coordinates to a stream in VTK text format.
Definition: SpeckleyNodes.cpp:204
int index_t
type for array/matrix indices used both globally and on each rank
Definition: DataTypes.h:82
std::string getFullSiloName() const
Returns full Silo mesh name, e.g. "/block0000/Nodes".
Definition: SpeckleyNodes.h:112
std::vector< std::string > StringVec
Definition: weipa.h:59
virtual int getNumDims() const
Returns the dimensionality of this mesh (2 or 3).
Definition: SpeckleyNodes.h:91
virtual int getDim() const
returns the number of spatial dimensions of the domain
Definition: speckley/src/SpeckleyDomain.h:167
virtual int getNumNodes() const
Returns the number of mesh nodes.
Definition: SpeckleyNodes.h:94
std::vector< index_t > IndexVector
Definition: Speckley.h:55
SpeckleyNodes(const std::string &meshName)
Constructor with mesh name.
Definition: SpeckleyNodes.cpp:38
virtual dim_t getNumDataPointsGlobal() const =0
returns the number of data points summed across all MPI processes
std::vector< int > IntVec
Definition: weipa.h:58
std::string name
node distribution
Definition: SpeckleyNodes.h:107
virtual const IntVec & getNodeDistribution() const
Returns the node distribution array.
Definition: SpeckleyNodes.h:82
Stores and manipulates speckley mesh nodes.
Definition: SpeckleyNodes.h:37
Definition: Speckley.h:72