|
core
Shared MPI block decomposition + asynchronous ghost-layer exchange (header-only C++20)
|
Geometric-multigrid V-cycle on a graded distributed octree, built on DistributedFvOperator. More...
#include <distributed_fv.hpp>
Public Types | |
| using | DO = DistributedOctree< Dim, Bits > |
| using | BO = typename DO::Octree |
| using | M = typename DO::M |
Public Member Functions | |
| void | build (const DO &finest) |
| Build the hierarchy from an already-graded, 2:1-balanced finest octree (openness-free; the coarsest is chained to the uniform DistributedMultigrid). | |
| template<class OpenFn > | |
| void | build (const DO &finest, OpenFn &&openFn) |
Build with cut-cell openness openFn on every level (each level re-samples the geometry at its own face centroids — a rediscretized coarse operator). | |
| std::size_t | numLevels () const |
| DistributedFvOperator< Dim, Bits > & | op (std::size_t L=0) |
| Index | numLeaves (std::size_t L=0) const |
| void | vcycle (std::vector< double > &x, const std::vector< double > &b, int pre=2, int post=2, int innerCycles=6, double omega=0.8, std::size_t L=0) |
One V-cycle of L u = rhs on level L (default finest), correction scheme. | |
Geometric-multigrid V-cycle on a graded distributed octree, built on DistributedFvOperator.
The hierarchy keeps the same ORB blocks and coarsens each rank's local octree (coarsenIf, which never merges the root brick — it is guarded by level < lmax — so every rank stops at the uniform root brick and no cross-block re-decomposition is needed). 2:1 grading is preserved by uniform coarsening; the consistent per-level operator handles whatever grading remains. Ranks reach the root brick after DIFFERENT numbers of coarsening steps (deep vs shallow blocks), so the level count is padded to the global max with identity root-brick levels — otherwise the per-level collective gather deadlocks at np>1 (see buildImpl).
Transfers are local: a fine leaf's covering coarse leaf is in the same block (parents never cross root cells), so restriction (average children) and prolongation (piecewise-constant) need no communication — only the per-level Jacobi smoother uses the operator's ghost halo. Jacobi + local transfers are all order-independent / per-cell ⇒ the V-cycle is bit-identical COMM_WORLD vs COMM_SELF. The coarsest level (uniform root brick) is solved with extra Jacobi.
Definition at line 380 of file distributed_fv.hpp.
| using peclet::core::amr::GradedDistributedMultigrid< Dim, Bits >::DO = DistributedOctree<Dim, Bits> |
Definition at line 382 of file distributed_fv.hpp.
| using peclet::core::amr::GradedDistributedMultigrid< Dim, Bits >::BO = typename DO::Octree |
Definition at line 383 of file distributed_fv.hpp.
| using peclet::core::amr::GradedDistributedMultigrid< Dim, Bits >::M = typename DO::M |
Definition at line 384 of file distributed_fv.hpp.
|
inline |
Build the hierarchy from an already-graded, 2:1-balanced finest octree (openness-free; the coarsest is chained to the uniform DistributedMultigrid).
Definition at line 388 of file distributed_fv.hpp.
|
inline |
Build with cut-cell openness openFn on every level (each level re-samples the geometry at its own face centroids — a rediscretized coarse operator).
The chained uniform bottom solve is openness-free, so for openness the coarsest is bottom-solved with Jacobi on the (correct, openness-carrying) coarsest operator.
Definition at line 397 of file distributed_fv.hpp.
|
inline |
Definition at line 486 of file distributed_fv.hpp.
|
inline |
Definition at line 487 of file distributed_fv.hpp.
|
inline |
Definition at line 488 of file distributed_fv.hpp.
|
inline |
One V-cycle of L u = rhs on level L (default finest), correction scheme.
The coarsest (uniform root brick) is solved by innerCycles V-cycles of the uniform DistributedMultigrid on the root grid.
Definition at line 493 of file distributed_fv.hpp.
References peclet::core::amr::GradedDistributedMultigrid< Dim, Bits >::vcycle().
Referenced by peclet::core::amr::GradedDistributedMultigrid< Dim, Bits >::vcycle().