MyraMath
EliminationTree.h
Go to the documentation of this file.
1 // ========================================================================= //
2 // This file is part of MyraMath, copyright (c) 2014-2019 by Ryan A Chilton //
3 // and distributed by MyraCore, LLC. See LICENSE.txt for license terms. //
4 // ========================================================================= //
5 
6 #ifndef MYRAMATH_MULTIFRONTAL_SYMBOLIC_ELIMINATIONTREE_H
7 #define MYRAMATH_MULTIFRONTAL_SYMBOLIC_ELIMINATIONTREE_H
8 
14 #include <vector>
15 
16 #include <myramath/MYRAMATH_EXPORT.h>
17 
18 namespace myra {
19 
20 // Forward declarations.
21 class intCRange;
22 class PatternRange;
23 
25 class MYRAMATH_EXPORT EliminationTree
26  {
27  public:
28 
30  EliminationTree(const PatternRange& A);
31 
33  intCRange parents() const;
34 
36  intCRange postorder() const;
37  intCRange ipostorder() const;
38 
40  intCRange children(int n) const;
41 
43  int size() const;
44 
45  private:
46 
47  // Implementation detail of PatternRange constructor.
48  void constructor_all(const PatternRange& A);
49  void constructor_slice(const PatternRange& A);
50  void constructor_path(int i, int j, std::vector<int>& ancestor);
51 
52  // After parent[] table has been computed, this method fills everything else.
53  void constructor_finish();
54 
55  // Internal contents.
56  int N;
57  std::vector<int> parent;
58  std::vector<int> children_data;
59  std::vector<int> children_stride;
60  std::vector<int> post;
61  std::vector<int> ipost;
62 
63  };
64 
65 } // namespace myra
66 
67 #endif
Given a Pattern A, models propagation of fill-in for A=LL&#39;.
Definition: EliminationTree.h:25
Definition: syntax.dox:1
Represents an immutable view of a Pattern.
Definition: PatternRange.h:31
Represents a const intRange.
Definition: intRange.h:142