ESyS-Particle  2.3.2
RandomAssembly2D.h
Go to the documentation of this file.
1 
2 // //
3 // Copyright (c) 2003-2014 by The University of Queensland //
4 // Centre for Geoscience Computing //
5 // http://earth.uq.edu.au/centre-geoscience-computing //
6 // //
7 // Primary Business: Brisbane, Queensland, Australia //
8 // Licensed under the Open Software License version 3.0 //
9 // http://www.opensource.org/licenses/osl-3.0.php //
10 // //
12 
13 #ifndef __RANDOMASSEMBLY2D_H
14 #define __RANDOMASSEMBLY2D_H
15 
16 //-- project includes --
20 #include "Geometry/Sphere2d.h"
21 #include "Geometry/Line.h"
22 
23 //-- STL includes --
24 #include <vector>
25 
26 using std::vector;
27 
37 {
38  protected:
39  vector<Line> Borders;
40  double m_rmin,m_rmax;
42  bool m_circ_x;
43 
44 
45  virtual Vec3 getAPoint()=0;
46 
47  bool isInSpace(const Vec3&);
48  bool findAFit(SimpleParticle&, const vector<SimpleParticle>&, const Line&);
49  bool findAFit(SimpleParticle&, const vector<SimpleParticle>&);
50  virtual bool checkAFit(const SimpleParticle&);
51  virtual Line *getClosestPlane(const SimpleParticle&);
52  void fillSpace(int);
53  virtual int getNParts() const=0;
54 
55  public:
56  virtual void generate(int,unsigned int)=0;
57  virtual void insertParticle(const SimpleParticle)=0;
58  virtual void tagParticleClosestTo(const Vec3&,int)=0;
59  virtual void tagEdgeY(int,int,double)=0;
60 };
61 
62 #endif // __RANDOMASSEMBLY2D_H