18#ifndef __WEIPA_RIPLEYDOMAIN_H__
19#define __WEIPA_RIPLEYDOMAIN_H__
21#include <weipa/DomainChunk.h>
22#include <weipa/RipleyElements.h>
23#include <boost/enable_shared_from_this.hpp>
44 virtual bool writeToSilo(DBfile* dbfile,
const std::string& pathInSilo,
Base class for all escript domains.
Definition: AbstractDomain.h:51
Abstract base class for weipa's interface to an Escript domain or one chunk thereof if domain decompo...
Definition: DomainChunk.h:47
Represents a full Ripley domain including nodes and elements.
Definition: weipa/src/RipleyDomain.h:37
virtual DataVar_ptr getDataVarByName(const std::string &name) const
Creates and returns a variable with domain data.
Definition: weipa/src/RipleyDomain.cpp:161
std::string siloPath
Definition: weipa/src/RipleyDomain.h:66
virtual ElementData_ptr getElementsByName(const std::string &name) const
Returns element data with given name.
Definition: weipa/src/RipleyDomain.cpp:193
virtual NodeData_ptr getNodes() const
Returns a pointer to the full nodes.
Definition: weipa/src/RipleyDomain.h:57
virtual StringVec getMeshNames() const
Returns the names of all meshes within this domain.
Definition: weipa/src/RipleyDomain.cpp:130
virtual ~RipleyDomain()
Definition: weipa/src/RipleyDomain.h:41
virtual bool initFromFile(const std::string &filename)
Reads the domain from a dump file.
Definition: weipa/src/RipleyDomain.cpp:71
RipleyElements_ptr cells
Definition: weipa/src/RipleyDomain.h:64
RipleyElements_ptr faces
Definition: weipa/src/RipleyDomain.h:65
virtual bool initFromEscript(const escript::AbstractDomain *domain)
Initialises the domain using an escript domain instance.
Definition: weipa/src/RipleyDomain.cpp:50
virtual Centering getCenteringForFunctionSpace(int fsCode) const
Returns whether data on given function space is node or cell centered.
Definition: weipa/src/RipleyDomain.cpp:77
virtual NodeData_ptr getMeshByName(const std::string &name) const
Returns the node mesh with given name.
Definition: weipa/src/RipleyDomain.cpp:204
virtual ElementData_ptr getElementsForFunctionSpace(int fsCode) const
Returns the element data for given function space code.
Definition: weipa/src/RipleyDomain.cpp:97
RipleyNodes_ptr nodes
Definition: weipa/src/RipleyDomain.h:63
virtual NodeData_ptr getMeshForFunctionSpace(int fsCode) const
Returns the node mesh for given function space code.
Definition: weipa/src/RipleyDomain.cpp:83
virtual void removeGhostZones(int ownIndex)
Removes 'ghost' elements and nodes.
Definition: weipa/src/RipleyDomain.cpp:229
virtual void reorderGhostZones(int ownIndex)
Reorders elements so that 'ghost' elements (i.e. those that do not belong to ownIndex) appear last.
Definition: weipa/src/RipleyDomain.cpp:216
bool initialized
Definition: weipa/src/RipleyDomain.h:62
virtual StringVec getVarNames() const
Returns the names of all 'special' domain variables.
Definition: weipa/src/RipleyDomain.cpp:146
virtual std::string getSiloPath() const
Returns the absolute path within Silo file if writeToSilo() or setSiloPath() was called before,...
Definition: weipa/src/RipleyDomain.h:58
virtual void setSiloPath(const std::string &path)
Sets the silo path to be used when saving to a Silo file.
Definition: weipa/src/RipleyDomain.h:59
RipleyDomain()
Definition: weipa/src/RipleyDomain.cpp:36
virtual bool writeToSilo(DBfile *dbfile, const std::string &pathInSilo, const StringVec &labels, const StringVec &units, bool writeMeshData)
Writes the domain to a Silo file.
Definition: weipa/src/RipleyDomain.cpp:243
Definition: DataVar.cpp:51
std::vector< std::string > StringVec
Definition: weipa.h:61
boost::shared_ptr< ElementData > ElementData_ptr
Definition: weipa.h:67
boost::shared_ptr< RipleyElements > RipleyElements_ptr
Definition: RipleyElements.h:34
Centering
Definition: DomainChunk.h:31
boost::shared_ptr< NodeData > NodeData_ptr
Definition: weipa.h:69
boost::shared_ptr< DataVar > DataVar_ptr
Definition: weipa.h:65
boost::shared_ptr< RipleyNodes > RipleyNodes_ptr
Definition: RipleyNodes.h:32