ESyS-Particle  2.3.2
BEdge2DInteraction.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 __BEDGE2DINTERACTION_H
14 #define __BEDGE2DINTERACTION_H
15 
16 // -- Project includes --
17 #include "Foundation/vec3.h"
18 #include "Geometry/Edge2D.h"
19 #include "Model/Particle.h"
20 #include "Model/BMesh2DIP.h"
22 
32 {
33  private:
36  double m_k;
37  double m_break;
38  double m_dist;
39  int m_eid;
40  int m_pid;
41 
42  Vec3 m_ap; // anchor point in local coord.
47  bool m_inner_flag;
48 
49  public:
52 
54  BEdge2DInteraction(CParticle*,Edge2D*,BMesh2DIP,bool iflag=true);
55  virtual ~BEdge2DInteraction();
56 
57  bool isInner(){return m_inner_flag;};
58  virtual void calcForces();
59  bool broken();
60  virtual Vec3 getPos()const {return m_p->getPos();}; // ??
61  inline int getPid() const {return m_pid;};
62  inline int getTid() const {return m_eid;};
63  Vec3 getAP() const;
64  virtual void setPP(CParticle* part_p){m_p=part_p;};
65  virtual void setTP(Edge2D* tri_p){m_ed=tri_p;};
66 
67  friend class TML_PackedMessageInterface;
68 };
69 #endif //__BEDGE2DINTERACTION_H