Itasca C++ Interface
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | List of all members
models::State Struct Referenceabstract

The structure used to pass information to the constitutive model. More...

#include <state.h>

Public Types

enum class  CondType { D3 =0 , D2 , D1 }
 

Public Member Functions

virtual double getSubZoneVolume () const =0
 
virtual double getZoneVolume (bool deformed=false) const =0
 Volume of the current zone as a whole.
 
virtual DVect3 getRotation () const =0
 Three components of overlay unit rotation in large strain.
 
virtual double getDensity () const =0
 Density of the zone.
 
virtual void setDensity (const double &)=0
 set Density of the zone.
 
virtual double getTemperature () const =0
 Temperature of the zone.
 
virtual double getTimeStep () const =0
 The current time step.
 
virtual double getPorosity () const =0
 The current zone fluid porosity.
 
virtual bool isLarge () const =0
 true if in large strain mode.
 
virtual bool isThermal () const =0
 true if thermal is configured.
 
virtual bool isCreep () const =0
 true if creep is configured.
 
virtual bool isFluid () const =0
 true if fluid/flow is configured.
 
virtual bool isThermalInUse () const =0
 true if thermal is in use.
 
virtual bool isCreepInUse () const =0
 true if creep is in use.
 
virtual bool isFluidInUse () const =0
 true if fluid/flow is in use.
 
virtual SymTensor getEffectiveZoneStress () const =0
 The average effective stress in the zone.
 
virtual double getAveragePP () const =0
 The average pore pressure in the zone.
 
virtual double getTMUtility (unsigned index=0) const =0
 Returns Thermal to Mechanical communication utility values.
 
virtual double getFMUtility (unsigned index=0) const =0
 Returns Fluid to Mechanical communication utility values.
 
virtual void * getTableIndexFromID (const string &id) const =0
 Return a table index given an ID.
 
virtual double getYFromX (void *index, const double &x) const =0
 The index pointer should be previously obtained from a getTableIndexFromID() call.
 
virtual double getSlopeFromX (void *index, const double &x) const =0
 The index pointer should be previously obtained from a getTableIndexFromID() call.
 
virtual IProgramgetIProgram ()=0
 A pointer to an IProgram interface for this code. May be null.
 
virtual IGenericZonegetIZone ()=0
 A pointer to the IZone being processed. May be null.
 
virtual IGenericTetgetITet ()=0
 A pointer to the ITet in the IZone being processed. May be null.
 
virtual uint64 getZoneID () const =0
 The ID or index of the Zone being processed. May be 0.
 
virtual uint64 getTetID () const =0
 The ID or index of the Tetra being processed. May be 0.
 

Public Attributes

unsigned int sub_zone_ = 0
 # of sub zone being operated on (starting at 0).
 
unsigned int total_sub_zones_ = 0
 Total # of sub zones involved, from all overlays. Minimum value of 1.
 
unsigned int overlay_ = 0
 
unsigned long state_ = 0
 Sub zone state bit flag.
 
SymTensor stnE_ = SymTensor(0.0)
 6 components of strain increment, input to run().
 
SymTensor stnS_ = SymTensor(0.0)
 The current stress tensor is input to run(), and the model must return the updated tensor.
 
double modulus_reduction_factor_ = 1.0
 modulus reduction factor from hysteretic damping or small strain effect.
 
bool viscous_ = false
 True if viscous strains are to be computed.
 
bool modulus_changed_ = false
 
double pore_pressure_increment_ = 0.0
 Set to true in run() if modulus has changed (confined, shear, bulk).
 
CondType condition_ = CondType::D3
 condition number to define conditions.
 
std::array< double, max_working_working_
 = 0, 3D general (default); = 1, 2D plane-stress; = 2, 1D uniaxial
 
std::array< int32, max_iworking_iworking_
 This is a working area for values that must be stored between run() calls.
 
SymTensor stnPSI_ = SymTensor(0.0)
 6 components of plastic strain increment.
 

Static Public Attributes

static const uint32 max_working_ = 50
 The size of the working_ array.
 
static const uint32 max_iworking_ = 10
 The size of the iworking_ array.
 

Detailed Description

The structure used to pass information to the constitutive model.

The most important link between FLAC3D and a user-written model is the member-function run(unsigned dim, State *ps), which computes the mechanical response of the model during cycling.
A structure, State (defined in state.h?, is used to transfer information to and from the model.
State is also sent to the initialize() method, although not all fields are guaranteed to be valid in that case.
The members of State (all public) are as follows.
Not all the information may be used by a particular code; the structure is intended to serve all Itasca codes.

Member Function Documentation

◆ getDensity()

virtual double models::State::getDensity ( ) const
pure virtual

Density of the zone.

Density of full zone. Note that density is automatically updated by FLAC3D in large-strain mode if the volume changes.

◆ getEffectiveZoneStress()

virtual SymTensor models::State::getEffectiveZoneStress ( ) const
pure virtual

The average effective stress in the zone.

For some stress-dependent constitutive models to access the previous zone-level stress, It should be called only once before any stress update in any subzone.

◆ getRotation()

virtual DVect3 models::State::getRotation ( ) const
pure virtual

Three components of overlay unit rotation in large strain.

Three components of zone rotation (spin velocity multiplied by timestep), input to the model in large-strain mode.
This information may be used by models that have directional properties that must be updated in large-strain mode.

◆ getSlopeFromX()

virtual double models::State::getSlopeFromX ( void * index,
const double & x ) const
pure virtual

The index pointer should be previously obtained from a getTableIndexFromID() call.

Lookup a rate of change at a point in the table.

◆ getSubZoneVolume()

virtual double models::State::getSubZoneVolume ( ) const
pure virtual

Volume of the current sub zone. If the implementation does not define sub-zones (total_sub_zones_ = 1), then this should return the same as getZoneVolume().

◆ getTableIndexFromID()

virtual void * models::State::getTableIndexFromID ( const string & id) const
pure virtual

Return a table index given an ID.

Finding a table given an id number can be an expensive operation.
In general, it is better to store a reference pointer using this function during initialize(), and use it to access the table during run(). Index pointers should not be saved and restored, and should be found during every initialize() call. (Table data may have changed in the interim).

◆ getYFromX()

virtual double models::State::getYFromX ( void * index,
const double & x ) const
pure virtual

The index pointer should be previously obtained from a getTableIndexFromID() call.

Lookup a value in a table.

Member Data Documentation

◆ modulus_changed_

bool models::State::modulus_changed_ = false

A change in the elastic modulus of a zone (particulary if it gets stiffer) may have stability implications.
Setting this flag to true during run() notifies the code of this fact, so that stability requirements may be recalculated.

◆ overlay_

unsigned int models::State::overlay_ = 0

of times sub zones represent volume (1 or 2 usually).

◆ pore_pressure_increment_

double models::State::pore_pressure_increment_ = 0.0

Set to true in run() if modulus has changed (confined, shear, bulk).

Mean plastic stress change value, needed for nodal mixed discretization calculations. If plastic flow changes the pressure, it needs to be indicates here so that pressure averaging will proceed correctly.

Increment in fluid volume supplied by model (per unit volume)

◆ state_

unsigned long models::State::state_ = 0

Sub zone state bit flag.

Model state indicator bit flag.
Specific bits in this integer correspond to names in the getStates() member function.
For example, a flag value of 1 (bit 0) represents the first state, a value of 2 (bit 1) represents the second, a value of 4 (bit 2) represents the third, a value of 8 (bit 3) represents the fourth, etc.
Any number of bits may be selected simultaneously (for example, both shear and tensile yield may occur together).

◆ stnS_

SymTensor models::State::stnS_ = SymTensor(0.0)

The current stress tensor is input to run(), and the model must return the updated tensor.

6 components of stress.

◆ sub_zone_

unsigned int models::State::sub_zone_ = 0

# of sub zone being operated on (starting at 0).

This information may be used to scale accumulated sub-zone data correctly. For example, if ten sub-zones are present (see total_sub_zones_), accumulated values will need to be divided by ten, in order to obtain the average for the whole zone.

◆ viscous_

bool models::State::viscous_ = false

True if viscous strains are to be computed.

true if viscous strains are to be computed for the stiffnessproportional component of Rayleigh damping.
This flag defaults to false if not set.
Typically, it should be set true for an elastic increment, and false for an increment in which yielding occurs.

◆ working_

std::array<double,max_working_> models::State::working_

= 0, 3D general (default); = 1, 2D plane-stress; = 2, 1D uniaxial

This is a working area for values that must be stored between run() calls.


The documentation for this struct was generated from the following files: