Class documentation of Concepts

Loading...
Searching...
No Matches
hexsubdiv.hh
Go to the documentation of this file.
1
7#ifndef hexsubdiv_hh
8#define hexsubdiv_hh
9
10#include <iostream>
11#include "strategyChange.hh"
12#include "subdivision.hh"
13
14namespace concepts {
15
16 // forward declaration
17 class Hexahedron;
18 class Z2;
19 class Z4;
20 class Quad;
21 class Vertex;
22
23 // ******************************************************** HexSubdivision **
24
40 class HexSubdivision : public Subdivision {
41 public:
44 virtual void createChildren(Hexahedron& q) const = 0;
48 virtual void removeChildren(Hexahedron& q) const = 0;
49 protected:
51
67 void subFace0011(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B) const;
68 void subFace1100(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B) const;
69 void subFace0110(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B) const;
70 void subFace1001(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B) const;
72
73
89 void subFace0123(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B,
90 Quad*& C, Quad*& D) const;
91 void subFace1230(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B,
92 Quad*& C, Quad*& D) const;
93 void subFace2301(Quad& q, Z2 rho, Z4 tau, Quad*& A, Quad*& B,
94 Quad*& C, Quad*& D) const;
96
110 bool faceSubdiv4(Quad& q) const;
111
127 Quad* findFace(const Vertex* const v, Quad* const q[4],
128 const unsigned int tau, const unsigned int rho, const unsigned int vtxIdx) const;
130
143 Quad*& C, Quad*& D, bool normal) const;
144 void subdivFace1(Hexahedron& h, Quad*& A, Quad*& B,
145 Quad*& C, Quad*& D, bool normal) const;
146 void subdivFace2(Hexahedron& h, Quad*& A, Quad*& B,
147 Quad*& C, Quad*& D, bool normal) const;
148 void subdivFace3(Hexahedron& h, Quad*& A, Quad*& B,
149 Quad*& C, Quad*& D, bool normal) const;
150 void subdivFace4(Hexahedron& h, Quad*& A, Quad*& B,
151 Quad*& C, Quad*& D, bool normal) const;
152 void subdivFace5(Hexahedron& h, Quad*& A, Quad*& B,
153 Quad*& C, Quad*& D, bool normal) const;
155 };
156
157 // ************************************************************ HexSubdiv8 **
158
167 class HexSubdiv8 : public HexSubdivision {
168 public:
169 virtual void createChildren(Hexahedron& q) const;
170 virtual void removeChildren(Hexahedron& q) const;
171 static const HexSubdiv8* instance();
172 virtual ~HexSubdiv8();
173 protected:
174 virtual std::ostream& info(std::ostream& os) const;
175 private:
176 static std::unique_ptr<HexSubdiv8> instance_;
177 };
178
179 // *********************************************************** HexSubdiv2x **
180
190 public:
191 virtual void createChildren(Hexahedron& q) const;
192 virtual void removeChildren(Hexahedron& q) const;
193 static const HexSubdiv2x* instance();
194 virtual ~HexSubdiv2x();
195 protected:
196 virtual std::ostream& info(std::ostream& os) const;
197 private:
198 static std::unique_ptr<HexSubdiv2x> instance_;
199 };
200
201 // *********************************************************** HexSubdiv2y **
202
212 public:
213 virtual void createChildren(Hexahedron& q) const;
214 virtual void removeChildren(Hexahedron& q) const;
215 static const HexSubdiv2y* instance();
216 virtual ~HexSubdiv2y();
217 protected:
218 virtual std::ostream& info(std::ostream& os) const;
219 private:
220 static std::unique_ptr<HexSubdiv2y> instance_;
221 };
222
223 // *********************************************************** HexSubdiv2z **
224
234 public:
235 virtual void createChildren(Hexahedron& q) const;
236 virtual void removeChildren(Hexahedron& q) const;
237 static const HexSubdiv2z* instance();
238 virtual ~HexSubdiv2z();
239 protected:
240 virtual std::ostream& info(std::ostream& os) const;
241 private:
242 static std::unique_ptr<HexSubdiv2z> instance_;
243 };
244
245 // *********************************************************** HexSubdiv4x **
246
256 public:
257 virtual void createChildren(Hexahedron& q) const;
258 virtual void removeChildren(Hexahedron& q) const;
259 static const HexSubdiv4x* instance();
260 virtual ~HexSubdiv4x();
261 protected:
262 virtual std::ostream& info(std::ostream& os) const;
263 private:
264 static std::unique_ptr<HexSubdiv4x> instance_;
265 };
266
267 // *********************************************************** HexSubdiv4y **
268
278 public:
279 virtual void createChildren(Hexahedron& q) const;
280 virtual void removeChildren(Hexahedron& q) const;
281 static const HexSubdiv4y* instance();
282 virtual ~HexSubdiv4y();
283 protected:
284 virtual std::ostream& info(std::ostream& os) const;
285 private:
286 static std::unique_ptr<HexSubdiv4y> instance_;
287 };
288
289 // *********************************************************** HexSubdiv4z **
290
300 public:
301 virtual void createChildren(Hexahedron& q) const;
302 virtual void removeChildren(Hexahedron& q) const;
303 static const HexSubdiv4z* instance();
304 virtual ~HexSubdiv4z();
305 protected:
306 virtual std::ostream& info(std::ostream& os) const;
307 private:
308 static std::unique_ptr<HexSubdiv4z> instance_;
309 };
310
311} // namespace concepts
312
313#endif // hexsubdiv_hh
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void createChildren(Hexahedron &q) const
virtual void removeChildren(Hexahedron &q) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void createChildren(Hexahedron &q) const
virtual void removeChildren(Hexahedron &q) const
virtual void removeChildren(Hexahedron &q) const
virtual void createChildren(Hexahedron &q) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void createChildren(Hexahedron &q) const
virtual void removeChildren(Hexahedron &q) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void removeChildren(Hexahedron &q) const
virtual void createChildren(Hexahedron &q) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void createChildren(Hexahedron &q) const
virtual void removeChildren(Hexahedron &q) const
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
virtual void removeChildren(Hexahedron &q) const
virtual void createChildren(Hexahedron &q) const
virtual void createChildren(Hexahedron &q) const =0
void subdivFace0(Hexahedron &h, Quad *&A, Quad *&B, Quad *&C, Quad *&D, bool normal) const
void subFace0011(Quad &q, Z2 rho, Z4 tau, Quad *&A, Quad *&B) const
void subFace0123(Quad &q, Z2 rho, Z4 tau, Quad *&A, Quad *&B, Quad *&C, Quad *&D) const
virtual void removeChildren(Hexahedron &q) const =0
Quad * findFace(const Vertex *const v, Quad *const q[4], const unsigned int tau, const unsigned int rho, const unsigned int vtxIdx) const
bool faceSubdiv4(Quad &q) const
Set< F > makeSet(uint n, const F &first,...)
Definition set.hh:320