79 void read(std::istream& is)
override;
84 void write(std::ostream& os)
const override;
139 void setNZ(std::size_t nZ);
144 std::size_t
getNZ()
const;
149 void setNY(std::size_t nY);
154 std::size_t
getNY()
const;
159 void setNX(std::size_t nX);
164 std::size_t
getNX()
const;
169 void setN(std::size_t
n);
174 void setN(std::array<std::size_t, 3>
n);
const unsigned n
Definition: CG3DPackingUnitTest.cpp:32
Base class of all CG objects, needed to store the various CG objects in the CGHandler.
Definition: BaseCG.h:57
virtual Mdouble getWidth() const =0
Returns width_, the coarse-graining width.
void setHX(Mdouble h)
Sets nX_ the number of spatial mesh points in the X-direction. Instead of explicitly defining nX,...
Definition: BaseCG.cc:250
void setNY(std::size_t nY)
Sets nY_, the number of spatial mesh points in the y-direction.
Definition: BaseCG.cc:112
Mdouble getTimeMax() const
Returns timeMax_, the upper limit of the temporal domain.
Definition: BaseCG.cc:181
~BaseCG() override=default
Default destructor, does nothing.
void setMax(Vec3D max)
Sets max_, the upper limit of the spatial domain.
Definition: BaseCG.cc:171
void setVerbose(const bool verbose)
Definition: BaseCG.h:279
bool averageBeyondDomain_
Determines whether particles outside the domain are considered when computing the averaged fields.
Definition: BaseCG.h:368
BaseCG(const BaseCG &p)=default
Default copy constructor, copies all values.
void setSelectedParticle(const std::function< const bool(const BaseInteractable *)> &selectedParticle)
Definition: BaseCG.cc:237
Mdouble timeMin_
Definition: BaseCG.h:333
void setZ(Mdouble min, Mdouble max)
Sets min_.Z, max_.Z, the limits of the spatial domain in Z.
Definition: BaseCG.cc:198
File statFile
File class to handle the output into a .stat file.
Definition: BaseCG.h:376
void setNX(std::size_t nX)
Sets nX_, the number of spatial mesh points in the x-direction.
Definition: BaseCG.cc:122
std::size_t getNY() const
Returns nY_, the number of spatial mesh points in the y-direction.
Definition: BaseCG.cc:117
Mdouble getEps() const
Definition: BaseCG.cc:97
void setHY(Mdouble h)
Sets nX_ the number of spatial mesh points in the X-direction. Instead of explicitly defining nX,...
Definition: BaseCG.cc:259
void setYGrid(Mdouble min, Mdouble max, Mdouble h)
Definition: BaseCG.cc:210
void setHandler(CGHandler *handler)
Sets handler_, the pointer to the CGHandler.
Definition: BaseCG.cc:73
virtual void setWidth(Mdouble width)=0
Sets width_, the coarse-graining width.
virtual void evaluate()=0
Called after a given number of time steps (statFile::saveCount_) to evaluate the CG fields.
std::size_t nY_
Definition: BaseCG.h:314
void clear()
This class seems to have no use (?), but is required for any derivative of BaseObject.
Definition: BaseCG.cc:46
Vec3D min_
Definition: BaseCG.h:345
Mdouble eps_
Definition: BaseCG.h:325
BaseCG()
Simple constructor, sets default values.
Definition: BaseCG.cc:29
void setTimeMin(Mdouble timeMin)
Sets timeMin_, the lower limit of the temporal domain.
Definition: BaseCG.cc:146
void setX(Mdouble min, Mdouble max)
Sets min_.X, max_.X, the limits of the spatial domain in X.
Definition: BaseCG.cc:186
void setH(Mdouble h)
Sets nX_, nY_, nZ_, the number of spatial mesh points in each cartesian direction....
Definition: BaseCG.cc:242
CGHandler * getHandler() const
Returns handler_, a pointer to the CGHandler.
Definition: BaseCG.cc:81
virtual void finish()=0
Called at the end of the DPM simulation to finish the cg evaluation and to close the statFile.
void setAverageBeyondDomain(const bool val)
Definition: BaseCG.h:275
std::function< bool(const BaseInteractable *)> selectedParticle_
Definition: BaseCG.h:355
Vec3D getMin() const
Returns min_, the lower limit of the spatial domain.
Definition: BaseCG.cc:156
void setXGrid(Mdouble min, Mdouble max, Mdouble h)
Definition: BaseCG.cc:204
Mdouble getTimeMin() const
Returns timeMin_, the lower limit of the temporal domain.
Definition: BaseCG.cc:176
void setEps(Mdouble eps)
Definition: BaseCG.cc:92
std::size_t nZ_
Definition: BaseCG.h:319
void write(std::ostream &os) const override
Writes class content into an output stream, usually a stat file.
Definition: BaseCG.cc:59
void setMin(Vec3D min)
Sets max_, the lower limit of the spatial domain.
Definition: BaseCG.cc:166
virtual void initialise()=0
Called at the beginning of the DPM simulation to initialise the cg evaluation and to open the statFil...
void setZGrid(Mdouble min, Mdouble max, Mdouble h)
Definition: BaseCG.cc:216
void selectSpecies(unsigned speciesIndex)
Definition: BaseCG.cc:229
virtual void setRadius(Mdouble radius)=0
bool getVerbose() const
Definition: BaseCG.h:281
void setNZ(std::size_t nZ)
Sets nZ_, the number of spatial mesh points in the z-direction.
Definition: BaseCG.cc:102
virtual BaseCG * copy() const =0
Copy operator. Required for BaseHandler::copyAndAddObject.
std::size_t getNZ() const
Returns nZ_, the number of spatial mesh points in the z-direction.
Definition: BaseCG.cc:107
void setTimeMax(Mdouble timeMax)
Sets timeMax_, the upper limit of the temporal domain.
Definition: BaseCG.cc:151
void setGrid(Vec3D min, Vec3D max, Mdouble h)
Definition: BaseCG.cc:222
void setN(std::size_t n)
Sets nX_, nY_, nZ_, the number of spatial mesh points in each cartesian direction.
Definition: BaseCG.cc:132
std::size_t nX_
Definition: BaseCG.h:309
std::size_t getNX() const
Returns nX_, the number of spatial mesh points in the x-direction.
Definition: BaseCG.cc:127
Mdouble timeMax_
Definition: BaseCG.h:338
CGHandler * handler_
Definition: BaseCG.h:300
void setHZ(Mdouble h)
Sets nX_ the number of spatial mesh points in the X-direction. Instead of explicitly defining nX,...
Definition: BaseCG.cc:268
bool verbose_
Definition: BaseCG.h:370
void read(std::istream &is) override
Currently, no read functions are implemented for the CGHandler, but the function is required for any ...
Definition: BaseCG.cc:52
virtual void setStandardDeviation(Mdouble std)=0
bool getAverageBeyondDomain() const
Definition: BaseCG.h:277
Vec3D max_
Definition: BaseCG.h:350
Vec3D getMax() const
Returns max_, the upper limit of the spatial domain.
Definition: BaseCG.cc:161
void setY(Mdouble min, Mdouble max)
Sets min_.Y, max_.Y, the limits of the spatial domain in Y.
Definition: BaseCG.cc:192
Defines the basic properties that a interactable object can have.
Definition: BaseInteractable.h:55
It is an abstract base class due to the purely virtual functions declared below. Even if the function...
Definition: BaseObject.h:51
Container that stores all CG objects.
Definition: CGHandler.h:65
bool verbose
Definition: statXZ.cpp:28