21 #ifndef bempp_grid_hpp
22 #define bempp_grid_hpp
26 #include "../common/common.hpp"
27 #include "../common/shared_ptr.hpp"
28 #include "grid_parameters.hpp"
30 #include "../common/armadillo_fwd.hpp"
34 #include <tbb/mutex.h>
41 template<
int codim>
class Entity;
42 class GeometryFactory;
61 virtual int dim()
const = 0;
77 virtual std::auto_ptr<GridView>
levelView(
size_t level)
const = 0;
80 virtual std::auto_ptr<GridView>
leafView()
const = 0;
118 arma::Col<double>& upperBound)
const;
122 mutable arma::Col<double> m_lowerBound, m_upperBound;
145 std::vector<bool> areInside(
const Grid& grid,
const arma::Mat<double>& points);
146 std::vector<bool> areInside(
const Grid& grid,
const arma::Mat<float>& points);
virtual std::auto_ptr< GridView > levelView(size_t level) const =0
View of the entities on grid level level.
virtual const IdSet & globalIdSet() const =0
Reference to the grid's global id set.
virtual bool hasBarycentricGrid() const =0
Return true if a barycentric refinement of this grid has been created.
virtual int maxLevel() const =0
Maximum level defined in this grid.
Abstract wrapper of a grid.
Definition: grid.hpp:50
virtual std::auto_ptr< GridView > leafView() const =0
View of the leaf entities.
virtual std::auto_ptr< GeometryFactory > elementGeometryFactory() const =0
Factory able to construct empty geometries of codimension 0 compatible with this grid.
virtual int dimWorld() const =0
Dimension of the space containing the grid.
Abstract wrapper of an id set.
Definition: id_set.hpp:37
virtual GridParameters::Topology topology() const =0
Return the topology of the grid.
Topology
Grid topology
Definition: grid_parameters.hpp:33
virtual shared_ptr< Grid > barycentricGrid() const =0
Return a barycentrically refined grid based on the LeafView.
virtual int dim() const =0
Dimension of the grid.
virtual bool isBarycentricRepresentationOf(const Grid &other) const
Return true if this grid is a barycentric representation of other, i.e. if this grid was created by o...
Definition: grid.cpp:60
virtual ~Grid()
Destructor.
Definition: grid.hpp:54
void getBoundingBox(arma::Col< double > &lowerBound, arma::Col< double > &upperBound) const
Get bounding box.
Definition: grid.cpp:68