1#ifndef AMREX_EB2_MULTIGFAB_H_
2#define AMREX_EB2_MULTIGFAB_H_
3#include <AMReX_Config.H>
26 static constexpr int ng = 2;
35 for (
int idim = 0; idim < AMREX_SPACEDIM; ++idim) {
37#if (AMREX_SPACEDIM == 3)
55#if (AMREX_SPACEDIM == 3)
77#if (AMREX_SPACEDIM == 3)
102 const Box& bx = mfi.validbox();
103 auto& gfab = (*this)[mfi];
A FortranArrayBox(FAB)-like object.
Definition AMReX_BaseFab.H:190
void resize(const Box &b, int N=1, Arena *ar=nullptr)
This function resizes a BaseFab so it covers the Box b with N components.
Definition AMReX_BaseFab.H:1629
A collection of Boxes stored in an Array.
Definition AMReX_BoxArray.H:568
Calculates the distribution of FABs to MPI processes.
Definition AMReX_DistributionMapping.H:43
Object that stores level-set, face/edge types, and EB graph per box.
Definition AMReX_EB2_MultiGFab.H:21
Box validbox() const
Valid box covered by this GFab.
Definition AMReX_EB2_MultiGFab.H:45
Graph & getGraph()
Definition AMReX_EB2_MultiGFab.H:63
const Graph & getGraph() const
Accessor for the EB graph structure stored within this tile.
Definition AMReX_EB2_MultiGFab.H:62
const BaseFab< Real > & getLevelSet() const
Access the nodal level-set field (const and mutable).
Definition AMReX_EB2_MultiGFab.H:48
const Array< BaseFab< Type_t >, 3 > & getFaceType() const
Access face-type classification arrays.
Definition AMReX_EB2_MultiGFab.H:52
const Array< BaseFab< Type_t >, 3 > & getEdgeType() const
Access edge-type arrays (3-D only).
Definition AMReX_EB2_MultiGFab.H:57
BaseFab< Real > & getLevelSet()
Definition AMReX_EB2_MultiGFab.H:49
Array< BaseFab< Type_t >, 3 > & getEdgeType()
Definition AMReX_EB2_MultiGFab.H:58
void buildTypes(EBCellFlagFab &celltype)
Derive face/edge types from the supplied EB cell flags.
Definition AMReX_EB2_MultiGFab.cpp:8
Array< BaseFab< Type_t >, 3 > & getFaceType()
Definition AMReX_EB2_MultiGFab.H:53
void define(const Box &vbx)
Allocate level-set and type arrays for valid box vbx.
Definition AMReX_EB2_MultiGFab.H:31
static constexpr int ng
Definition AMReX_EB2_MultiGFab.H:26
LayoutData wrapper that allocates a GFab per FAB/Box.
Definition AMReX_EB2_MultiGFab.H:86
void define(const BoxArray &ba, const DistributionMapping &dm)
Define the layout and allocate per-box GFab storage.
Definition AMReX_EB2_MultiGFab.H:99
MultiGFab(const BoxArray &ba, const DistributionMapping &dm)
Construct and define the layout immediately.
Definition AMReX_EB2_MultiGFab.H:92
MultiFab getLevelSet()
Collect the level-set data from each GFab into a MultiFab.
Definition AMReX_EB2_MultiGFab.cpp:41
FAB storing EBCellFlag data per cell.
Definition AMReX_EBCellFlag.H:324
__host__ static __device__ constexpr IntVectND< dim > TheNodeVector() noexcept
This static member function returns a reference to a constant IntVectND object, all of whose dim argu...
Definition AMReX_IntVect.H:801
__host__ static __device__ constexpr IntVectND< dim > TheDimensionVector(int d) noexcept
This static member function returns a reference to a constant IntVectND object, all of whose dim argu...
Definition AMReX_IntVect.H:790
a one-thingy-per-box distributed object
Definition AMReX_LayoutData.H:13
void define(const BoxArray &a_grids, const DistributionMapping &a_dm)
Definition AMReX_LayoutData.H:25
Iterator for looping ever tiles and boxes of amrex::FabArray based containers.
Definition AMReX_MFIter.H:88
bool isValid() const noexcept
Is the iterator valid i.e. is it associated with a FAB?
Definition AMReX_MFIter.H:172
A collection (stored as an array) of FArrayBox objects.
Definition AMReX_MultiFab.H:40
__host__ __device__ BoxND< dim > grow(const BoxND< dim > &b, int i) noexcept
Grow BoxND in all directions by given amount.
Definition AMReX_Box.H:1280
std::array< T, N > Array
Definition AMReX_Array.H:26
Definition AMReX_FabArrayBase.H:33
std::unordered_map< IntVect, Vector< Vertex >, IntVect::hasher > Graph
EB graph type: map from cell index to all EB vertices stored there.
Definition AMReX_EB2_Graph.H:105
__host__ __device__ BoxND< dim > convert(const BoxND< dim > &b, const IntVectND< dim > &typ) noexcept
Return a BoxND with different type.
Definition AMReX_Box.H:1558
__host__ __device__ BoxND< dim > surroundingNodes(const BoxND< dim > &b, int dir) noexcept
Return a BoxND with NODE based coordinates in direction dir that encloses BoxND b....
Definition AMReX_Box.H:1522