MechanicalFemPhysics
The GeMA Mechanical FEM Physics Plugin
gmpMaterialGeneralYieldSurface.h
Go to the documentation of this file.
1 /************************************************************************
2 **
3 ** Copyright (C) 2016 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_GENERAL_YIELD_SURFACE_H_
28 #define _GEMA_PLUGIN_MECHANICALMATERIAL_GENERAL_YIELD_SURFACE_H_
29 
31 #include "gmpMechanicPoint.h"
32 #include "gmpFemPhysics.h"
33 #include "gmMathUtils.h"
34 
35 class GMP_MECHANICAL_PHYSICS_API_EXPORT GmpMaterialGeneralYieldSurface : public GmpMaterialElastoplastic
36 {
37 protected:
40  {
47  A_ID,
48 
49  // --- NO ADDING BELOW THIS LINE
51  };
52 
53 public:
54 
56  GmpMaterialGeneralYieldSurface(int typeIndex, QString typeName, const GmLogCategory& logger)
57  : GmpMaterialElastoplastic(typeIndex, typeName, logger) {}
58 
61 
63  static GmpFemPhysicsCommonMaterial* instance(GmSimulationData* simulation, int typeIndex, QString typeName, const GmLogCategory& logger)
64  {
65  Q_UNUSED(simulation);
66  return new GmpMaterialGeneralYieldSurface(typeIndex, typeName, logger);
67  }
68 
69  // Returns a map with material associated properties.
70  virtual const QVariantMap* materialMetaDataMap();
71 
73  virtual bool isIsotropic() const { return true; }
74 
76  virtual double cohesion(const GmElement* e, const GmVector* coord, int ip) const
77  {
78  return propertyAc(COH_ID)->scalarValueAt(e, coord, ip);
79  }
81  virtual double frictionAngle(const GmElement* e, const GmVector* coord, int ip) const
82  {
83  return propertyAc(PHI_ID)->scalarValueAt(e, coord, ip);
84  }
86  virtual double dilationAngle(const GmElement* e, const GmVector* coord, int ip) const
87  {
88  return propertyAc(PSI_ID)->scalarValueAt(e, coord, ip);
89  }
91  virtual double firstShapeFactor(const GmElement* e, const GmVector* coord, int ip) const
92  {
93  return propertyAc(ALPHA_ID)->scalarValueAt(e, coord, ip);
94  }
96  virtual double secondShapeFactor(const GmElement* e, const GmVector* coord, int ip) const
97  {
98  return propertyAc(BETA_ID)->scalarValueAt(e, coord, ip);
99  }
101  virtual double thirdShapeFactor(const GmElement* e, const GmVector* coord, int ip) const
102  {
103  return propertyAc(GAMMA_ID)->scalarValueAt(e, coord, ip);
104  }
106  virtual double fourthShapeFactor(const GmElement* e, const GmVector* coord, int ip) const
107  {
108  return propertyAc(A_ID)->scalarValueAt(e, coord, ip);
109  }
110 
111  // Yield criterion
112  virtual double yieldCriterion(const GmElement*, const GmVector&, const GmVector*, int, unsigned) const;
113  virtual bool yieldStressGradient(const GmElement*, GmVector&, const GmVector&, const GmVector*, int, unsigned, bool) const;
114  virtual bool yieldHessian(const GmElement*, GmMatrix&, const GmVector&, const GmVector*, int, unsigned, bool) const;
115 
116  // Plastic potential
117  virtual double plasticFPotential(const GmElement*, const GmVector&, const GmVector*, int, unsigned) const;
118  virtual bool flowVector(const GmElement*, GmVector&, const GmVector&, const GmVector*, int, unsigned, bool) const;
119  virtual bool flowVectorStressGradient(const GmElement*, GmMatrix&, const GmVector&, const GmVector*, int, unsigned, bool) const;
120 
122  virtual double yieldStrengthRatio(const GmElement* e, const GmVector& S, const GmVector* coord, int ip, unsigned sc) const;
123 
124 };
125 
126 #endif
GmpMaterialGeneralYieldSurface(int typeIndex, QString typeName, const GmLogCategory &logger)
Constructor. Gets as parameters the material index and its name.
Definition: gmpMaterialGeneralYieldSurface.h:56
Id for retrieving the dilatance angle accessor.
Definition: gmpMaterialGeneralYieldSurface.h:43
virtual double dilationAngle(const GmElement *e, const GmVector *coord, int ip) const
Returns the material dilation angle.
Definition: gmpMaterialGeneralYieldSurface.h:86
Definition: gmpMaterialGeneralYieldSurface.h:35
ElementPropertyIds
IDs for material element properties.
Definition: gmpMaterialElastic.h:38
Id for retrieving the fourth shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:47
virtual double fourthShapeFactor(const GmElement *e, const GmVector *coord, int ip) const
Returns the fourth shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:106
The number of property ids above.
Definition: gmpMaterialElastoplastic.h:79
The number of property ids above.
Definition: gmpMaterialGeneralYieldSurface.h:50
virtual double firstShapeFactor(const GmElement *e, const GmVector *coord, int ip) const
Returns the first shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:91
Id for retrieving the friction angle accessor.
Definition: gmpMaterialGeneralYieldSurface.h:42
Declaration of the gmpMaterialElastoplastic classes.
virtual double yieldStrengthRatio(const GmElement *e, const GmVector &S, const GmVector *coord, int ip, unsigned sc) const =0
Returns the Yield Strength Ratio (Ysr)
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: gmpMaterialGeneralYieldSurface.h:63
Declaration of the GmpMechanicPoint class.
Id for retrieving the second shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:45
virtual bool isIsotropic() const
Returns true if the material is isotropic, false otherwise.
Definition: gmpMaterialGeneralYieldSurface.h:73
Id for retrieving the third shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:46
virtual double thirdShapeFactor(const GmElement *e, const GmVector *coord, int ip) const
Returns the third shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:101
arma::vec GmVector
virtual double secondShapeFactor(const GmElement *e, const GmVector *coord, int ip) const
Returns the second shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:96
virtual ~GmpMaterialGeneralYieldSurface()
Virtual destructor.
Definition: gmpMaterialGeneralYieldSurface.h:60
Definition: gmpMaterialElastoplastic.h:35
arma::mat GmMatrix
Id for retrieving the first shape factor.
Definition: gmpMaterialGeneralYieldSurface.h:44
virtual const QVariantMap * materialMetaDataMap()
Returns a pointer to the material/Gauus attribute map, built when the function is called for the firs...
Definition: gmpMaterialElastoplastic.cpp:45