OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
material.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 material_h
36 #define material_h
37 
38 #include "femcmpnn.h"
39 
40 #include "matconst.h"
41 #include "matstatus.h"
42 #include "materialmode.h"
43 #include "timestep.h"
44 #include "internalstatetype.h"
45 #include "internalstatevaluetype.h"
46 #include "matresponsemode.h"
47 #include "dictionary.h"
48 
50 
51 #define _IFT_Material_density "d"
52 #define _IFT_Material_castingtime "castingtime"
53 
54 
55 namespace oofem {
56 #define STRAIN_STEPS 10.0
57 
58 class GaussPoint;
59 class Dictionary;
60 class FloatArray;
61 class FloatMatrix;
62 class Element;
63 class ProcessCommunicator;
64 
95 class OOFEM_EXPORT Material : public FEMComponent
96 {
97 protected:
106 
113  double castingTime;
114 
115 public:
121  Material(int n, Domain *d);
123  virtual ~Material();
124 
129  virtual bool isCharacteristicMtrxSymmetric(MatResponseMode rMode) { return true; }
138  virtual double give(int aProperty, GaussPoint *gp);
145  virtual bool hasProperty(int aProperty, GaussPoint *gp);
152  virtual void modifyProperty(int aProperty, double value, GaussPoint *gp);
156  double giveCastingTime() { return this->castingTime; }
161  virtual bool isActivated(TimeStep *tStep) {
162  if ( tStep ) {
163  return ( tStep->giveIntrinsicTime() >= this->castingTime );
164  } else {
165  return true;
166  }
167  }
168 
169  // identification and auxiliary functions
173  virtual int hasNonLinearBehaviour() { return 0; }
174 
180  virtual int hasMaterialModeCapability(MaterialMode mode);
181 
182 
187  virtual int hasCastingTimeSupport();
188 
189 
191 
192 
200  virtual int setIPValue(const FloatArray &value, GaussPoint *gp, InternalStateType type)
201  { return 0; }
210  virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep);
212 
213  virtual IRResultType initializeFrom(InputRecord *ir);
214  virtual void giveInputRecord(DynamicInputRecord &input);
215  virtual void printYourself();
216 
225  virtual contextIOResultType saveIPContext(DataStream &stream, ContextMode mode, GaussPoint *gp);
234  virtual contextIOResultType restoreIPContext(DataStream &stream, ContextMode mode, GaussPoint *gp);
235 
243  virtual int checkConsistency();
244 
245 
252  virtual int initMaterial(Element *element);
260  virtual MaterialStatus *giveStatus(GaussPoint *gp) const;
261  /*
262  * In the case of nonlocal constitutive models,
263  * the use of multiple inheritance is assumed. Typically, the class representing nonlocal
264  * constitutive model is derived both from class representing local model and from class
265  * NonlocalMaterialExtension or from one of its derived classes
266  * (which declare services and variables corresponding to specific analysis type).
267  * Or alternatively, material model can introduce stronger form of this relation,
268  * it can possess object of NonlocalMaterialExtension.
269  * @return In both cases, this function returns pointer to this object, obtained by
270  * returning address of component or using pointer conversion from receiver to base class
271  * NonlocalMaterialExtension. If no nonlocal extension exists, NULL pointer is returned.
272  */
273  //virtual NonlocalMaterialExtension* giveNonlocalMaterialExtensionPtr () {return NULL;}
274 
285  virtual int packUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip) { return 1; }
294  virtual int unpackAndUpdateUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip) { return 1; }
298  virtual int estimatePackSize(DataStream &buff, GaussPoint *ip) { return 0; }
304  virtual double predictRelativeComputationalCost(GaussPoint *gp) { return 1.0; }
308  virtual double predictRelativeRedistributionCost(GaussPoint *gp) { return 1.0; }
309 
310 
317  { return NULL; }
318 
328  virtual void initTempStatus(GaussPoint *gp);
329 };
330 } // end namespace oofem
331 #endif // material_h
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
virtual int setIPValue(const FloatArray &value, GaussPoint *gp, InternalStateType type)
Sets the value of a certain variable at a given integration point to the given value.
Definition: material.h:200
Class and object Domain.
Definition: domain.h:115
virtual int hasNonLinearBehaviour()
Returns nonzero if receiver is non linear.
Definition: material.h:173
virtual int packUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip)
Pack all necessary data of integration point (according to element parallel_mode) into given communic...
Definition: material.h:285
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
Definition: datastream.h:54
Defines several material constant (respective their representative number).
double giveCastingTime()
Definition: material.h:156
virtual double predictRelativeRedistributionCost(GaussPoint *gp)
Returns the relative redistribution cost of the receiver.
Definition: material.h:308
Dictionary propertyDictionary
Property dictionary.
Definition: material.h:105
Abstract base class for all finite elements.
Definition: element.h:145
MaterialMode
Type representing material mode of integration point.
Definition: materialmode.h:89
MatResponseMode
Describes the character of characteristic material matrix.
virtual bool isCharacteristicMtrxSymmetric(MatResponseMode rMode)
Returns true if stiffness matrix of receiver is symmetric Default implementation returns true...
Definition: material.h:129
virtual double predictRelativeComputationalCost(GaussPoint *gp)
Returns the weight representing relative computational cost of receiver The reference material model ...
Definition: material.h:304
Abstract base class for all material models.
Definition: material.h:95
double giveIntrinsicTime()
Returns intrinsic time, e.g. time in which constitutive model is evaluated.
Definition: timestep.h:148
Abstract base class representing a material status information.
Definition: matstatus.h:84
This class implements a linked list whose entries are Pairs (see below).
Definition: dictionary.h:58
Class representing vector of real numbers.
Definition: floatarray.h:82
IRResultType
Type defining the return values of InputRecord reading operations.
Definition: irresulttype.h:47
Class representing the general Input Record.
Definition: inputrecord.h:101
Class representing the a dynamic Input Record.
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
Definition: contextmode.h:43
virtual bool isActivated(TimeStep *tStep)
Definition: material.h:161
virtual int estimatePackSize(DataStream &buff, GaussPoint *ip)
Estimates the necessary pack size to hold all packed data of receiver.
Definition: material.h:298
double castingTime
Casting time.
Definition: material.h:113
the oofem namespace is to define a context or scope in which all oofem names are defined.
virtual int unpackAndUpdateUnknowns(DataStream &buff, TimeStep *tStep, GaussPoint *ip)
Unpack and updates all necessary data of given integration point (according to element parallel_mode)...
Definition: material.h:294
Class representing integration point in finite element program.
Definition: gausspoint.h:93
Class representing solution step.
Definition: timestep.h:80
The top abstract class of all classes constituting the finite element mesh.
Definition: femcmpnn.h:76
virtual MaterialStatus * CreateStatus(GaussPoint *gp) const
Creates new copy of associated status and inserts it into given integration point.
Definition: material.h:316

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:29 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011