|
flow 1.3.0
Kokkos cut-cell IBM incompressible Navier-Stokes solver + pnm pore extraction
|
#include <mac_velocity_mg.hpp>
Classes | |
| struct | Level |
Public Types | |
| using | Comm = void * |
Public Member Functions | |
| void | setMetric (const double w[3], const double hp[3]) |
| Per-axis metric of the physical domain (doc/anisotropic_metric.md §1.1): the weights w_a = 1/h_a'^2, which every level operator carries as b_a^L = nu_dt * w_a / cfac_a^2 (C1), and the spacings hp_a = h_a' that the aspect-ratio COARSENING rule of §5 reads (C3). | |
| std::vector< C3 > | levelRatios () const |
| The per-level coarsening ratio actually chosen (the level table of §5; the two hierarchies share one rule, so on the same grid this equals CutcellMG::levelRatios()). | |
| void | init (int nx, int ny, int nz, int nLevels) |
| bool | touches (const Level &lv, int f) const |
| int | nLevels () const |
| Level & | level (int L) |
| int | levels () const |
| void | setFineStencil (FPC AC, FPC AW, FPC AE, FPC AS, FPC AN, FPC AB, FPC AT) |
| void | setStaircase (CCConst theta0, CCConst solid0, CCConst resmask0, double nu_dt, double idiag, double thresh) |
| void | setStaircaseBc (int comp, CCConst theta0, CCConst solid0, CCConst resmask0, double nu_dt, double idiag, double thresh, bool upwind=false, double fouw=0.0) |
| void | restrictAdvVelocities (CCConst u0, CCConst v0, CCConst w0) |
| void | buildUpwindCoarse (int comp, double nu_dt, double idiag, double fouw) |
| void | setBC (const int bc[6]) |
| void | setBcApplyL0 (std::function< void(CCField)> fn) |
| void | setChebyshevSmoother (bool on, int degree=0, double eigRatio=10.0) |
| bool | chebyshevSmoother () const |
| void | setAspectThreshold (double theta) |
| Anisotropic-coarsening aspect threshold theta (doc/anisotropic_metric.md §5.1). | |
| void | setDomainBcOp (int comp, double nu_dt, double idiag) |
| int | solve (CCConst b, CCField x, int nvc, int pre, int post, int bottom, double tol=0.0, Comm comm=nullComm(), double resTol=0.0) |
| double | lastResidualRatio () const |
| void | vcycle (int L) |
| void | smooth (Level &lv, int sweeps, bool isL0) |
| void | chebSmooth (Level &lv, int degree, bool isL0, CCConst pin) |
| void | fill (Level &lv, CCField f) |
| void | zeroBcGhosts (Level &lv, CCField f) |
| void | fillProlongBcGhosts (Level &lv) |
| void | fillAxis (Level &lv, CCField f, int axis) |
Static Public Member Functions | |
| static void * | nullComm () |
Static Public Attributes | |
| static constexpr int | G = 2 |
Definition at line 297 of file mac_velocity_mg.hpp.
Definition at line 304 of file mac_velocity_mg.hpp.
Definition at line 305 of file mac_velocity_mg.hpp.
Per-axis metric of the physical domain (doc/anisotropic_metric.md §1.1): the weights w_a = 1/h_a'^2, which every level operator carries as b_a^L = nu_dt * w_a / cfac_a^2 (C1), and the spacings hp_a = h_a' that the aspect-ratio COARSENING rule of §5 reads (C3).
Call BEFORE init/initMpi (trap 5): the level table is built there. The default (1,1,1)/(1,1,1) is the isotropic / cell-unit path – every coefficient multiplied by exactly 1.0, and the aspect rule inert by construction (aniso_ false -> today's level table verbatim).
Definition at line 329 of file mac_velocity_mg.hpp.
Referenced by compare(), and peclet::flow::Solver< Grid >::initVelocityMg().
|
inline |
The per-level coarsening ratio actually chosen (the level table of §5; the two hierarchies share one rule, so on the same grid this equals CutcellMG::levelRatios()).
Definition at line 338 of file mac_velocity_mg.hpp.
|
inline |
Definition at line 347 of file mac_velocity_mg.hpp.
References G, peclet::flow::CutcellMG::mgChooseRatio(), nLevels(), peclet::flow::C3::x, peclet::flow::C3::y, and peclet::flow::C3::z.
Referenced by peclet::flow::Solver< Grid >::initVelocityMg().
Definition at line 494 of file mac_velocity_mg.hpp.
Referenced by fillProlongBcGhosts(), setDomainBcOp(), setStaircaseBc(), solve(), and zeroBcGhosts().
|
inline |
Definition at line 501 of file mac_velocity_mg.hpp.
Referenced by init().
|
inline |
Definition at line 502 of file mac_velocity_mg.hpp.
|
inline |
Definition at line 505 of file mac_velocity_mg.hpp.
Referenced by compare(), and peclet::flow::Solver< Grid >::initVelocityMg().
|
inline |
Definition at line 508 of file mac_velocity_mg.hpp.
References AC.
Referenced by main(), and peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 522 of file mac_velocity_mg.hpp.
References peclet::flow::buildVelocityStaircase(), G, peclet::flow::restrictAvg(), and peclet::flow::thresholdMask().
Referenced by main(), setStaircaseBc(), and peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 554 of file mac_velocity_mg.hpp.
References peclet::flow::boundaryFold(), peclet::flow::buildAdvCoarse(), G, peclet::flow::pinSolidRows(), setStaircase(), touches(), and peclet::flow::zeroPlane().
Referenced by peclet::flow::Solver< Grid >::smoothComp().
Definition at line 602 of file mac_velocity_mg.hpp.
References fill(), G, and peclet::flow::restrictAvg().
Referenced by peclet::flow::Solver< Grid >::step().
|
inline |
Definition at line 620 of file mac_velocity_mg.hpp.
References peclet::flow::buildAdvCoarse(), and G.
Referenced by peclet::flow::Solver< Grid >::smoothComp().
Definition at line 639 of file mac_velocity_mg.hpp.
Referenced by peclet::flow::Solver< Grid >::initVelocityMg().
Definition at line 652 of file mac_velocity_mg.hpp.
Referenced by peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 660 of file mac_velocity_mg.hpp.
Referenced by peclet::flow::Solver< Grid >::setVelocityMgChebyshev().
|
inline |
Definition at line 665 of file mac_velocity_mg.hpp.
Anisotropic-coarsening aspect threshold theta (doc/anisotropic_metric.md §5.1).
Definition at line 667 of file mac_velocity_mg.hpp.
Referenced by peclet::flow::Solver< Grid >::setMultigridAspectThreshold().
Definition at line 675 of file mac_velocity_mg.hpp.
References peclet::flow::boundaryFold(), peclet::flow::buildConstAniso(), G, touches(), and peclet::flow::zeroPlane().
Referenced by peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 734 of file mac_velocity_mg.hpp.
References fill(), G, peclet::flow::ibmStencilJacobiBounds(), peclet::flow::maxAbsDiffInner(), peclet::flow::maxAbsInner(), peclet::flow::residualVarPin(), touches(), vcycle(), and peclet::flow::zeroPlane().
Referenced by main(), and peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 824 of file mac_velocity_mg.hpp.
Referenced by peclet::flow::Solver< Grid >::smoothComp().
|
inline |
Definition at line 827 of file mac_velocity_mg.hpp.
References fill(), fillProlongBcGhosts(), G, peclet::flow::mulMask(), peclet::flow::prolongAdd(), peclet::flow::prolongMasked(), peclet::flow::residualVarPin(), peclet::flow::restrictAvg(), smooth(), and vcycle().
Definition at line 859 of file mac_velocity_mg.hpp.
References chebSmooth(), fill(), G, peclet::flow::ibmRbgsStencilColor(), and peclet::flow::ibmRbgsStencilColorBox().
Referenced by vcycle().
Definition at line 900 of file mac_velocity_mg.hpp.
References fill(), G, peclet::flow::ibmChebUpdate(), peclet::flow::ChebCoeffs::next(), and peclet::flow::residualVarPin().
Referenced by smooth().
Definition at line 922 of file mac_velocity_mg.hpp.
References fillAxis(), and zeroBcGhosts().
Referenced by chebSmooth(), restrictAdvVelocities(), smooth(), solve(), and vcycle().
Definition at line 938 of file mac_velocity_mg.hpp.
References peclet::flow::fillBcGhost(), G, and touches().
Referenced by fill().
Definition at line 946 of file mac_velocity_mg.hpp.
References peclet::flow::fillBcGhost(), G, and touches().
Referenced by vcycle().
|
staticconstexpr |
Definition at line 299 of file mac_velocity_mg.hpp.
Referenced by buildUpwindCoarse(), chebSmooth(), fillAxis(), fillProlongBcGhosts(), init(), restrictAdvVelocities(), setDomainBcOp(), setStaircase(), setStaircaseBc(), smooth(), solve(), vcycle(), and zeroBcGhosts().