Mallard 0.8.0
Unstructured, GPU accelerated, high-order finite volume CFD solver
Mallard website
Loading...
Searching...
No Matches
SpeciesSlotFunctor< Eval > Struct Template Reference

Species fluxes by mass-flux upwinding (Larrouturou 1991), F_k = max(mdot, 0) Y_k^L + min(mdot, 0) Y_k^R, split by the side each part comes from: each cell writes, for each of its faces, the mass of each species leaving it through that face, slot(face, side, k) = A/2 sum_q w_q max(mdot_out, 0) Y_k(q), with Y_k from its own reconstruction (the evaluator Eval, see ScalarFaceValues); boundary faces also get the inflow from the exterior state in slot(face, 1, k). No two threads write the same slot. More...

#include <mixture_flux.h>

Public Member Functions

KOKKOS_INLINE_FUNCTION uint8_t n_quad () const
 
KOKKOS_INLINE_FUNCTION void exterior_Y (const uint32_t f, const uint32_t k, const rtype *interior, rtype *out) const
 Mass fraction k beyond boundary face f (local face k_face of cell c, whose own values there are interior) at each face point.
 
KOKKOS_INLINE_FUNCTION void linear (const uint32_t c) const
 Linear reconstruction (ScalarFaceValues, one point per face): the faces' offsets and weights are shared by all species and held in registers, the face loops unrolled.
 
KOKKOS_INLINE_FUNCTION void operator() (const uint32_t c) const
 

Public Attributes

Kokkos::View< uint32_t * > offsets_faces_of_cell
 
Kokkos::View< uint32_t * > faces_of_cell
 
Kokkos::View< int32_t *[2]> cells_of_face
 
Kokkos::View< rtype * > face_area
 
Kokkos::View< rtype * > quad_weights
 
Kokkos::View< rtype ** > face_weights
 
Kokkos::View< rtype ** > face_mdot
 
Eval values
 
BoundaryData boundaries
 
Kokkos::View< rtype ***, Kokkos::LayoutRight > slots
 
uint32_t n_species
 

Static Public Attributes

static constexpr uint8_t MAX_Q = teno::MAX_FACE_QUAD
 

Detailed Description

template<typename Eval>
struct SpeciesSlotFunctor< Eval >

Species fluxes by mass-flux upwinding (Larrouturou 1991), F_k = max(mdot, 0) Y_k^L + min(mdot, 0) Y_k^R, split by the side each part comes from: each cell writes, for each of its faces, the mass of each species leaving it through that face, slot(face, side, k) = A/2 sum_q w_q max(mdot_out, 0) Y_k(q), with Y_k from its own reconstruction (the evaluator Eval, see ScalarFaceValues); boundary faces also get the inflow from the exterior state in slot(face, 1, k). No two threads write the same slot.

With face mass fractions in [0, 1] summing to one, the species fluxes sum to the mass flux and keep rho Y_k non-negative under the flow's CFL limit.

Member Function Documentation

◆ exterior_Y()

template<typename Eval >
KOKKOS_INLINE_FUNCTION void SpeciesSlotFunctor< Eval >::exterior_Y ( const uint32_t  f,
const uint32_t  k,
const rtype *  interior,
rtype *  out 
) const
inline

Mass fraction k beyond boundary face f (local face k_face of cell c, whose own values there are interior) at each face point.

◆ linear()

template<typename Eval >
KOKKOS_INLINE_FUNCTION void SpeciesSlotFunctor< Eval >::linear ( const uint32_t  c) const
inline

Linear reconstruction (ScalarFaceValues, one point per face): the faces' offsets and weights are shared by all species and held in registers, the face loops unrolled.

◆ n_quad()

template<typename Eval >
KOKKOS_INLINE_FUNCTION uint8_t SpeciesSlotFunctor< Eval >::n_quad ( ) const
inline

◆ operator()()

Member Data Documentation

◆ boundaries

template<typename Eval >
BoundaryData SpeciesSlotFunctor< Eval >::boundaries

◆ cells_of_face

template<typename Eval >
Kokkos::View<int32_t *[2]> SpeciesSlotFunctor< Eval >::cells_of_face

◆ face_area

template<typename Eval >
Kokkos::View<rtype *> SpeciesSlotFunctor< Eval >::face_area

◆ face_mdot

template<typename Eval >
Kokkos::View<rtype **> SpeciesSlotFunctor< Eval >::face_mdot

◆ face_weights

template<typename Eval >
Kokkos::View<rtype **> SpeciesSlotFunctor< Eval >::face_weights

◆ faces_of_cell

template<typename Eval >
Kokkos::View<uint32_t *> SpeciesSlotFunctor< Eval >::faces_of_cell

◆ MAX_Q

template<typename Eval >
constexpr uint8_t SpeciesSlotFunctor< Eval >::MAX_Q = teno::MAX_FACE_QUAD
staticconstexpr

◆ n_species

template<typename Eval >
uint32_t SpeciesSlotFunctor< Eval >::n_species

◆ offsets_faces_of_cell

template<typename Eval >
Kokkos::View<uint32_t *> SpeciesSlotFunctor< Eval >::offsets_faces_of_cell

◆ quad_weights

template<typename Eval >
Kokkos::View<rtype *> SpeciesSlotFunctor< Eval >::quad_weights

◆ slots

template<typename Eval >
Kokkos::View<rtype ***, Kokkos::LayoutRight> SpeciesSlotFunctor< Eval >::slots

◆ values

template<typename Eval >
Eval SpeciesSlotFunctor< Eval >::values

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