core
Shared MPI block decomposition + asynchronous ghost-layer exchange (header-only C++20)
Loading...
Searching...
No Matches
peclet::core::amr::FvFaceEmit< Dim, Bits > Struct Template Reference

Device-callable reproduction of AmrPoisson's per-cell face walk + geometry. More...

#include <assembly.hpp>

Public Types

using View_t = BlockOctreeView< Dim, Bits >
 
using M = typename View_t::M
 
using Code = typename View_t::Code
 
using Coord = typename View_t::Coord
 

Public Member Functions

double openness (Index leaf, int axis, int dir) const
 
Real areaOf (Coord s) const
 
Real coeff (Coord si, Coord sj) const
 
Coord wrap (long c, int axis) const
 
Real cellWidth (Index i) const
 
Real cellVolume (Index i) const
 
double bcDiag (Index i) const
 Σ over leaf i's Dirichlet-wall faces of A_f/(½·cellWidth) — mirrors AmrPoisson::boundaryDiag.
 
template<class Sink >
void operator() (Index i, Sink &sink) const
 Emit each face of leaf i as sink(neighbourLeaf, coef=openness·A_f/d_f) — the exact enumeration (axis-major, dir −1 then +1, 2:1 sub-faces in bit order) and weights of forEachFaceNeighbor.
 

Static Public Member Functions

static int faceIndex (int axis, int dir)
 

Public Attributes

View_t ov
 device octree (codes/levels/locate)
 
View< const doublealpha
 per-leaf·(2·Dim) openness, or empty when !hasOpen
 
Coord fineExt [Dim] = {}
 periodic-wrap modulus per axis
 
Real h0 = 1.0
 finest cell width
 
bool hasOpen = false
 
bool periodic = true
 
bool immersedWall = false
 

Static Public Attributes

static constexpr int kFaces = 2 * Dim
 

Detailed Description

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
struct peclet::core::amr::FvFaceEmit< Dim, Bits >

Device-callable reproduction of AmrPoisson's per-cell face walk + geometry.

Trivially copyable (Views are handles, the rest are scalars), so it captures by value into Kokkos kernels. Drives both the CSR emit (operator()) and the per-cell diagonal (cellVolume/bcDiag).

Definition at line 38 of file assembly.hpp.

Member Typedef Documentation

◆ View_t

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
using peclet::core::amr::FvFaceEmit< Dim, Bits >::View_t = BlockOctreeView<Dim, Bits>

Definition at line 39 of file assembly.hpp.

◆ M

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
using peclet::core::amr::FvFaceEmit< Dim, Bits >::M = typename View_t::M

Definition at line 40 of file assembly.hpp.

◆ Code

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
using peclet::core::amr::FvFaceEmit< Dim, Bits >::Code = typename View_t::Code

Definition at line 41 of file assembly.hpp.

◆ Coord

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
using peclet::core::amr::FvFaceEmit< Dim, Bits >::Coord = typename View_t::Coord

Definition at line 42 of file assembly.hpp.

Member Function Documentation

◆ faceIndex()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
static int peclet::core::amr::FvFaceEmit< Dim, Bits >::faceIndex ( int  axis,
int  dir 
)
inlinestatic

Definition at line 53 of file assembly.hpp.

Referenced by peclet::core::amr::FvFaceEmit< Dim, Bits >::openness().

◆ openness()

◆ areaOf()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
Real peclet::core::amr::FvFaceEmit< Dim, Bits >::areaOf ( Coord  s) const
inline

◆ coeff()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
Real peclet::core::amr::FvFaceEmit< Dim, Bits >::coeff ( Coord  si,
Coord  sj 
) const
inline

◆ wrap()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
Coord peclet::core::amr::FvFaceEmit< Dim, Bits >::wrap ( long  c,
int  axis 
) const
inline

◆ cellWidth()

◆ cellVolume()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
Real peclet::core::amr::FvFaceEmit< Dim, Bits >::cellVolume ( Index  i) const
inline

◆ bcDiag()

◆ operator()()

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
template<class Sink >
void peclet::core::amr::FvFaceEmit< Dim, Bits >::operator() ( Index  i,
Sink sink 
) const
inline

Member Data Documentation

◆ ov

◆ alpha

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
View<const double> peclet::core::amr::FvFaceEmit< Dim, Bits >::alpha

per-leaf·(2·Dim) openness, or empty when !hasOpen

Definition at line 45 of file assembly.hpp.

Referenced by peclet::core::amr::assembleFv(), and peclet::core::amr::FvFaceEmit< Dim, Bits >::openness().

◆ fineExt

◆ h0

◆ hasOpen

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
bool peclet::core::amr::FvFaceEmit< Dim, Bits >::hasOpen = false

◆ periodic

◆ immersedWall

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
bool peclet::core::amr::FvFaceEmit< Dim, Bits >::immersedWall = false

◆ kFaces

template<int Dim, unsigned Bits = (Dim == 2 ? 32u : (Dim == 3 ? 21u : 16u))>
constexpr int peclet::core::amr::FvFaceEmit< Dim, Bits >::kFaces = 2 * Dim
staticconstexpr

Definition at line 52 of file assembly.hpp.

Referenced by peclet::core::amr::FvFaceEmit< Dim, Bits >::openness().


The documentation for this struct was generated from the following file: