Itasca C++ Interface
igp.h
Go to the documentation of this file.
1 #pragma once
2 // igp.h
3 
9 // Gp Masks
10 //static const uint32 N_XFIX = 0x00000001; /* X Fix Flag */
11 //static const uint32 N_YFIX = 0x00000002; /* Y Fix Flag */
12 //static const uint32 N_ZFIX = 0x00000004; /* Z Fix Flag */
13 //static const uint32 N_MULT = 0x00000008; /* Multiplier manually set flag */
14 static const uint32 GF_AVAIL = 0x00000020; // Available to user
15 static const uint32 GF_AVAIL2 = 0x00000040; // Available to user
16 static const uint32 GF_GEN1 = 0x00000080; // Gen Iterator Mask
17 static const uint32 GF_GEN2 = 0x00000100; // Gen Iterator Mask
18 static const uint32 GF_XQUIET = 0x00000200; // Quiet bound. flag
19 static const uint32 GF_YQUIET = 0x00000400; // Quiet bound. flag
20 static const uint32 GF_ZQUIET = 0x00000800; // Quiet bound. flag
21 static const uint32 GF_NOEOM = 0x00010000; // Indiciates equations-of-motion are to be skipped
22 static const uint32 GF_TEMP = 0x00020000; // TEMPORARY FLAG - used internally
23 static const uint32 GF_FF1 = 0x00040000; // Gp in corner FF
24 static const uint32 GF_FF2 = 0x00080000; // Gp in side FF
25 static const uint32 GF_INTER = 0x00100000; // Indicates GP is a coincidentGp on a host interface node
26 static const uint32 GF_FDSCRG = 0x00200000; // Fluid discharge flag
27 static const uint32 GF_FLKG = 0x00400000; // Fluid leakage flag
28 static const uint32 GF_FPWELL = 0x00800000; // Fluid pwell flag
29 static const uint32 GF_LOCSMALL = 0x01000000; // Local small-strain Motion update
30 static const uint32 GF_WG = 0x40000000; // Westergaard condition flag
31 static const uint32 GF_NOSOLVE = 0x80000000; // Solve limit flag
32 
33 
34 #include "module/interface/dim.h"
35 
36 namespace fish {
37  class File;
38 }
39 
40 namespace itasca {
41  class IThing;
42  class IFishParam;
43  class IFish;
44  class IGroup;
45 }
46 
47 namespace zone {
48  class INode;
49  class IFluidGp;
50  class IThermGp;
51  class IZone;
52  using itasca::IThing;
53 
56  class IGp {
57  public:
59  inline static const TType type_ = 0x4c815bed;
60  enum class Change { MechNull, FlNull, ThNull, AddToList, RemoveFromList };
62  virtual const IThing * getIThing() const=0;
64  virtual IThing * getIThing()=0;
66  virtual const INode * getINode() const=0;
67  virtual INode * getINode()=0;
70  virtual const IGp * getNext() const=0;
72  virtual bool isMechanicalNull() const=0;
74  virtual bool isThermalNull() const=0;
76  virtual bool isFluidNull() const=0;
78  virtual DVect getVelocity(bool local=false) const=0;
80  virtual void setVelocity(const DVect &v,bool local=false)=0;
82  virtual DVect getDisplacement(bool local=false) const=0;
84  virtual void setDisplacement(DVect v,bool local=false) =0;
86  virtual DVect getSmallDisplacement(bool local=false) const=0;
88  virtual void setSmallDisplacement(DVect v,bool local=false) =0;
90  virtual DVect getFobLast(bool local=false) const=0;
92  virtual DVect getFap(bool local=false) const=0;
97  virtual DVect getTotalForceLast(bool reaction=false,bool local=false) const=0;
98  virtual DVect getTotalForceCurrent(const DVect &gravity,bool reaction=false,bool local=false) const=0;
100  virtual DVect getPosition() const=0;
102  virtual void setPosition(const DVect &v) =0;
104  virtual const IFluidGp * getIFluidGp() const=0;
106  virtual IFluidGp * getIFluidGp() =0;
108  virtual void copyState(const IGp *gp)=0;
110  virtual bool getLocSmall() const =0;
112  virtual void setLocSmall(bool b) =0;
114  virtual double getInertialMass() const=0;
116  virtual double getGravitationalMass() const=0;
118  virtual void setGravitationalMass(const double &d)=0;
120  virtual double getPP() const =0;
122  virtual void setPP(double d) =0;
124  virtual bool getPPFix() const = 0;
126  virtual void setPPFix(bool b) = 0;
128  virtual double getSat() const=0;
130  virtual void setSat(const double &d) =0;
132  virtual const IThermGp * getIThermGp() const =0;
134  virtual IThermGp * getIThermGp() =0;
136  virtual bool getTFix() const =0;
138  virtual void setTFix(bool b) =0;
141  virtual IVect getFix() const =0;
144  virtual void setFix(IVect v) =0;
147  virtual DVect getFApplyUser(bool local=false) const=0;
150  virtual DVect getMassAdd(bool local=false) const=0;
152  virtual void setMassAdd(const DVect &v,bool local=false) =0;
154  virtual void setFApplyUser(const DVect &d,bool local=false) =0;
155  virtual bool getLocalSystem() const=0;
157  virtual Axes getSystem() const=0;
159  virtual void setSystem(const Axes &a) = 0;
162  virtual bool getBit(int bit) const=0;
167  virtual void setBit(int bit,bool b) const=0;
170  virtual QVariant getValue(int index) const=0;
174  virtual void setValue(int index,const QVariant &v) const=0;
187  virtual IZone * getLinkZone()=0;
188  virtual const IZone * getLinkZone() const=0;
191  virtual uint32 getLinkIndex() const=0;
196  virtual bool fishIO(bool save,fish::File *f)=0;
198  virtual double getStiff() const=0;
200  //virtual void setStiff(const double &d) =0;
202  virtual double getTempChange() const=0;
204  virtual void setTempChange(const double &d)=0;
205  virtual double getConvergence() const=0;
206  virtual double getRatioTarget() const=0;
207  virtual void setRatioTarget(const double &d)=0;
208  virtual bool getAttached() const=0;
209  };
210 } // namespace zone
211 // EoF
Class for specifying a particular 3D cartesian axes system, and converting to and from it.
Definition: axes.h:121
Base class for items that will be stored in containers.
Definition: ithing.h:30
Interface to access fluid gridpoint data.
Definition: ifluidgp.h:14
Interface to provide access to a gridpoint.
Definition: igp.h:56
virtual QVariant getValue(int index) const =0
virtual IFluidGp * getIFluidGp()=0
Returns a pointer to the gridpoint fluid-flow data.
virtual void setBit(int bit, bool b) const =0
virtual IVect getFix() const =0
virtual bool getBit(int bit) const =0
virtual void setTFix(bool b)=0
If parameter is true, sets the thermal FIX flag on.
virtual bool getTFix() const =0
Returns 1 if the gridpoint thermal FIX flag is set, otherwise value 0 indicates that the thermal fix ...
virtual const INode * getINode() const =0
Returns a pointer to itself.
virtual void setMassAdd(const DVect &v, bool local=false)=0
Sets the additional applied mass at a gridpoint.
virtual double getPP() const =0
Returns the gridpoint pore-pressure, see setPP()
virtual void setPosition(const DVect &v)=0
Sets the gridpoint position, see getPosition()
virtual void setVelocity(const DVect &v, bool local=false)=0
Sets the gridpoint velocity, see getVelocity();.
virtual void setSat(const double &d)=0
Sets the gridpoint fluid saturation, see getSat()
virtual void setGravitationalMass(const double &d)=0
Sets the gridpoint gravitational mass, see getGravitationalMass()
virtual const IZone * getLinkZone() const =0
virtual double getTempChange() const =0
Sets the gridpoint stiffness.
virtual void setSmallDisplacement(DVect v, bool local=false)=0
Sets the gridpoint displacement for small strain, see getSmallDisplacement()
virtual double getStiff() const =0
Returns the gridpoint stiffness.
virtual DVect getVelocity(bool local=false) const =0
Returns the gridpoint velocity, see setVelocity();.
virtual const IFluidGp * getIFluidGp() const =0
Returns a const pointer to the gridpoint fluid-flow data.
virtual void setPPFix(bool b)=0
If parameter b is treu, sets the gridpoint pore-pressure to be kept fixed during calculation,...
virtual bool isThermalNull() const =0
Returns true to indicate that gridpoint thermal flag is set to NULL.
virtual bool getLocSmall() const =0
Returns 1 if gridpoint behaves as in small-strain mode. See setLocSmall();.
virtual bool isMechanicalNull() const =0
Returns true to indicate that gridpoint is "nulled".
virtual void setFApplyUser(const DVect &d, bool local=false)=0
using the APPLY command. See getFApplyUser()
virtual void setLocSmall(bool b)=0
If parameter b is true, the gridpoint will behave as in small-strain mode. See getLocSmall();.
virtual DVect getDisplacement(bool local=false) const =0
Returns the gridpoint displacement, seet setDisplacement();.
virtual DVect getTotalForceLast(bool reaction=false, bool local=false) const =0
virtual void setPP(double d)=0
Sets the gridpoint pore-pressure, see getPP()
virtual DVect getFobLast(bool local=false) const =0
Returns the gridpoint out of balance force.
virtual bool fishIO(bool save, fish::File *f)=0
virtual DVect getFApplyUser(bool local=false) const =0
virtual DVect getSmallDisplacement(bool local=false) const =0
Returns the gridpoint displacement accumulated for small strain, see setSmallDisplacement()
virtual void setFix(IVect v)=0
virtual DVect getPosition() const =0
Returns the gridpoint position, see setPosition()
virtual DVect getFap(bool local=false) const =0
Returns the sum of the gridpoint static applied force and the dynamic applied force.
virtual void setTempChange(const double &d)=0
Sets dDTemp.
static const TType type_
The type identification number for this class, for use in convert_cast() and convert_getcast().
Definition: igp.h:59
virtual const IThermGp * getIThermGp() const =0
Returns a const pointer to IThermGp.
virtual DVect getMassAdd(bool local=false) const =0
virtual const IGp * getNext() const =0
virtual IZone * getLinkZone()=0
virtual double getInertialMass() const =0
Returns the gridpoint inertial mass, see setInertialMass()
virtual double getSat() const =0
Returns the gridpoint fluid saturation, see setSat()
virtual void setValue(int index, const QVariant &v) const =0
virtual bool getPPFix() const =0
Returns 1 if the gridpoint has fixed pore-pressure, otherwise value 0 indicates non-fixed pore-pressu...
virtual IThing * getIThing()=0
Returns a IThing pointer.
virtual void setDisplacement(DVect v, bool local=false)=0
Sets the gridpoint displacement, seet getDisplacement();.
virtual const IThing * getIThing() const =0
Returns a const IThing pointer.
virtual void setSystem(const Axes &a)=0
Sets the user-defined local axes.
virtual bool isFluidNull() const =0
Returns true to indicate that gridpoint fluid flag is set to NULL.
virtual double getGravitationalMass() const =0
Returns the gridpoint gravitational mass, see setGravitationalMass()
virtual uint32 getLinkIndex() const =0
virtual IThermGp * getIThermGp()=0
Returns a pointer to IThermGp.
virtual Axes getSystem() const =0
Returns the user-defined local axes.
virtual void copyState(const IGp *gp)=0
Copies the state of this gridpoint to gp.
Interface to access node data.
Definition: inode.h:18
Interface to access gridpoint thermal data.
Definition: ithermgp.h:12
Interface to provide access to a zone.
Definition: izone.h:80
DIM - Provides code portability between 2D and 3D codes.
uint32 TType
class type indicator
Definition: basedef.h:46
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition: dim.h:150
IVect3 IVect
Vector of ints, either 2D or 3D.
Definition: dim.h:152
namespace Itasca
Definition: basememory.cpp:10