OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
tutorialmaterial.h
Go to the documentation of this file.
1 /*
2  *
3  * ##### ##### ###### ###### ### ###
4  * ## ## ## ## ## ## ## ### ##
5  * ## ## ## ## #### #### ## # ##
6  * ## ## ## ## ## ## ## ##
7  * ## ## ## ## ## ## ## ##
8  * ##### ##### ## ###### ## ##
9  *
10  *
11  * OOFEM : Object Oriented Finite Element Code
12  *
13  * Copyright (C) 1993 - 2013 Borek Patzak
14  *
15  *
16  *
17  * Czech Technical University, Faculty of Civil Engineering,
18  * Department of Structural Mechanics, 166 29 Prague, Czech Republic
19  *
20  * This library is free software; you can redistribute it and/or
21  * modify it under the terms of the GNU Lesser General Public
22  * License as published by the Free Software Foundation; either
23  * version 2.1 of the License, or (at your option) any later version.
24  *
25  * This program is distributed in the hope that it will be useful,
26  * but WITHOUT ANY WARRANTY; without even the implied warranty of
27  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
28  * Lesser General Public License for more details.
29  *
30  * You should have received a copy of the GNU Lesser General Public
31  * License along with this library; if not, write to the Free Software
32  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
33  */
34 
35 #ifndef tutorialmaterial_h
36 #define tutorialmaterial_h
37 
39 #include "Materials/structuralms.h"
41 
43 
44 #define _IFT_TutorialMaterial_Name "tutorialmaterial"
45 #define _IFT_TutorialMaterial_yieldstress "sigy"
46 #define _IFT_TutorialMaterial_hardeningmoduli "h"
47 
48 
49 namespace oofem {
50 class Domain;
51 
57 {
58 protected:
60  double H;
61 
63  double sig0;
64 
66 
67 public:
68  TutorialMaterial(int n, Domain * d);
69  virtual ~TutorialMaterial();
70 
72  virtual void giveInputRecord(DynamicInputRecord &ir);
73  virtual const char *giveInputRecordName() const { return _IFT_TutorialMaterial_Name; }
74  virtual const char *giveClassName() const { return "TutorialMaterial"; }
75  virtual bool isCharacteristicMtrxSymmetric(MatResponseMode rMode) { return true; }
76 
77  virtual MaterialStatus *CreateStatus(GaussPoint *gp) const;
78  // stress computation methods
79  virtual void giveRealStressVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedE, TimeStep *tStep);
80 
81  virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep);
82 
83  virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep);
84 
85  virtual void giveThermalDilatationVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep);
86 
87 protected:
88  static void giveDeviatoricProjectionMatrix(FloatMatrix &answer);
89 
90  static void computeSphDevPartOf(const FloatArray &sigV, FloatArray &sigSph, FloatArray &sigDev);
91 };
92 
93 
94 
96 {
97 protected:
100 
103 
105 
106  double tempK;
107  double k;
108 
109 public:
110  TutorialMaterialStatus(int n, Domain * d, GaussPoint * g);
112 
113  const FloatArray &givePlasticStrain() { return plasticStrain; }
114 
115  void letTempPlasticStrainBe(const FloatArray &values) { tempPlasticStrain = values; }
116 
117  double giveK() { return this->k; }
118 
119  void letTempKBe(double value) { tempK = value; }
120 
121  void letTempDevTrialStressBe(const FloatArray &values) { tempDevTrialStress = values; }
122  const FloatArray &giveTempDevTrialStress() { return tempDevTrialStress; }
123 
124  virtual const char *giveClassName() const { return "TutorialMaterialStatus"; }
125 
126  virtual void initTempStatus();
127 
128  virtual void updateYourself(TimeStep *tStep);
129 
130  // semi optional methods
131  //virtual void printOutputAt(FILE *file, TimeStep *tStep);
132 
133  //virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj = NULL);
134  //virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj = NULL);
135 };
136 
137 } // end namespace oofem
138 #endif // tutorialmaterial_h
const FloatArray & giveTempDevTrialStress()
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
This class implements a isotropic plastic linear material (J2 plasticity condition is used)...
Class and object Domain.
Definition: domain.h:115
static void computeSphDevPartOf(const FloatArray &sigV, FloatArray &sigSph, FloatArray &sigDev)
This class implements a structural material status information.
Definition: structuralms.h:65
const FloatArray & givePlasticStrain()
double sig0
Initial (uniaxial) yield stress.
TutorialMaterial(int n, Domain *d)
MatResponseMode
Describes the character of characteristic material matrix.
virtual const char * giveInputRecordName() const
virtual const char * giveClassName() const
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
FloatArray tempPlasticStrain
Temporary plastic strain (the given iteration)
virtual void giveRealStressVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedE, TimeStep *tStep)
Default implementation relies on giveRealStressVector for second Piola-Kirchoff stress.
virtual MaterialStatus * CreateStatus(GaussPoint *gp) const
Creates new copy of associated status and inserts it into given integration point.
This class implements an isotropic linear elastic material in a finite element problem.
FloatArray plasticStrain
Last equilibriated plastic strain (end of last time step)
void letTempDevTrialStressBe(const FloatArray &values)
virtual void giveThermalDilatationVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep)
Returns a vector of coefficients of thermal dilatation in direction of each material principal (local...
void letTempPlasticStrainBe(const FloatArray &values)
static void giveDeviatoricProjectionMatrix(FloatMatrix &answer)
Abstract base class representing a material status information.
Definition: matstatus.h:84
Class representing vector of real numbers.
Definition: floatarray.h:82
virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep)
Computes full 3d material stiffness matrix at given integration point, time, respecting load history ...
#define _IFT_TutorialMaterial_Name
Implementation of matrix containing floating point numbers.
Definition: floatmatrix.h:94
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
Class representing the general Input Record.
Definition: inputrecord.h:101
virtual void giveInputRecord(DynamicInputRecord &ir)
Setups the input record string of receiver.
Class representing the a dynamic Input Record.
IsotropicLinearElasticMaterial D
Abstract base class for all "structural" constitutive models.
the oofem namespace is to define a context or scope in which all oofem names are defined.
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
virtual void initTempStatus(GaussPoint *gp)
Initializes temporary variables stored in integration point status at the beginning of new time step...
Definition: material.C:267
virtual bool isCharacteristicMtrxSymmetric(MatResponseMode rMode)
Returns true if stiffness matrix of receiver is symmetric Default implementation returns true...
Class representing integration point in finite element program.
Definition: gausspoint.h:93
double H
Hardening modulus.
Class representing solution step.
Definition: timestep.h:80
virtual const char * giveClassName() const

This page is part of the OOFEM documentation. Copyright (c) 2011 Borek Patzak
Project e-mail: info@oofem.org
Generated at Tue Jan 2 2018 20:07:32 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011