xc
Kratzig.h
1 // -*-c++-*-
2 //----------------------------------------------------------------------------
3 // XC program; finite element analysis code
4 // for structural analysis and design.
5 //
6 // Copyright (C) Luis C. Pérez Tato
7 //
8 // This program derives from OpenSees <http://opensees.berkeley.edu>
9 // developed by the «Pacific earthquake engineering research center».
10 //
11 // Except for the restrictions that may arise from the copyright
12 // of the original program (see copyright_opensees.txt)
13 // XC is free software: you can redistribute it and/or modify
14 // it under the terms of the GNU General Public License as published by
15 // the Free Software Foundation, either version 3 of the License, or
16 // (at your option) any later version.
17 //
18 // This software is distributed in the hope that it will be useful, but
19 // WITHOUT ANY WARRANTY; without even the implied warranty of
20 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 // GNU General Public License for more details.
22 //
23 //
24 // You should have received a copy of the GNU General Public License
25 // along with this program.
26 // If not, see <http://www.gnu.org/licenses/>.
27 //----------------------------------------------------------------------------
28 
29 /* ****************************************************************** **
30 ** OpenSees - Open System for Earthquake Engineering Simulation **
31 ** Pacific Earthquake Engineering Research Center **
32 ** **
33 ** **
34 ** (C) Copyright 1999, The Regents of the University of California **
35 ** All Rights Reserved. **
36 ** **
37 ** Commercial use of this program without express permission of the **
38 ** University of California, Berkeley, is strictly prohibited. See **
39 ** file 'COPYRIGHT' in main directory for information on usage and **
40 ** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. **
41 ** **
42 ** Developed by: **
43 ** Frank McKenna (fmckenna@ce.berkeley.edu) **
44 ** Gregory L. Fenves (fenves@ce.berkeley.edu) **
45 ** Filip C. Filippou (filippou@ce.berkeley.edu) **
46 ** **
47 ** ****************************************************************** */
48 
49 
50 
51 // $Revision: 1.1 $
52 // $Date: 2004/09/01 03:54:28 $
53 // $Source: /usr/local/cvs/OpenSees/SRC/damage/Kratzig.h,v $
54 
55 #ifndef Kratzig_h
56 #define Kratzig_h
57 
58 // Written: AA,GGD
59 // Created: 08/02
60 // Revision: AA
61 //
62 // Description: This file contains the class definition for
63 // Damage. Damage is a base class and
64 // thus no objects of it's type can be instantiated. It has pure virtual
65 // functions which must be implemented in it's derived classes.
66 
67 
68 #include <material/damage/DamageModel.h>
69 
70 namespace XC {
71 class DamageResponse;
72 
74 //
85 class Kratzig: public DamageModel
86  {
87  public:
88  Kratzig(int tag, double ultimatePosVal , double ultimateNegVal);
89  Kratzig(void);
90 
91  int setTrial(const Vector &trialVector );
92  int setTrial(void) { return -1; }
93 
94  int setInputResponse(Element *elem , const std::vector<std::string> & , int ndof );
95 
96  double getDamage(void);
97  double getPosDamage (void);
98  double getNegDamage (void);
99 
100  int commitState(void);
101  int revertToLastCommit (void);
102  int revertToStart (void);
103 
104  DamageModel *getCopy(void) const;
105 
106  int setVariable(const std::string &argv);
107  int getVariable(int variableID, double &info);
108 
109  int setParameter(const std::vector<std::string> &argv, Information &eleInformation);
110  int updateParameter(int responseID, Information &eleInformation);
111 
112  Response *setResponse(const std::vector<std::string> &argv, Information &);
113  int getResponse(int responseID, Information &info);
114 
115  int sendSelf(Communicator &);
116  int recvSelf(const Communicator &);
117  void Print(std::ostream &s, int flag =0) const;
118 
119  // method for this damage model to update itself according to its new parameters
120  void update(void) {return;}
121  private:
122 
123  // Model parameters
124  double UltimatePosValue , UltimateNegValue;
125 
126  double TrialInfo[10];
127  double CommitInfo[10];
128  double LastCommitInfo[10];
129 
130 };
131 } // end of XC namespace
132 
133 
134 #endif
Float vector abstraction.
Definition: Vector.h:94
Information about an element.
Definition: Information.h:81
Communication parameters between processes.
Definition: Communicator.h:66
Base class response objects.
Definition: Response.h:81
int getVariable(int variableID, double &info)
Returns the value of the variable cuyo identifier being passed as parameter.
Definition: Kratzig.cpp:302
Base class for the finite elements.
Definition: Element.h:112
int sendSelf(Communicator &)
Send the object.
Definition: Kratzig.cpp:365
Kratzig damage model.
Definition: Kratzig.h:85
void Print(std::ostream &s, int flag=0) const
Print stuff.
Definition: Kratzig.cpp:374
int recvSelf(const Communicator &)
Receive the object.
Definition: Kratzig.cpp:369
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
int setVariable(const std::string &argv)
Returns the identifier of the variable cuyo name being passed as parameter.
Definition: Kratzig.cpp:297
DamageModel * getCopy(void) const
Virtual constructor.
Definition: Kratzig.cpp:281
Base class for damage models.
Definition: DamageModel.h:107
int updateParameter(int responseID, Information &eleInformation)
Updates the parameter identified by parameterID with info.
Definition: Kratzig.cpp:311