Go to the documentation of this file.
21 #ifndef THUNDEREGG_GMG_MPIINTERPOLATOR_H
22 #define THUNDEREGG_GMG_MPIINTERPOLATOR_H
53 : ilc(coarser_domain, finer_domain)
69 const std::vector<std::pair<
int, std::reference_wrapper<
const PatchInfo<D>>>>& patches,
81 if constexpr (ENABLE_DEBUG) {
83 throw RuntimeError(
"coarse vector is incorrect length. Expected Length of " +
88 throw RuntimeError(
"fine vector is incorrect length. Expected Length of " +
Facilitates communication between a finer domain and a coarser domain.
Definition: InterLevelComm.h:52
const std::vector< std::pair< int, std::reference_wrapper< const PatchInfo< D > > > > & getPatchesWithGhostParent() const
Get the vector of finer patches that have a ghost parent.
Definition: InterLevelComm.h:276
virtual void interpolatePatches(const std::vector< std::pair< int, std::reference_wrapper< const PatchInfo< D >>>> &patches, const Vector< D > &coarser_vector, Vector< D > &finer_vector) const =0
Interpolate values from coarse vector to the finer vector.
Uses a collection of PatchInfo objects to represent the domain of the problem.
Definition: Domain.h:50
void getGhostPatchesFinish(const Vector< D > &vector, Vector< D > &ghost_vector)
Finish the communication for getting ghost values.
Definition: InterLevelComm.h:516
const Domain< D > & getFinerDomain() const
Get the finer Domain.
Definition: InterLevelComm.h:580
MPIInterpolator(const Domain< D > &coarser_domain, const Domain< D > &finer_domain)
Create new MPIInterpolator object.
Definition: MPIInterpolator.h:52
Contains metadata for a patch.
Definition: PatchInfo.h:51
Abstract class for interpolation operators.
Definition: Interpolator.h:35
const std::vector< std::pair< int, std::reference_wrapper< const PatchInfo< D > > > > & getPatchesWithLocalParent() const
Get the vector of finer patches that have a local parent.
Definition: InterLevelComm.h:260
const Domain< D > & getCoarserDomain() const
Get the coarser Domain.
Definition: InterLevelComm.h:574
Base class that makes the necessary mpi calls, derived classes only have to implement interpolatePatc...
Definition: MPIInterpolator.h:38
Vector class for use in thunderegg.
Definition: Vector.h:42
Geometric-Multigrid classes.
Definition: Cycle.h:33
int getNumLocalPatches() const
Get the number of local patches.
Definition: Vector.h:316
void interpolate(const Vector< D > &coarse, Vector< D > &fine) const
interpolation function
Definition: MPIInterpolator.h:79
Vector< D > getNewGhostVector(int num_components) const
Allocate a new vector for ghost patch values.
Definition: InterLevelComm.h:243
ThunderEgg runtime exception.
Definition: RuntimeError.h:36
void getGhostPatchesStart(const Vector< D > &vector, Vector< D > &ghost_vector)
Start the communication for getting ghost values.
Definition: InterLevelComm.h:437