MechanicalFemPhysics
The GeMA Mechanical FEM Physics Plugin
Loading...
Searching...
No Matches
gmpMaterialCrackingCrushingDamage.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
27#ifndef _GEMA_PLUGIN_MECHANICALMATERIAL_CRACKINGCRUSHINGDAMAGE_H_
28#define _GEMA_PLUGIN_MECHANICALMATERIAL_CRACKINGCRUSHINGDAMAGE_H_
29
30#include "gmpMechanicalConfig.h"
31#include "gmpFemPhysics.h"
32#include "gmMathUtils.h"
33
34#include "gmpMaterialElastic.h"
35#include "gmpMechanicPoint.h"
36
37
38class GMP_MECHANICAL_PHYSICS_API_EXPORT GmpMaterialCrackingCrushingDamage : public GmpMechanicalMaterialElastic
39{
40protected:
60
61public:
62
64 GmpMaterialCrackingCrushingDamage(int typeIndex, QString typeName, const GmLogCategory& logger)
65 : GmpMechanicalMaterialElastic(typeIndex, typeName, logger) {}
66
69
71 static GmpFemPhysicsCommonMaterial* instance(GmSimulationData* simulation, int typeIndex, QString typeName, const GmLogCategory& logger)
72 {
73 Q_UNUSED(simulation);
74 return new GmpMaterialCrackingCrushingDamage(typeIndex, typeName, logger);
75 }
76
77 // Returns a map with material associated properties.
78 virtual const QVariantMap* materialMetaDataMap();
79
80 // Checks material loaded data.
81 virtual bool checkLoadedData(const GmElement* e) const;
82
96
97 // Sets the initial conditions required by isotropic damage material
98 virtual bool setInitialConditions(const GmElement* e, GmpMechanicPoint* mp, const GmVector* coord, unsigned sc) const;
99
100 // Returns the stresses according to the material behavior adopted
101 virtual bool mechanicalConstitutiveModel(const GmElement* e, GmMatrix& Ded, const GmpMechanicPoint* mp, const GmVector* coord, const GmVector& Time, unsigned nc, bool ips) const;
102
104 virtual double ultimateUniaxialCompressiveStrength(const GmElement* e, const GmVector* coord, int ip) const
105 {
106 return propertyAc(FCM_ID)->scalarValueAt(e, coord, ip);
107 }
108
110 virtual double strainAtUltimateCompressiveStrength(const GmElement* e, const GmVector* coord, int ip) const
111 {
112 return propertyAc(RCM_ID)->scalarValueAt(e, coord, ip);
113 }
114
116 virtual double uniaxialTensileStrength(const GmElement* e, const GmVector* coord, int ip) const
117 {
118 return propertyAc(FT0_ID)->scalarValueAt(e, coord, ip);
119 }
120
122 virtual double biaxialTensileStrength(const GmElement* e, const GmVector* coord, int ip) const
123 {
124 return propertyAc(FBT_ID)->scalarValueAt(e, coord, ip);
125 }
126
128 virtual double tensileCriterionShapeParameter(const GmElement* e, const GmVector* coord, int ip) const
129 {
130 return propertyAc(FTC_ID)->scalarValueAt(e, coord, ip);
131 }
132
134 virtual double elasticUniaxialCompressiveLimit(const GmElement* e, const GmVector* coord, int ip) const
135 {
136 return propertyAc(FC0_ID)->scalarValueAt(e, coord, ip);
137 }
138
140 virtual double biaxialCompressiveStrength(const GmElement* e, const GmVector* coord, int ip) const
141 {
142 return propertyAc(FBC_ID)->scalarValueAt(e, coord, ip);
143 }
144
146 virtual double parameterRho(const GmElement* e, const GmVector* coord, int ip) const
147 {
148 return propertyAc(RHO_ID)->scalarValueAt(e, coord, ip);
149 }
150
152 virtual double fractureEnergy(const GmElement* e, const GmVector* coord, int ip) const
153 {
154 return propertyAc(GF_ID)->scalarValueAt(e, coord, ip);
155 }
156
158 virtual double crushingEnergy(const GmElement* e, const GmVector* coord, int ip) const
159 {
160 return propertyAc(GC_ID)->scalarValueAt(e, coord, ip);
161 }
162
164 virtual double userDefinedCharacteristicLength(const GmElement* e, const GmVector* coord, int ip) const
165 {
166 S_TRACE(); assert(e);
167 // Get accessor for the user-defined characteristic length
168 GmCellAccessor* lch = propertyAc(LCH_ID);
169
170 if (lch == NULL)
171 {
172 return 0.0;
173 }
174
175 return lch->scalarValueAt(e, coord, ip);
176 }
177
179 virtual double minimumCharacteristicLength(const GmElement* e, const GmVector* coord, int ip) const
180 {
181 S_TRACE(); assert(e);
182 // Get accessor for the minimum characteristic length
183 GmCellAccessor* lchmin = propertyAc(LCHMIN_ID);
184
185 if (lchmin == NULL)
186 {
187 return 0.0;
188 }
189
190 return lchmin->scalarValueAt(e, coord, ip);
191 }
192
193 // Damage criterion definition
194 virtual bool damageCriterion(const GmElement*, const GmpMechanicPoint*, const GmVector*, unsigned, GmVector, double&, double&, GmVector&, GmVector&, unsigned) const;
195
196 // Damage evolution law definition
197 virtual bool damageLaw(const GmElement*, const GmVector*, const GmpMechanicPoint*, double, double, double&, double&, double& dg) const;
198
199 // Returns the characteristic length
200 virtual double characteristicLength(const GmElement*, const GmVector*, int, GmValueAccessor*, bool type = false) const;
201};
202
203#endif
Definition gmpMaterialCrackingCrushingDamage.h:39
static GmpFemPhysicsCommonMaterial * instance(GmSimulationData *simulation, int typeIndex, QString typeName, const GmLogCategory &logger)
A "factory" function used to register the material with the physics material factory.
Definition gmpMaterialCrackingCrushingDamage.h:71
virtual double biaxialTensileStrength(const GmElement *e, const GmVector *coord, int ip) const
Returns the biaxial tensile strength of the material.
Definition gmpMaterialCrackingCrushingDamage.h:122
virtual double elasticUniaxialCompressiveLimit(const GmElement *e, const GmVector *coord, int ip) const
Returns the uniaxial compressive stress in which the damage process is initialized.
Definition gmpMaterialCrackingCrushingDamage.h:134
virtual double parameterRho(const GmElement *e, const GmVector *coord, int ip) const
Returns the triaxial compression adjustment parameter.
Definition gmpMaterialCrackingCrushingDamage.h:146
virtual double biaxialCompressiveStrength(const GmElement *e, const GmVector *coord, int ip) const
Returns the biaxial compressive strength of the material.
Definition gmpMaterialCrackingCrushingDamage.h:140
virtual double ultimateUniaxialCompressiveStrength(const GmElement *e, const GmVector *coord, int ip) const
Returns the ultimate uniaxial compressive strength of the material.
Definition gmpMaterialCrackingCrushingDamage.h:104
virtual double fractureEnergy(const GmElement *e, const GmVector *coord, int ip) const
Returns the fracture energy.
Definition gmpMaterialCrackingCrushingDamage.h:152
ElementPropertyIds
IDs for material element properties.
Definition gmpMaterialCrackingCrushingDamage.h:43
@ FC0_ID
Id for retrieving the uniaxial compressive stress in which the damage process is initialized accessor...
Definition gmpMaterialCrackingCrushingDamage.h:49
@ FT0_ID
Id for retrieving the uniaxial tensile strength accessor.
Definition gmpMaterialCrackingCrushingDamage.h:46
@ RCM_ID
Id for retrieving the strain that corresponds to the ultimate uniaxial compressive strength acessor.
Definition gmpMaterialCrackingCrushingDamage.h:45
@ GF_ID
Id for retrieving the fracture energy accessor.
Definition gmpMaterialCrackingCrushingDamage.h:52
@ LCH_ID
Id for retrieving the user-defined characteristic element length accessor.
Definition gmpMaterialCrackingCrushingDamage.h:54
@ FBT_ID
Id for retrieving the biaxial tensile strength of the material accessor.
Definition gmpMaterialCrackingCrushingDamage.h:47
@ NUM_PROPERTY_IDS
The number of property ids above.
Definition gmpMaterialCrackingCrushingDamage.h:58
@ FBC_ID
Id for retrieving the biaxial compressive strength accessor.
Definition gmpMaterialCrackingCrushingDamage.h:50
@ RHO_ID
Id for retrieving the triaxial compression adjustment parameter accessor.
Definition gmpMaterialCrackingCrushingDamage.h:51
@ LCHMIN_ID
Id for retrieving the minimum characteristic element length accessor.
Definition gmpMaterialCrackingCrushingDamage.h:55
@ FTC_ID
Id for retrieving the tensile criterion shape parameter accessor.
Definition gmpMaterialCrackingCrushingDamage.h:48
@ GC_ID
Id for retrieving the crushing energy accessor.
Definition gmpMaterialCrackingCrushingDamage.h:53
virtual double strainAtUltimateCompressiveStrength(const GmElement *e, const GmVector *coord, int ip) const
Returns the strain that corresponds to the ultimate uniaxial compressive strength of the material.
Definition gmpMaterialCrackingCrushingDamage.h:110
elasticDamageGaussAttrIds
IDs for Gauss attributes of elastic damage material.
Definition gmpMaterialCrackingCrushingDamage.h:85
@ TISVOLD_GA_ID
Id for retrieving the material point state accessor at the previous state.
Definition gmpMaterialCrackingCrushingDamage.h:89
@ DAMOLD_GA_ID
Id for retrieving the material point state accessor at the previous state.
Definition gmpMaterialCrackingCrushingDamage.h:87
@ NUM_GA_IDS
The number of gauss attributes.
Definition gmpMaterialCrackingCrushingDamage.h:94
@ TISV_GA_ID
Base Id for Gauss attribute(s) used to store the tensile internal state variable at the current state...
Definition gmpMaterialCrackingCrushingDamage.h:88
@ DAM_GA_ID
Base Id for Gauss attribute(s) used to store the damage variable at the current state.
Definition gmpMaterialCrackingCrushingDamage.h:86
@ CISV_GA_ID
Base Id for Gauss attribute(s) used to store the compressive internal state variable at the current s...
Definition gmpMaterialCrackingCrushingDamage.h:90
@ CISVOLD_GA_ID
Id for retrieving the material point state accessor at the previous state.
Definition gmpMaterialCrackingCrushingDamage.h:91
GmpMaterialCrackingCrushingDamage(int typeIndex, QString typeName, const GmLogCategory &logger)
Constructor. Gets as parameters the material index and its name.
Definition gmpMaterialCrackingCrushingDamage.h:64
virtual double userDefinedCharacteristicLength(const GmElement *e, const GmVector *coord, int ip) const
Returns the user-defined characteristic length.
Definition gmpMaterialCrackingCrushingDamage.h:164
virtual double minimumCharacteristicLength(const GmElement *e, const GmVector *coord, int ip) const
Returns the minimum characteristic length.
Definition gmpMaterialCrackingCrushingDamage.h:179
virtual double crushingEnergy(const GmElement *e, const GmVector *coord, int ip) const
Returns the crushing energy.
Definition gmpMaterialCrackingCrushingDamage.h:158
virtual double tensileCriterionShapeParameter(const GmElement *e, const GmVector *coord, int ip) const
Returns the tensile criterion shape parameter.
Definition gmpMaterialCrackingCrushingDamage.h:128
virtual ~GmpMaterialCrackingCrushingDamage()
Virtual destructor.
Definition gmpMaterialCrackingCrushingDamage.h:68
virtual double uniaxialTensileStrength(const GmElement *e, const GmVector *coord, int ip) const
Returns the uniaxial tensile strength of the material.
Definition gmpMaterialCrackingCrushingDamage.h:116
Definition gmpMechanicPoint.h:33
Definition gmpMaterialElastic.h:35
virtual bool mechanicalConstitutiveModel(const GmElement *e, GmMatrix &Dep, const GmpMechanicPoint *mp, const GmVector *coord, const GmVector &Time, unsigned nc, bool ips) const
Evaluates stress and tangent matrix according to the material behavior adopted.
Definition gmpMaterialElastic.cpp:83
virtual const QVariantMap * materialMetaDataMap()
Returns a pointer to the material attribute map, built when the function is called for the first time...
Definition gmpMaterialElastic.cpp:40
@ NUM_PROPERTY_IDS
The number of property ids above.
Definition gmpMaterialElastic.h:46
virtual bool setInitialConditions(const GmElement *e, GmpMechanicPoint *mp, const GmVector *coord, unsigned sc) const
Sets the initial conditions required by Solid materials.
Definition gmpMechanicalMaterial.h:69
arma::mat GmMatrix
#define S_TRACE()
arma::vec GmVector
Declaration of the GmpMechanicalMaterialElastic class.
Declaration of the GmpMechanicPoint class.
Declaration of useful configuration definitions for the plugin library.