MechanicalFemPhysics
The GeMA Mechanical FEM Physics Plugin
gmpMaterialDruckerPrager.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_DRUCKER_PRAGER_H_
28 #define _GEMA_PLUGIN_MECHANICALMATERIAL_DRUCKER_PRAGER_H_
29 
31 #include "gmpMechanicPoint.h"
32 #include "gmpFemPhysics.h"
33 #include "gmMathUtils.h"
34 
35 class GMP_MECHANICAL_PHYSICS_API_EXPORT GmpMaterialDruckerPrager : public GmpMaterialElastoplastic
36 {
37 protected:
40  {
44 
45  // --- NO ADDING BELOW THIS LINE
47  };
48 
49 public:
50 
52  GmpMaterialDruckerPrager(int typeIndex, QString typeName, const GmLogCategory& logger)
53  : GmpMaterialElastoplastic(typeIndex, typeName, logger) {}
54 
57 
59  static GmpFemPhysicsCommonMaterial* instance(GmSimulationData* simulation, int typeIndex, QString typeName, const GmLogCategory& logger)
60  {
61  Q_UNUSED(simulation);
62  return new GmpMaterialDruckerPrager(typeIndex, typeName, logger);
63  }
64 
65  // Returns a map with material associated properties.
66  virtual const QVariantMap* materialMetaDataMap();
67 
68  // Returns the stresses according to an alternative return mapping algorithm
69  virtual bool alternativeReturnAlgorithm(const GmElement*, GmMatrix&, const GmpMechanicPoint*, const GmVector*, unsigned, bool) const;
70 
72  virtual bool isIsotropic() const { return true; }
73 
75  virtual double cohesion(const GmElement* e, const GmVector* coord, int ip) const
76  {
77  return propertyAc(COH_ID)->scalarValueAt(e, coord, ip);
78  }
80  virtual double frictionAngle(const GmElement* e, const GmVector* coord, int ip) const
81  {
82  return propertyAc(PHI_ID)->scalarValueAt(e, coord, ip);
83  }
85  virtual double dilationAngle(const GmElement* e, const GmVector* coord, int ip) const
86  {
87  return propertyAc(PSI_ID)->scalarValueAt(e, coord, ip);
88  }
89 
90  // Yield criterion
91  virtual double yieldCriterion(const GmElement* e, const GmVector& s, const GmVector* coord, int ip, unsigned sc) const;
92  virtual bool yieldStressGradient(const GmElement* e, GmVector& dfs, const GmVector& s, const GmVector* coord, int ip, unsigned sc, bool ips) const;
93  virtual bool yieldHessian(const GmElement* e, GmMatrix& dfss, const GmVector& s, const GmVector* coord, int ip, unsigned sc, bool ips) const;
94 
95  // Plastic potential
96  virtual double plasticFPotential(const GmElement* e, const GmVector& s, const GmVector* coord, int ip, unsigned sc) const;
97  virtual bool flowVector(const GmElement* e, GmVector& dgs, const GmVector& s, const GmVector* coord, int ip, unsigned sc, bool ips) const;
98  virtual bool flowVectorStressGradient(const GmElement* e, GmMatrix& dgss, const GmVector& s, const GmVector* coord, int ip, unsigned sc, bool ips) const;
99 
101  virtual double yieldStrengthRatio(const GmElement* e, const GmVector& S, const GmVector* coord, int ip, unsigned sc) const;
102 
103 };
104 
105 #endif
Definition: gmpMaterialDruckerPrager.h:35
virtual ~GmpMaterialDruckerPrager()
Virtual destructor.
Definition: gmpMaterialDruckerPrager.h:56
The number of property ids above.
Definition: gmpMaterialElastoplastic.h:79
virtual bool alternativeReturnAlgorithm(const GmElement *, GmMatrix &, const GmpMechanicPoint *, const GmVector *, unsigned, bool) const
Returns the updated stresses using an alternative return mapping algorithm.
Definition: gmpMaterialElastoplastic.cpp:551
ElementPropertyIds
IDs for material element properties.
Definition: gmpMaterialDruckerPrager.h:39
The number of property ids above.
Definition: gmpMaterialDruckerPrager.h:46
Definition: gmpMechanicPoint.h:32
virtual bool isIsotropic() const
Returns true if the material is isotropic, false otherwise.
Definition: gmpMaterialDruckerPrager.h:72
Declaration of the gmpMaterialElastoplastic classes.
virtual double dilationAngle(const GmElement *e, const GmVector *coord, int ip) const
Returns the material dilation angle.
Definition: gmpMaterialDruckerPrager.h:85
virtual double yieldStrengthRatio(const GmElement *e, const GmVector &S, const GmVector *coord, int ip, unsigned sc) const =0
Returns the Yield Strength Ratio (Ysr)
Declaration of the GmpMechanicPoint class.
Id for retrieving the friction angle accessor.
Definition: gmpMaterialDruckerPrager.h:42
GmpMaterialDruckerPrager(int typeIndex, QString typeName, const GmLogCategory &logger)
Constructor. Gets as parameters the material index and its name.
Definition: gmpMaterialDruckerPrager.h:52
arma::vec GmVector
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: gmpMaterialDruckerPrager.h:59
Definition: gmpMaterialElastoplastic.h:35
arma::mat GmMatrix
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
Id for retrieving the dilatance angle accessor.
Definition: gmpMaterialDruckerPrager.h:43