HydroFemPhysics
The GeMA Hydraulic FEM Physics Plugin
Loading...
Searching...
No Matches
gmpHydraulicEmbeddedFracture.h
Go to the documentation of this file.
1/************************************************************************
2**
3** Copyright (C) 2014 by Carlos Augusto Teixera Mendes
4** All rights reserved.
5**
6** This file is part of the "GeMA" software. It's use should respect
7** the terms in the license agreement that can be found together
8** with this source code.
9** It is provided AS IS, with NO WARRANTY OF ANY KIND,
10** INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR
11** A PARTICULAR PURPOSE.
12**
13************************************************************************/
14
25#ifndef _GEMA_PLUGIN_HYDRAULICS_EMBEDDED_FRACTURE_H_
26#define _GEMA_PLUGIN_HYDRAULICS_EMBEDDED_FRACTURE_H_
27
28
29#include "gmpHydraulicConfig.h"
30#include "gmpHydraulicEmbeddedFractureConductive.h"
31
32#include <gmpFemPhysicsCommon.h>
33#include <gmpFemPhysicsData.h>
34#include <gmpHydraulic.h>
35#include <gmGaussAccessor.h>
36#include <gmMathUtils.h>
37#include <gmDiscontinuitySet.h>
38#include <gmDiscontinuity.h>
40
41class GmGaussAccessor;
42
45class GMP_HYDRAULIC_PHYSICS_API_EXPORT GmpHydraulicEmbeddedFracture : public GmpHydraulicEmbeddedFractureConductive
46{
47public:
48 // constructor
49 GmpHydraulicEmbeddedFracture(const char* pluginType, GmSimulationData* simulation, QString id, QString description,
50 const GmpFemPhysicsCommonMaterialFactory* matFactory, const GmLogCategory& logger);
51 // destructor
53
54 // Comments on the base class
55 virtual const char* pluginType() const { return _pluginType; }
56
57 // Comments on the base class
58 virtual const QVariantMap* physicsMetaDataMap();
59
60 // Comments on the base class
61 bool checkAndLoadAttributeAccessors(LuaTable& nodeTable, LuaTable& cellTable, LuaTable& gaussTable);
62
63 // Comments on the base class
64 virtual FemResultType fillElementData(const GmElement* e, GmpFemMatrixSet& elemMatrices, GmpFemVectorSet& elemVectors);
65
66 // Fills the element matrices and vectors for a enriched element.
67 virtual FemResultType fillEnrichedElementData(const GmElement* e, GmpFemMatrixSet& elemMatrices, GmpFemVectorSet& elemVectors, int nDiscontinuities);
68
69 // Discretizes the system of equations in time using a fully implicit scheme.
70 virtual FemResultType fullyImplicitTimeDiscretization(const GmElement* e, GmpFemMatrixSet& elemMatrices, GmpFemVectorSet& elemVectors);
71
72 // Fills nodal pressure of the discontinuity elements inside element e
74
75 // Fills degrees of freedom
76 void fillElementOldPorePressure(const GmElement* e, GmVector& pe);
77 void fillElementPorePressureJump(const GmElement* e, GmVector& Dp);
78 void fillElementOldPorePressureJump(const GmElement* e, GmVector& dpe);
79 void setElementPorePressureJump(const GmElement* e, GmVector& dpe);
80 void fillDiscontinuitySetInternalPressure(const GmElement* e, GmVector& pd, QMap<int, int> dNodesGlobalToLocal);
81 void fillDiscontinuitySetOldInternalPressure(const GmElement* e, GmVector& pdOld, QMap<int, int> dNodesGlobalToLocal);
82 void setDiscontinuitySetInternalPressure(const GmElement* e, GmVector& pd, QMap<int, int> dNodesGlobalToLocal);
83
84 // Fills the element matrices and vectors of the enriched element that considers a discontinuous pressure field.
85 FemResultType fillDiscontinuousPressureElementSubData(const GmElement* e, bool needsK, bool needsC, bool needsFi, GmMatrix& Hcc, GmMatrix& Hcj, GmMatrix& Hjc, GmMatrix& Hjj, GmMatrix& Scc, GmMatrix& Scj, GmMatrix& Sjj, QMap<int, int> dNodesGlobalToLocal, int nDeltaPDofs);
86
87 // Fills the element compressibility matrices for a enriched element with discontinuous pressure field.
88 void fillCompressibilityMatrices(const GmElement* e, GmMatrix& Xe, const GmVector* coord, int ip, GmMatrix& Scc, GmMatrix& Scj, GmMatrix& Sjj, const GmVector& N, double c, int nDeltaPDofs);
89
90 // Fills the element fluid-flow matrices for a enriched element with discontinuous pressure field.
91 void fillFluidFlowMatrices(const GmElement* e, GmMatrix& Xe, const GmVector* coord, int ip, GmMatrix& Hcc, GmMatrix& Hcj, GmMatrix& Hjc, GmMatrix& Hjj, const GmMatrix& Bp, double c, int nDeltaPDofs);
92
93 // Enriched shape function associated with the discontinuity idDiscontinuityElem
94 void fillEnrichedShapeValues(const GmElement* e, GmMatrix& Xe, GmVector& N, GmVector& X, int idDiscontinuityElem, GmVector& Nenr);
95
96 // Enriched shape function matrix
97 void fillNenrMatrix(const GmElement* e, GmMatrix& Xe, GmVector& N, GmVector& X, GmVector& Nenr);
98
99 // Enriched gradient pressure matrix
100 void fillGMatrix(const GmElement* e, GmMatrix& Xe, const GmMatrix& B, GmMatrix& G);
101
102 // Gets the number of enriched dofs (pressure jumps) at the element
103 int getNumberEnrichedDofs(const GmElement* e);
104
105 // Fills the element matrices and vectors of the discontinuity elements.
106 FemResultType fillDiscontinuitySetElementData(const GmElement* e, GmMatrix& Hd, GmMatrix& Sd, GmMatrix& Lcc, GmMatrix& Lcj, GmMatrix& Lcd, GmMatrix& Ljj, GmMatrix& Ljd, GmMatrix& Ldd, GmMatrix& Tcd, GmMatrix& Tjd, QMap<int, int> globalToLocal);
107
110 {
112 DP_ID, // Current pressure jump
113 DPOLD_ID, // Old pressure jump
114
115 // ------ NO ADDING BELOW THIS LINE
117 };
118
119private:
120 const char* _pluginType;
122};
123
124#endif
Basic class for the hydraulic physics plugin object.
Definition gmpHydraulicEmbeddedFractureConductive.h:45
virtual bool fillDiscontinuityInternalPressureNodalValues(GmElement *e, GmValueAccessor *nAc)
Fills nodal pressure of the discontinuity elements inside element e.
Definition gmpHydraulicEmbeddedFractureConductive.cpp:563
bool checkAndLoadAttributeAccessors(LuaTable &nodeTable, LuaTable &cellTable, LuaTable &gaussTable)
Reimplementation of the common function to init the _hmaterialPointAccessor structure.
Definition gmpHydraulicEmbeddedFractureConductive.cpp:89
FemResultType fillDiscontinuitySetElementData(const GmElement *e, GmMatrix &Hd, GmMatrix &Sd, GmMatrix &Tcd, const QMap< int, int > &dNodesGlobalToLocal)
Fills the element matrices and vectors of the discontinuity elements.
Definition gmpHydraulicEmbeddedFractureConductive.cpp:367
virtual FemResultType fillEnrichedElementData(const GmElement *e, GmpFemMatrixSet &elemMatrices, GmpFemVectorSet &elemVectors, int nDiscontinuities)
Fills the element matrices and vectors for a enriched element.
Definition gmpHydraulicEmbeddedFractureConductive.cpp:217
virtual FemResultType fillElementData(const GmElement *e, GmpFemMatrixSet &elemMatrices, GmpFemVectorSet &elemVectors)
Fills the element matrices and vectors for a generic element.
Definition gmpHydraulicEmbeddedFractureConductive.cpp:187
const char * _pluginType
The plugin type name.
Definition gmpHydraulicEmbeddedFractureConductive.h:89
virtual const QVariantMap * physicsMetaDataMap()
Returns a reference for the single Hydraulics attribute map, built when the function is called for th...
Definition gmpHydraulicEmbeddedFractureConductive.cpp:65
Basic class for the hydraulic physics plugin object.
Definition gmpHydraulicEmbeddedFracture.h:46
embeddedPhysicsAttributeIds
IDs for physics attributes.
Definition gmpHydraulicEmbeddedFracture.h:110
@ NUM_ATTRI_IDS
The number of physics attribute ids above.
Definition gmpHydraulicEmbeddedFracture.h:116
@ DP_ID
Id for the cell attributes.
Definition gmpHydraulicEmbeddedFracture.h:112
const char * _pluginType
The plugin type name.
Definition gmpHydraulicEmbeddedFracture.h:120
GmValueAccessor * _pOldAcc
Accessor to the old pore pressure.
Definition gmpHydraulicEmbeddedFracture.h:121
arma::mat GmMatrix
arma::vec GmVector
Declaration of the gmpHydraulic classes.
Declaration of useful configuration definitions for the plugin library.