Itasca C++ Interface
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages
igp.h
Go to the documentation of this file.
1 #pragma once
2 // igp.h
3 
9 // Gp Masks
10 //static const uint N_XFIX = 0x00000001; /* X Fix Flag */
11 //static const uint N_YFIX = 0x00000002; /* Y Fix Flag */
12 //static const uint N_ZFIX = 0x00000004; /* Z Fix Flag */
13 static const quint32 GF_RELAX = 0x00000008; // Relaxation condition flag
14 //static const quint32 GF_NULL = 0x00000010; // Defined as PRIVATE
15 static const quint32 GF_AVAIL = 0x00000020; // Available to user
16 static const quint32 GF_AVAIL2 = 0x00000040; // Available to user
17 static const quint32 GF_GEN1 = 0x00000080; // Gen Iterator Mask
18 static const quint32 GF_GEN2 = 0x00000100; // Gen Iterator Mask
19 static const quint32 GF_XQUIET = 0x00000200; // Quiet bound. flag
20 static const quint32 GF_YQUIET = 0x00000400; // Quiet bound. flag
21 static const quint32 GF_ZQUIET = 0x00000800; // Quiet bound. flag
22 //static const quint32 GF_TFIX = 0x00001000; // Thermal FIX flag
23 //static const quint32 GF_THNULL = 0x00002000; // Thermal NULL flag PRIVATE
24 //static const quint32 GF_FFIX = 0x00004000; // Fluid FIX flag
25 //static const quint32 GF_FLNULL = 0x00008000; // Fluid NULL flag PRIVATE
26 static const quint32 GF_NOEOM = 0x00010000; // Indiciates equations-of-motion are to be skipped
27 static const quint32 GF_TEMP = 0x00020000; // TEMPORARY FLAG - used internally
28 static const quint32 GF_FF1 = 0x00040000; // Gp in corner FF
29 static const quint32 GF_FF2 = 0x00080000; // Gp in side FF
30 static const quint32 GF_INTER = 0x00100000; // Indicates GP is a coincidentGp on a host interface node
31 static const quint32 GF_FDSCRG = 0x00200000; // Fluid discharge flag
32 static const quint32 GF_FLKG = 0x00400000; // Fluid leakage flag
33 static const quint32 GF_FPWELL = 0x00800000; // Fluid pwell flag
34 static const quint32 GF_LOCSMALL = 0x01000000; // Local small-strain Motion update
35 //static const quint32 GF_GHOST = 0x02000000; // DEFINED AS PRIVATE Used with MPI to deisgnate a slave gridpoint if in force/velocity mode
36 //static const quint32 GF_MECHLIVE = 0x04000000; // set if gp is connected to a live mech zone
37 //static const quint32 GF_FLUIDLIVE = 0x10000000; // set if gp is connected to a live fluid zone
38 //static const quint32 GF_THERMLIVE = 0x20000000; // set if gp is connected to a live therm zone
39 static const quint32 GF_WG = 0x40000000; // Westergaard condition flag
40 
41 
42 #include "module/interface/dim.h"
43 
44 namespace fish {
45  class File;
46 }
47 
48 namespace itasca {
49  class IThing;
50  class IFishParam;
51  class IFish;
52  class IGroup;
53 }
54 
55 namespace zone {
56  class INode;
57  class IFluidGp;
58  class IThermGp;
59  class IZone;
60  using itasca::IThing;
61 
64  class IGp {
65  public:
67  inline static const TType type_ = 0x4c815bed;
68  enum class Change { MechNull, FlNull, ThNull, AddToList, RemoveFromList };
70  virtual const IThing * getIThing() const=0;
72  virtual IThing * getIThing()=0;
74  virtual const INode * getINode() const=0;
75  virtual INode * getINode()=0;
78  virtual const IGp * getNext() const=0;
80  virtual bool isMechanicalNull() const=0;
82  virtual bool isThermalNull() const=0;
84  virtual bool isFluidNull() const=0;
86  virtual DVect getVelocity(bool local=false) const=0;
88  virtual void setVelocity(const DVect &v,bool local=false)=0;
90  virtual DVect getDisplacement(bool local=false) const=0;
92  virtual void setDisplacement(DVect v,bool local=false) =0;
94  virtual DVect getSmallDisplacement(bool local=false) const=0;
96  virtual void setSmallDisplacement(DVect v,bool local=false) =0;
98  virtual DVect getFobLast(bool local=false) const=0;
100  virtual DVect getFap(bool local=false) const=0;
105  virtual DVect getTotalForceLast(bool reaction=false,bool local=false) const=0;
106  virtual DVect getTotalForceCurrent(const DVect &gravity,bool reaction=false,bool local=false) const=0;
108  virtual DVect getPosition() const=0;
110  virtual void setPosition(const DVect &v) =0;
111 #ifdef THREED
112  virtual const IFluidGp * getIFluidGp() const=0;
115  virtual IFluidGp * getIFluidGp() =0;
117 #endif
118  virtual void copyState(const IGp *gp)=0;
120  virtual bool getLocSmall() const =0;
122  virtual void setLocSmall(bool b) =0;
124  virtual double getInertialMass() const=0;
126  virtual void setInertialMass(const double &d) =0;
128  virtual double getGravitationalMass() const=0;
130  virtual void setGravitationalMass(const double &d)=0;
132  virtual double getPP() const =0;
134  virtual void setPP(double d) =0;
136  virtual bool getPPFix() const = 0;
138  virtual void setPPFix(bool b) = 0;
139 #ifdef THREED
140  virtual double getSat() const=0;
143  virtual void setSat(const double &d) =0;
145  virtual const IThermGp * getIThermGp() const =0;
147  virtual IThermGp * getIThermGp() =0;
148 #endif
149  virtual bool getTFix() const =0;
152  virtual void setTFix(bool b) =0;
155  virtual IVect getFix() const =0;
158  virtual void setFix(IVect v) =0;
161  virtual DVect getFApplyUser(bool local=false) const=0;
164  virtual DVect getMassAdd(bool local=false) const=0;
166  virtual void setMassAdd(const DVect &v,bool local=false) =0;
167  virtual void setFApplyUser(const DVect &d,bool local=false) =0;
169  virtual bool getLocalSystem() const=0;
171  virtual Axes getSystem() const=0;
173  virtual void setSystem(const Axes &a) = 0;
176  virtual bool getBit(int bit) const=0;
181  virtual void setBit(int bit,bool b) const=0;
184  virtual QVariant getValue(int index) const=0;
188  virtual void setValue(int index,const QVariant &v) const=0;
201  virtual IZone * getLinkZone()=0;
202  virtual const IZone * getLinkZone() const=0;
203  virtual quint32 getLinkIndex() const=0;
210  virtual bool fishIO(bool save,fish::File *f)=0;
212  virtual double getStiff() const=0;
214  //virtual void setStiff(const double &d) =0;
215 #ifdef THREED
216  virtual double getTempChange() const=0;
219  virtual void setTempChange(const double &d)=0;
220 #endif
221  virtual double getConvergence() const=0;
222  virtual double getRatioTarget() const=0;
223  virtual void setRatioTarget(const double &d)=0;
224  virtual bool getAttached() const=0;
225  };
226 } // namespace zone
227 // EoF
virtual bool isFluidNull() const =0
Returns true to indicate that gridpoint fluid flag is set to NULL.
virtual IVect getFix() const =0
virtual DVect getDisplacement(bool local=false) const =0
Returns the gridpoint displacement, seet setDisplacement();.
virtual void setSystem(const Axes &a)=0
Sets the user-defined local axes.
virtual DVect getSmallDisplacement(bool local=false) const =0
Returns the gridpoint displacement accumulated for small strain, see setSmallDisplacement()
virtual bool isThermalNull() const =0
Returns true to indicate that gridpoint thermal flag is set to NULL.
virtual void setFix(IVect v)=0
virtual void setValue(int index, const QVariant &v) const =0
namespace Itasca
Definition: basememory.cpp:9
Base class for items that will be stored in containers.
Definition: ithing.h:31
DIM - Provides code portability between 2D and 3D codes.
Interface to access gridpoint thermal data.
Definition: ithermgp.h:12
virtual void setPPFix(bool b)=0
If parameter b is treu, sets the gridpoint pore-pressure to be kept fixed during calculation,...
virtual quint32 getLinkIndex() const =0
virtual DVect getTotalForceLast(bool reaction=false, bool local=false) const =0
virtual double getPP() const =0
Returns the gridpoint pore-pressure, see setPP()
virtual void setDisplacement(DVect v, bool local=false)=0
Sets the gridpoint displacement, seet getDisplacement();.
virtual double getConvergence() const =0
Sets the gridpoint stiffness.
virtual void setTFix(bool b)=0
If parameter is true, sets the thermal FIX flag on.
virtual QVariant getValue(int index) const =0
Class for specifying a particular 3D cartesian axes system, and converting to and from it.
Definition: axes.h:120
virtual void setBit(int bit, bool b) const =0
virtual Axes getSystem() const =0
Returns the user-defined local axes.
Interface to provide access to a zone.
Definition: izone.h:116
virtual void setVelocity(const DVect &v, bool local=false)=0
Sets the gridpoint velocity, see getVelocity();.
unsigned int TType
class type indicator
Definition: basedef.h:41
virtual void setMassAdd(const DVect &v, bool local=false)=0
Sets the additional applied mass at a gridpoint.
Interface to access node data.
Definition: inode.h:18
virtual bool isMechanicalNull() const =0
Returns true to indicate that gridpoint is "nulled".
virtual void setPP(double d)=0
Sets the gridpoint pore-pressure, see getPP()
virtual void setFApplyUser(const DVect &d, bool local=false)=0
using the APPLY command. See getFApplyUser()
virtual DVect getMassAdd(bool local=false) const =0
virtual void setSmallDisplacement(DVect v, bool local=false)=0
Sets the gridpoint displacement for small strain, see getSmallDisplacement()
virtual DVect getFobLast(bool local=false) const =0
Returns the gridpoint out of balance force.
Interface to access fluid gridpoint data.
Definition: ifluidgp.h:14
virtual void setLocSmall(bool b)=0
If parameter b is true, the gridpoint will behave as in small-strain mode. See getLocSmall();.
virtual const IGp * getNext() const =0
IVect3 IVect
Vector of ints, either 2D or 3D.
Definition: dim.h:147
virtual void setInertialMass(const double &d)=0
Sets the gridpoint inertial mass, see getInertialMass()
virtual double getGravitationalMass() const =0
Returns the gridpoint gravitational mass, see setGravitationalMass()
Interface to provide access to a gridpoint.
Definition: igp.h:64
virtual bool getTFix() const =0
Returns 1 if the gridpoint thermal FIX flag is set, otherwise value 0 indicates that the thermal fix ...
virtual double getInertialMass() const =0
Returns the gridpoint inertial mass, see setInertialMass()
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition: dim.h:145
virtual IZone * getLinkZone()=0
virtual DVect getPosition() const =0
Returns the gridpoint position, see setPosition()
virtual const IThing * getIThing() const =0
Returns a const IThing pointer.
virtual double getStiff() const =0
Returns the gridpoint stiffness.
virtual void setPosition(const DVect &v)=0
Sets the gridpoint position, see getPosition()
virtual DVect getVelocity(bool local=false) const =0
Returns the gridpoint velocity, see setVelocity();.
virtual bool getLocSmall() const =0
Returns 1 if gridpoint behaves as in small-strain mode. See setLocSmall();.
static const TType type_
The type identification number for this class, for use in convert_cast() and convert_getcast().
Definition: igp.h:67
virtual bool fishIO(bool save, fish::File *f)=0
virtual DVect getFap(bool local=false) const =0
Returns the sum of the gridpoint static applied force and the dynamic applied force.
virtual bool getPPFix() const =0
Returns 1 if the gridpoint has fixed pore-pressure, otherwise value 0 indicates non-fixed pore-pressu...
virtual const INode * getINode() const =0
Returns a pointer to itself.
virtual void setGravitationalMass(const double &d)=0
Sets the gridpoint gravitational mass, see getGravitationalMass()
virtual bool getBit(int bit) const =0
virtual DVect getFApplyUser(bool local=false) const =0