52#ifndef MFEM_BB_GRID_MAP
53#define MFEM_BB_GRID_MAP
108 Vector lmap_bnd_min, lmap_bnd_max;
111 unsigned int lmap_nxd;
131 bool by_max_size=
false);
148 int nel,
int sdim,
int n,
bool by_max_size=
false);
187 int &imin,
int &imax);
Map a point in physical space to candidate elements of a curved mesh.
const Array< int > & GetGridN() const
Return the grid resolution (number of cells) in each direction.
Array< int > GridCellToElements(int i) const
Get list of elements corresponding to a grid cell.
static void GetGridRange(const int d, const Array< int > &lh_n, const Vector &lh_fac, const Vector &lh_bnd_min, const real_t &xmin, const real_t &xmax, int &imin, int &imax)
Get local (1D) indices for cells of tensor grid that intersect with the given bounding box.
int GetGridCellFromPoint(Vector &xyz) const
Get grid cell index for a given point.
BBoxTensorGridMap(Mesh &mesh, int nx)
Constructor for a given mesh and resolution of Cartesian grid.
const Vector & GetGridMax() const
Return the maximum extent of the grid in each direction.
const Vector & GetGridFac() const
Return the number of grid cells per unit extent in each direction.
static void SetGridFac(Vector &lh_fac, const Array< int > &nx, const Vector &lh_bnd_min, const Vector &lh_bnd_max)
Set grid fac - number of grid cells per unit grid extent.
const Vector & GetGridMin() const
Return the minimum extent of the grid in each direction.
static int GetGridCountAndRange(const Array< int > &lh_n, const Vector &lh_fac, const Vector &lh_bnd_min, const Vector &lh_bnd_max, const Vector &elmin, const Vector &elmax, Array< int > &elmin_h, Array< int > &elmax_h)
Get grid count and range - total number of grid cells that intersect with all elements of the mesh an...
const Array< unsigned int > & GetGridMap() const
Array< int > MapPointToElements(Vector &xyz) const
Map a point to possible overlapping elements.