XC Open source finite element analysis program
Material.h
1 //----------------------------------------------------------------------------
2 // XC program; finite element analysis code
3 // for structural analysis and design.
4 //
5 // Copyright (C) Luis Claudio Pérez Tato
6 //
7 // This program derives from OpenSees <http://opensees.berkeley.edu>
8 // developed by the «Pacific earthquake engineering research center».
9 //
10 // Except for the restrictions that may arise from the copyright
11 // of the original program (see copyright_opensees.txt)
12 // XC is free software: you can redistribute it and/or modify
13 // it under the terms of the GNU General Public License as published by
14 // the Free Software Foundation, either version 3 of the License, or
15 // (at your option) any later version.
16 //
17 // This software is distributed in the hope that it will be useful, but
18 // WITHOUT ANY WARRANTY; without even the implied warranty of
19 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 // GNU General Public License for more details.
21 //
22 //
23 // You should have received a copy of the GNU General Public License
24 // along with this program.
25 // If not, see <http://www.gnu.org/licenses/>.
26 //----------------------------------------------------------------------------
27 /* ****************************************************************** **
28 ** OpenSees - Open System for Earthquake Engineering Simulation **
29 ** Pacific Earthquake Engineering Research Center **
30 ** **
31 ** **
32 ** (C) Copyright 1999, The Regents of the University of California **
33 ** All Rights Reserved. **
34 ** **
35 ** Commercial use of this program without express permission of the **
36 ** University of California, Berkeley, is strictly prohibited. See **
37 ** file 'COPYRIGHT' in main directory for information on usage and **
38 ** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. **
39 ** **
40 ** Developed by: **
41 ** Frank McKenna (fmckenna@ce.berkeley.edu) **
42 ** Gregory L. Fenves (fenves@ce.berkeley.edu) **
43 ** Filip C. Filippou (filippou@ce.berkeley.edu) **
44 ** **
45 ** ****************************************************************** */
46 
47 // $Revision: 1.3 $
48 // $Date: 2003/02/25 23:33:21 $
49 // $Source: /usr/local/cvs/OpenSees/SRC/material/Material.h,v $
50 
51 
52 #ifndef Material_h
53 #define Material_h
54 
55 // File: Material.h
56 //
57 // Written: fmk
58 // Created: 05/98
59 // Revision: A
60 //
61 // Description: This file contains the class definition for Material.
62 // Material is an abstract base class and thus no objects of it's type
63 // can be instantiated. It has pure virtual functions which must be
64 // implemented in it's derived classes.
65 //
66 // What: "@(#) Material.h, revA"
67 
68 #include "utility/tagged/TaggedObject.h"
69 #include "utility/actor/actor/MovableObject.h"
70 #include "utility/actor/objectBroker/FEM_ObjectBroker.h"
71 #include "utility/matrix/ID.h"
72 #include "utility/actor/actor/BrokedPtrCommMetaData.h"
73 
74 namespace XC {
75 class Information;
76 class Response;
77 class MaterialLoader;
78 class ID;
79 
81 
83 //
85 class Material: public TaggedObject, public MovableObject
86  {
87  public:
88  Material(int tag, int classTag);
89 
90  const MaterialLoader *GetMaterialLoader(void) const;
92  std::string getName(void) const;
93 
94  virtual int setVariable(const std::string &argv);
95  virtual int getVariable(int variableID, double &info);
96 
97  // methods for sensitivity studies
98  virtual int setParameter(const std::vector<std::string> &argv, Parameter &param);
99  virtual int updateParameter(int responseID, Information &eleInformation);
100 
101  virtual Response *setResponse(const std::vector<std::string> &argv, Information &eleInformation);
102  virtual int getResponse(int responseID, Information &info);
103 
104  virtual void update(void);
105 
106  virtual const Vector &getGeneralizedStress(void) const= 0;
107  virtual const Vector &getGeneralizedStrain(void) const= 0;
108  virtual const Vector &getInitialGeneralizedStrain(void) const= 0;
109 
110  virtual void setInitialGeneralizedStrain(const Vector &)= 0;
111  virtual void addInitialGeneralizedStrain(const Vector &);
112  virtual void zeroInitialGeneralizedStrain(void);
113 
114  virtual int commitState(void) = 0;
115  virtual int revertToLastCommit(void) = 0;
116  virtual int revertToStart(void) = 0;
117 
118  };
119 
122 
123 } // end of XC namespace
124 
125 
126 #endif
127 
virtual int getResponse(int responseID, Information &info)
Returns material response.
Definition: Material.cpp:112
int sendMaterialPtr(Material *, DbTagData &, CommParameters &cp, const BrokedPtrCommMetaData &)
Sends a pointer to material through the communicator being passed as parameter.
Definition: Material.cpp:139
Base class for materials.
Definition: Material.h:85
Definition: Vector.h:82
Vector que almacena los dbTags de los miembros de la clase.
Definition: DbTagData.h:43
Information about an element.
Definition: Information.h:80
Data to transmit for a pointer «broked».
Definition: BrokedPtrCommMetaData.h:39
Object that can move between processes.
Definition: MovableObject.h:91
std::string getName(void) const
Returns the name of the material.
Definition: Material.cpp:90
virtual void addInitialGeneralizedStrain(const Vector &)
Increments generalized strain.
Definition: Material.cpp:122
const MaterialLoader * GetMaterialLoader(void) const
Returns (if possible) a pointer to the material handler (owner).
Definition: Material.cpp:72
virtual void update(void)
Update state variables for the material according to the new values of the parameters.
Definition: Material.cpp:117
Material * receiveMaterialPtr(Material *, DbTagData &, const CommParameters &cp, const BrokedPtrCommMetaData &)
Receives a pointer to material through the communicator being passed as parameter.
Definition: Material.cpp:156
Object idenfied by an integer (tag).
Definition: TaggedObject.h:82
virtual void zeroInitialGeneralizedStrain(void)
zeroes initial generalized strain
Definition: Material.cpp:128
Material handler (definition, searching,...).
Definition: MaterialLoader.h:45
Definition: Parameter.h:65
Communication parameters between processes.
Definition: CommParameters.h:65
Material(int tag, int classTag)
Constructor.
Definition: Material.cpp:68
================================================================================
Definition: ContinuaReprComponent.h:34
Definition: Response.h:71