1 #ifndef ITERATOR_OVER_GEOMETRY_H 2 #define ITERATOR_OVER_GEOMETRY_H 5 #include "exceptions.hpp" 15 mutable size_t layer_;
16 STD_TR1::shared_ptr<const Rectangle> my_t;
17 std::unique_ptr<geometry_const_Iterator> down;
20 void step_down(
bool backward =
false);
21 bool increased_down();
22 bool decreased_down();
25 bool trycreateHI(
Matrix&)
const;
26 bool trycreateHIt(
Matrix&)
const;
30 static const size_t npos = 4294967295U;
46 void first_rect_slice();
47 void last_rect_slice();
52 Hamiltonian::const_ref get_H()
const;
53 STD_TR1::shared_ptr<const Rectangle> get_leaf_Rect()
const;
54 STD_TR1::shared_ptr<const Rectangle> get_lower_Rect()
const;
55 STD_TR1::shared_ptr<const Rectangle> get_top_Rect()
const;
61 size_t layer()
const {
return layer_;};
62 void set_layer(
size_t l)
const { layer_ = l;};
64 size_t nx(STD_TR1::shared_ptr<const Rectangle>)
const;
65 size_t ix(STD_TR1::shared_ptr<const Rectangle>)
const;
66 size_t block_number(
const STD_TR1::shared_ptr<const Rectangle>&)
const;
68 inline int ny()
const;
69 inline int ny_layer()
const;
70 inline point_Positions::ref rxy()
const;
74 inline double width()
const;
76 inline void createH0(
Matrix&)
const;
77 void createHI(
Matrix&)
const;
78 void createHIt(
Matrix&)
const;
80 void createH(
Matrix&,
size_t nx)
const;
88 mutable size_t layer_;
89 STD_TR1::shared_ptr<Rectangle> my_t;
90 std::unique_ptr<geometry_Iterator> down;
93 void step_down(
bool backward =
false);
94 bool increased_down();
95 bool decreased_down();
98 bool trycreateHI(
Matrix&)
const;
99 bool trycreateHIt(
Matrix&)
const;
103 static const size_t npos = 4294967295U;
107 bool at_end =
false);
115 void first_rect_slice();
116 void last_rect_slice();
124 Hamiltonian::ref get_H()
const;
125 STD_TR1::shared_ptr<Rectangle> get_leaf_Rect()
const;
126 STD_TR1::shared_ptr<Rectangle> get_lower_Rect()
const;
127 STD_TR1::shared_ptr<Rectangle> get_top_Rect()
const;
132 size_t layer()
const {
return layer_;};
133 void set_layer(
size_t l) { layer_ = l;};
135 size_t nx(STD_TR1::shared_ptr<const Rectangle>)
const;
136 size_t ix(STD_TR1::shared_ptr<const Rectangle>)
const;
137 size_t block_number(
const STD_TR1::shared_ptr<const Rectangle> &)
const;
139 inline int ny()
const;
140 inline int ny_layer()
const;
141 inline point_Positions::ref rxy()
const;
145 inline double width()
const;
147 inline void createH0(
Matrix&)
const;
148 void createHI(
Matrix&)
const;
149 void createHIt(
Matrix&)
const;
151 void createH(
Matrix&,
size_t nx)
const;
154 int geometry_const_Iterator::ny()
const{
return get_H()->ny(*
this);}
155 int geometry_const_Iterator::ny_layer()
const{
return get_H()->ny_layer(*
this);}
156 double geometry_const_Iterator::width()
const{
return get_H()->width(*
this);}
157 point_Positions::ref geometry_const_Iterator::rxy()
const{
return get_H()->rxy(*
this);}
158 void geometry_const_Iterator::createH0(
Matrix& m)
const {
return get_H()->create_H0(m,*
this);}
160 int geometry_Iterator::ny()
const{
return get_H()->ny(*
this);}
161 int geometry_Iterator::ny_layer()
const{
return get_H()->ny_layer(*
this);}
162 double geometry_Iterator::width()
const{
return get_H()->width(*
this);}
163 point_Positions::ref geometry_Iterator::rxy()
const{
return get_H()->rxy(*
this);}
164 void geometry_Iterator::createH0(
Matrix& m)
const {
return get_H()->create_H0(m,*
this);}
Definition: iterators.hpp:83
Definition: iterators.hpp:13
Abstract class that defines a geomeetry.
Definition: rectangle.hpp:31
Base Matrix class for access to 2D number grids.
Definition: matrix.hpp:82
Definitions of abstract Hamiltonian base class.