Strong_witness_complex_interface.h
1 /* This file is part of the Gudhi Library - https://gudhi.inria.fr/ - which is released under MIT.
2  * See file LICENSE or go to https://gudhi.inria.fr/licensing/ for full license details.
3  * Author(s): Vincent Rouvreau
4  *
5  * Copyright (C) 2016 Inria
6  *
7  * Modification(s):
8  * - YYYY/MM Author: Description of the modification
9  */
10 
11 #ifndef INCLUDE_STRONG_WITNESS_COMPLEX_INTERFACE_H_
12 #define INCLUDE_STRONG_WITNESS_COMPLEX_INTERFACE_H_
13 
14 #include <gudhi/Simplex_tree.h>
15 #include <gudhi/Strong_witness_complex.h>
16 
17 #include "Simplex_tree_interface.h"
18 
19 #include <vector>
20 #include <utility> // std::pair
21 #include <iostream>
22 #include <cstddef>
23 
24 namespace Gudhi {
25 
26 namespace witness_complex {
27 
28 class Strong_witness_complex_interface {
29  using Nearest_landmark_range = std::vector<std::pair<std::size_t, double>>;
30  using Nearest_landmark_table = std::vector<Nearest_landmark_range>;
31 
32  public:
33  Strong_witness_complex_interface(const Nearest_landmark_table& nlt) {
34  witness_complex_ = new Strong_witness_complex<Nearest_landmark_table>(nlt);
35  }
36 
37  ~Strong_witness_complex_interface() {
38  delete witness_complex_;
39  }
40 
41  void create_simplex_tree(Simplex_tree_interface<>* simplex_tree, double max_alpha_square,
42  std::size_t limit_dimension) {
43  witness_complex_->create_complex(*simplex_tree, max_alpha_square, limit_dimension);
44  }
45 
46  void create_simplex_tree(Simplex_tree_interface<>* simplex_tree,
47  double max_alpha_square) {
48  witness_complex_->create_complex(*simplex_tree, max_alpha_square);
49  }
50 
51  private:
53 };
54 
55 } // namespace witness_complex
56 
57 } // namespace Gudhi
58 
59 #endif // INCLUDE_STRONG_WITNESS_COMPLEX_INTERFACE_H_
Constructs strong witness complex for given sets of witnesses and landmarks in Euclidean space.
Definition: Euclidean_strong_witness_complex.h:51
GUDHIdev  Version 3.5.0  - C++ library for Topological Data Analysis (TDA) and Higher Dimensional Geometry Understanding.  - Copyright : MIT Generated on Fri Jan 14 2022 18:28:42 for GUDHIdev by Doxygen 1.9.1