12 #ifndef EUCLIDEAN_STRONG_WITNESS_COMPLEX_H_
13 #define EUCLIDEAN_STRONG_WITNESS_COMPLEX_H_
15 #include <gudhi/Strong_witness_complex.h>
16 #include <gudhi/Active_witness/Active_witness.h>
17 #include <gudhi/Kd_tree_search.h>
19 #include <CGAL/version.h>
21 #include <Eigen/src/Core/util/Macros.h>
27 #if CGAL_VERSION_NR < 1041101000
28 # error Euclidean_strong_witness_complex is only available for CGAL >= 4.11
31 #if !EIGEN_VERSION_AT_LEAST(3,1,0)
32 # error Euclidean_strong_witness_complex is only available for Eigen3 >= 3.1.0 installed with CGAL
37 namespace witness_complex {
48 template<
class Kernel_ >
51 std::vector<typename Kernel_::Point_d>>::INS_range>> {
54 typedef typename K::Point_d Point_d;
55 typedef std::vector<Point_d> Point_range;
58 typedef typename std::vector<Nearest_landmark_range> Nearest_landmark_table;
60 typedef typename Nearest_landmark_range::Point_with_transformed_distance Id_distance_pair;
61 typedef typename Id_distance_pair::first_type Landmark_id;
62 typedef Landmark_id Vertex_handle;
65 Point_range landmarks_;
82 template<
typename LandmarkRange,
83 typename WitnessRange >
85 const WitnessRange & witnesses)
86 : landmarks_(std::begin(landmarks), std::end(landmarks)), landmark_tree_(landmarks_) {
87 nearest_landmark_table_.reserve(boost::size(witnesses));
88 for (
auto w : witnesses)
94 template <
typename Vertex_handle>
96 return landmarks_[vertex];
INS_range incremental_nearest_neighbors(Point const &p, FT eps=FT(0)) const
Search incrementally for the nearest neighbors from a query point.
Definition: Kd_tree_search.h:271
Incremental_neighbor_search INS_range
The range returned by an incremental nearest or furthest neighbor search. Its value type is std::pair...
Definition: Kd_tree_search.h:112
Constructs strong witness complex for given sets of witnesses and landmarks in Euclidean space.
Definition: Euclidean_strong_witness_complex.h:51
Euclidean_strong_witness_complex(const LandmarkRange &landmarks, const WitnessRange &witnesses)
Initializes member variables before constructing simplicial complex.
Definition: Euclidean_strong_witness_complex.h:84
Point_d get_point(Vertex_handle vertex) const
Returns the point corresponding to the given vertex.
Definition: Euclidean_strong_witness_complex.h:95
Constructs strong witness complex for a given table of nearest landmarks with respect to witnesses.
Definition: Strong_witness_complex.h:40
Gudhi namespace.
Definition: SimplicialComplexForAlpha.h:14