18#ifdef DEAL_II_WITH_ARBORX
25 template <
int dim,
typename Number>
29 static_assert(dim != 1,
"dim equal to one is not supported.");
31 const unsigned int size = dim_points.size();
33 for (
unsigned int i = 0; i <
size; ++i)
35 points.emplace_back(
static_cast<float>(dim_points[i][0]),
36 static_cast<float>(dim_points[i][1]),
38 static_cast<float>(dim_points[i][2]));
52 const ::Point<3, float> &
60 template <
int dim,
typename Number>
68 template <
int dim,
typename Number>
71 const unsigned int n_nearest_neighbors)
73 , n_nearest_neighbors(n_nearest_neighbors)
85 template <
int dim,
typename Number>
89 const unsigned int size = bb.size();
93 for (
unsigned int i = 0; i <
size; ++i)
95 auto boundary_points = bb[i].get_boundary_points();
98 for (
int d = 0;
d < dim; ++
d)
100 min_corner_arborx[
d] =
static_cast<float>(min_corner[
d]);
101 max_corner_arborx[
d] =
static_cast<float>(max_corner[
d]);
104 std::make_pair(min_corner_arborx, max_corner_arborx));
118 const ::BoundingBox<3, float> &
126 template <
int dim,
typename Number>
134 template <
int dim,
typename Number>
137 const unsigned int n_nearest_neighbors)
139 , n_nearest_neighbors(n_nearest_neighbors)
156 template <
int dim,
typename Number>
158 AccessTraits<std::vector<::Point<dim, Number>>, PrimitivesTag>::size(
166 template <
int dim,
typename Number>
168 AccessTraits<std::vector<::Point<dim, Number>>, PrimitivesTag>::get(
174 return {{
static_cast<float>(v[i][0]),
175 static_cast<float>(v[i][1]),
176 dim == 2 ? 0 :
static_cast<float>(v[i][2])}};
182 template <
int dim,
typename Number>
184 AccessTraits<std::vector<::BoundingBox<dim, Number>>, PrimitivesTag>::
192 template <
int dim,
typename Number>
194 AccessTraits<std::vector<::BoundingBox<dim, Number>>, PrimitivesTag>::
197 const auto boundary_points = v[i].get_boundary_points();
198 const ::Point<dim, Number> min_corner = boundary_points.first;
199 const ::Point<dim, Number> max_corner = boundary_points.second;
202 return {{
static_cast<float>(min_corner[0]),
203 static_cast<float>(min_corner[1]),
204 dim == 2 ? 0.f :
static_cast<float>(min_corner[2])},
205 {
static_cast<float>(max_corner[0]),
206 static_cast<float>(max_corner[1]),
207 dim == 2 ? 0.f :
static_cast<float>(max_corner[2])}};
212# include "access_traits.inst"
BoundingBoxIntersectPredicate(const std::vector<::BoundingBox< dim, Number > > &bounding_boxes)
unsigned int n_nearest_neighbors
BoundingBoxNearestPredicate(const std::vector<::BoundingBox< dim, Number > > &bounding_boxes, const unsigned int n_nearest_neighbors)
unsigned int get_n_nearest_neighbors() const
BoundingBoxPredicate(const std::vector<::BoundingBox< dim, Number > > &bounding_boxes)
std::vector<::BoundingBox< 3, float > > bounding_boxes
const ::BoundingBox< 3, float > & get(unsigned int i) const
PointIntersectPredicate(const std::vector<::Point< dim, Number > > &points)
unsigned int n_nearest_neighbors
unsigned int get_n_nearest_neighbors() const
PointNearestPredicate(const std::vector<::Point< dim, Number > > &points, const unsigned int n_nearest_neighbors)
std::vector<::Point< 3, float > > points
PointPredicate(const std::vector<::Point< dim, Number > > &points)
const ::Point< 3, float > & get(unsigned int i) const
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
SymmetricTensor< 2, dim, Number > d(const Tensor< 2, dim, Number > &F, const Tensor< 2, dim, Number > &dF_dt)