codac  1.5.7
codac_TubeTreeSynthesis.h
1 
11 #ifndef __CODAC_TUBETREESYNTHESIS_H__
12 #define __CODAC_TUBETREESYNTHESIS_H__
13 
14 #include "codac_Slice.h"
15 
16 namespace codac
17 {
18  class TubeTreeSynthesis
19  {
20  public:
21 
22  TubeTreeSynthesis(const Tube* tube, int k0, int kf, const std::vector<const Slice*>& v_tube_slices);
23  ~TubeTreeSynthesis();
24 
25  const Interval tdomain() const;
26  int nb_slices() const;
27  const Interval operator()(const Interval& t);
28  const Interval invert(const Interval& y, const Interval& search_tdomain);
29  const Interval codomain();
30  const std::pair<Interval,Interval> codomain_bounds();
31  const std::pair<Interval,Interval> eval(const Interval& t = Interval::ALL_REALS);
32 
33  int time_to_index(double t) const;
34  Slice* slice(int slice_id);
35  const Slice* slice(int slice_id) const;
36  Slice* slice(double t);
37  const Slice* slice(double t) const;
38 
39  bool is_leaf() const;
40  bool is_root() const;
41  TubeTreeSynthesis* root();
42 
43  void request_values_update();
44  void request_integrals_update(bool propagate_to_other_slices = true);
45  void update_values();
46  void update_integrals();
47  std::pair<Interval,Interval> partial_integral(const Interval& t);
48  const std::pair<Interval,Interval> partial_primitive_bounds(const Interval& t = Interval::ALL_REALS);
49 
50  protected:
51 
52  // Slices connections
53  const Slice *m_slice_ref = nullptr;
54  const Tube *m_tube_ref = nullptr;
55 
56  // Binary tree structure
57  TubeTreeSynthesis *m_parent = nullptr;
58  TubeTreeSynthesis *m_first_subtree = nullptr, *m_second_subtree = nullptr;
59 
60  int m_nb_slices = 1;
61  Interval m_tdomain, m_codomain;
62  std::pair<Interval,Interval> m_codomain_bounds;
63  std::pair<Interval,Interval> m_partial_primitive;
64 
65  bool m_integrals_update_needed = true;
66  bool m_values_update_needed = true;
67  };
68 }
69 
70 #endif
FixPoint of a separator The fixpoint of a separator is computed by calling the "::"separate function ...
Definition: codac_capd_helpers.h:9
const Trajectory root(const Trajectory &x, int p)