CoupledTHFemPhysics
The GeMA Coupled Thermo-Hydraulic FEM Physics Plugin
Loading...
Searching...
No Matches
GmpCoupledThermoHydraulic Class Reference

Thermo mechanical 2D & 3D : Quad, Tri, Hex and Tet. More...

#include <gmpCoupledThermoHydraulic.h>

Inheritance diagram for GmpCoupledThermoHydraulic:
Collaboration diagram for GmpCoupledThermoHydraulic:

Public Types

enum  GaussAttributeIds { T_GA_ID , TOLD_GA_ID , NUM_GA_IDS }
 IDs for physics Gauss attributes. More...
 

Public Member Functions

 GmpCoupledThermoHydraulic (const char *pluginType, GmSimulationData *simulation, QString id, QString description, const GmpFemPhysicsCommonMaterialFactory *matFactory, const GmLogCategory &logger)
 
virtual ~GmpCoupledThermoHydraulic ()
 Destructor.
 
virtual const QVariantMap * physicsMetaDataMap ()
 Returns a reference for the Hydraulics dual flow attribute map, built when the function is called for the first time.
 
virtual FemResultType fillElementData (const GmElement *e, GmpFemMatrixSet &elemMatrices, GmpFemVectorSet &elemVectors)
 Fills the element matrices and vectors for a generic element. Applying the Galerking method (Zienkiewicz and Taylor, 1989)
 
virtual bool calcDerivedResults (bool nonLinearSolver)
 Calc velocity and flow on nodes and/or Gauss points.
 
virtual void gravityForce (const GmElement *e, const GmVector *coord, int ip, GmVector &GFc, GmVector &N, double c)
 
virtual bool beforeElementStiffnessLoop (const GmpFemMatrixSet &elemMatrices, const GmpFemVectorSet &elemVectors)
 
- Public Member Functions inherited from GmpCoupledTHFemPhysics
 GmpCoupledTHFemPhysics (const char *pluginType, GmSimulationData *simulation, QString id, QString description, const GmpFemPhysicsCommonMaterialFactory *matFactory, const GmLogCategory &logger)
 Constructor. Will be called by the plugin loading code.
 
virtual ~GmpCoupledTHFemPhysics ()
 Destructor.
 
virtual const char * pluginName () const
 
virtual const char * pluginType () const
 
void fillFluidConductivityMatrix (GmMatrix &Kf, const GmElement *e, const GmVector *ip, int ipIndex)
 Fills the pore fluid conductivity matrix _kfMat evaluating accessor at the integration point ip of element e (ncoord can be NULL if accessors do not accept user functions), taking in consideration that the accessor might return scalars or vectors.
 
virtual bool fixedNodalForcesBc (QVector< int > &nodes, QVector< int > &dof, QVector< double > &values) const
 
virtual bool fixedNodalDofsBc (QVector< int > &nodes, QVector< int > &dof, QVector< double > &values, bool *constantValues) const
 

Protected Member Functions

virtual bool checkAndLoadAttributeAccessors (LuaTable &nodeTable, LuaTable &cellTable, LuaTable &gaussTable)
 Reimplementation of the common function to init the _mechanicPoint structure.
 
virtual const GmElementDofdofMapping (GmCellType type) const
 
virtual void fillDofIndexPosition (const GmElement *e, QVector< int > &iPe, QVector< int > &iTe)
 Fills the position index with the degreee of freedom, both the hydraulic and thermal physics. the implementation supports order of the defined state variables i.e {P, T} or {T, P}

 
virtual void fillFluidCompressibilityMatrix (const GmElement *e, const GmVector *coord, int ip, GmMatrix &Sc, GmVector &Np, double c)
 Calculates the fluid compressibility matrix.
 
virtual void fillThermalHydraulicCouplingMatrix (const GmElement *e, const GmVector *coord, int ip, GmMatrix &Ze, const GmVector &Np, double a, double af, double c) const
 Calculates the fluid compressibility matrix.
 
virtual bool assemblyElemDampingMatrix (const GmElement *e, GmMatrix &elemC, const GmMatrix &Se, const GmMatrix &Ze, const GmMatrix &Xe, const QVector< int > &iPe, const QVector< int > &iTe) const
 Assembly the damping matrix.
 
virtual bool assemblyElemStiffnessMatrix (const GmElement *e, GmMatrix &elemK, const GmMatrix &He, const GmMatrix &Ie, const GmMatrix &Ge, const QVector< int > &iPe, const QVector< int > &iTe) const
 Assembly the stiffness matrix.
 
virtual bool getPorePressureGaussPoint (const GmElement *e, const GmVector *coord, int ip, GmVector &Pg, const GmVector &Np, const GmVector &Pe) const
 Evaluates Pore pressure at integration points.
 
virtual void assemblyInternalForceVector (const GmElement *e, GmMatrix &elemFi, const GmMatrix &He, const GmMatrix &Ge, const GmMatrix &Ie, const GmVector &Pe, const GmVector &Te, const QVector< int > &iPe, const QVector< int > &iTe) const
 Assembly the internal force vector.
 
virtual bool setInitialConditions ()
 Sets the initial conditionrequired by interface elements.
 
- Protected Member Functions inherited from GmpCoupledTHFemPhysics
virtual bool checkAndLoadPrivateData (LuaTable &table)
 Overloads default checkAndLoadPrivateData() to be able to setup materials.
 

Protected Attributes

bool _setInitialCond
 Sets the initial conditions required by the physics.
 
- Protected Attributes inherited from GmpCoupledTHFemPhysics
const char * _pluginType
 The plugin type name.
 
GmpThermoFemPhysics * _thermoPhys
 The thermo physics providing parameters and matrices to the coupling TH equation.
 
GmpHydraulic * _hydroPhys
 The hydraulic physics providing parameters and B matrix to the coupling TH equation.
 

Private Attributes

bool _hasElementGeneration
 Should we enable heat sources on elements (does not affect point generation sources)?
 

Additional Inherited Members

- Protected Types inherited from GmpCoupledTHFemPhysics
enum  PhysicsAttributeIds { ISOPARAMETRIC_ID , REFERENCE_T_ID , NUM_ATTRI_IDS }
 IDs for physics attributes. More...
 
enum  StateVarIds { P_ID , T_ID , NUM_STATEVAR_IDS }
 IDs for thermic and hydraulic physics state vars. More...
 
enum  NodeAttributeIds { TREF_NA_ID , NUM_NA_IDS }
 IDs for thermo-mechanical node attributes. More...
 
enum  ElementPropertyIds {
  KF_ID , ALPHA_ID , ALPHAF_ID , RHOF_ID ,
  CPF_ID , NUM_PROPER_IDS
}
 IDs for physics element properties. More...
 

Detailed Description

Thermo mechanical 2D & 3D : Quad, Tri, Hex and Tet.

Member Enumeration Documentation

◆ GaussAttributeIds

IDs for physics Gauss attributes.

Enumerator
TOLD_GA_ID 

Id for retrieving the stress accessor at the previous temperature (old temperature)

NUM_GA_IDS 

The number of Gauss attribute ids above.

Member Function Documentation

◆ assemblyElemStiffnessMatrix()

bool GmpCoupledThermoHydraulic::assemblyElemStiffnessMatrix ( const GmElement * e,
GmMatrix & elemK,
const GmMatrix & He,
const GmMatrix & Ie,
const GmMatrix & Ge,
const QVector< int > & iPe,
const QVector< int > & iTe ) const
protectedvirtual

Assembly the stiffness matrix.

Assembly the elemental stiffness.

◆ assemblyInternalForceVector()

void GmpCoupledThermoHydraulic::assemblyInternalForceVector ( const GmElement * e,
GmMatrix & elemFi,
const GmMatrix & He,
const GmMatrix & Ge,
const GmMatrix & Ie,
const GmVector & Pe,
const GmVector & Te,
const QVector< int > & iPe,
const QVector< int > & iTe ) const
protectedvirtual

Assembly the internal force vector.

Assemble the internal forces.

◆ fillFluidCompressibilityMatrix()

void GmpCoupledThermoHydraulic::fillFluidCompressibilityMatrix ( const GmElement * e,
const GmVector * coord,
int ip,
GmMatrix & Sc,
GmVector & Np,
double c )
protectedvirtual

Calculates the fluid compressibility matrix.

Calculates the compressibility matrix of "storage / compressibility" for element 'e' at the given integration point (coord, ip) storing the result at the Sc matrix. N is the shape function vector and c a constant equal to w * h * detJ.

Returns Sc = N * ((Biot - porosity)/Kss + porosity/Kww) * N.t() * c, where c should be equal to w * h * detJ

◆ fillThermalHydraulicCouplingMatrix()

void GmpCoupledThermoHydraulic::fillThermalHydraulicCouplingMatrix ( const GmElement * e,
const GmVector * coord,
int ip,
GmMatrix & Ze,
const GmVector & Np,
double a,
double af,
double c ) const
protectedvirtual

Calculates the fluid compressibility matrix.

Calculates the thermal hydraulic coupling matrix. Returns Ze = Np.t() * Nt * 3.0 * [porosity*(alphaF - alpha) + alpha] * c where c = w * h * detJ.

◆ getPorePressureGaussPoint()

bool GmpCoupledThermoHydraulic::getPorePressureGaussPoint ( const GmElement * e,
const GmVector * coord,
int ip,
GmVector & Pg,
const GmVector & Np,
const GmVector & Pe ) const
protectedvirtual

Evaluates Pore pressure at integration points.

Evaluates pore pressure al gauss points.

◆ physicsMetaDataMap()

const QVariantMap * GmpCoupledThermoHydraulic::physicsMetaDataMap ( )
virtual

Returns a reference for the Hydraulics dual flow attribute map, built when the function is called for the first time.

Reimplemented from GmpCoupledTHFemPhysics.


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