41 #ifndef DTK_BOXGEOMETRY_HPP 42 #define DTK_BOXGEOMETRY_HPP 46 #include <Teuchos_ArrayView.hpp> 47 #include <Teuchos_Tuple.hpp> 71 const int block_id,
const double x_min,
const double y_min,
72 const double z_min,
const double x_max,
const double y_max,
77 const int block_id,
const Teuchos::Tuple<double, 6> &bounds );
99 double measure()
const override;
107 const Teuchos::ArrayView<const double> &point,
108 const Teuchos::ArrayView<double> &reference_point )
const override;
113 const Teuchos::ArrayView<const double>
114 &reference_point )
const override;
118 const Teuchos::ArrayView<const double> &reference_point,
119 const Teuchos::ArrayView<double> &point )
const override;
138 #endif // end DTK_BOXGEOMETRY_HPP ~BoxGeometry()
Destructor.
static void uniteBoxes(const BoxGeometry &box_A, const BoxGeometry &box_B, BoxGeometry &box_union)
Static function for box union.
bool checkPointInclusion(const double tolerance, const Teuchos::ArrayView< const double > &reference_point) const override
Determine if a reference point is in the parameterized space of an entity.
BoxGeometry operator+(const BoxGeometry &box_1, const BoxGeometry &box_2)
Addition operator. Adding two boxes together is the same as computing their union.
void centroid(const Teuchos::ArrayView< double > ¢roid) const override
Get the centroid of the box.
BasicGeometryEntity declaration.
Axis-aligned Cartesian box container.
std::ostream & operator<<(std::ostream &os, const DataTransferKit::BoxGeometry &b)
Print the box description to an ostream.
static bool checkForIntersection(const BoxGeometry &box_A, const BoxGeometry &box_B)
Static function for box intersection test.
BasicGeometryEntity interface.
BoxGeometry()
Default constructor.
unsigned long int EntityId
Entity id type.
BoxGeometry & operator+=(const BoxGeometry &rhs)
Compound assignment overload.
bool mapToReferenceFrame(const Teuchos::ArrayView< const double > &point, const Teuchos::ArrayView< double > &reference_point) const override
Map a point to the reference space of an entity. Return the.
void mapToPhysicalFrame(const Teuchos::ArrayView< const double > &reference_point, const Teuchos::ArrayView< double > &point) const override
Map a reference point to the physical space of an entity.
static bool intersectBoxes(const BoxGeometry &box_A, const BoxGeometry &box_B, BoxGeometry &box_intersection)
Static function for box intersection. Return false if they do not intersect.
double measure() const override
Compute the measure of the box.