xc
CableMaterial.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.5 $
48 // $Date: 2003/02/25 23:33:37 $: 2001/07/16 08:23:22 $
49 // $Source: /usr/local/cvs/OpenSees/SRC/material/uniaxial/CableMaterial.h,v $
50 
51 
52 #ifndef CableMaterial_h
53 #define CableMaterial_h
54 
55 // Written: Charles Chadwell
56 // Created: 07/01
57 //
58 // Description: This file contains the class definition for
59 // CableMaterial. CableMaterial provides the abstraction
60 // of an elastic uniaxial material,
61 //
62 // The input parameters are the Prestress, E, Effective Self Weight (gravity component of
63 // Weight per volume transverse to the cable), and Length of the cable.
64 //
65 // The cable Force Displacement is converted to Stress Strain material for use
66 // with the truss element. The stress strain ranges from slack (large strain at zero
67 // stress) to taught (linear with modulus E). The material has no history and is not
68 // path dependent.
69 //
70 //
71 // What: "@(#) CableMaterial.h, revA"
72 
73 
74 #include <material/uniaxial/ElasticBaseMaterial.h>
75 
76 namespace XC {
78 //
89  {
90  private:
91  double Ps;
92  double Mue;
93  double L;
94  double trialStress;
95  double trialTangent;
96 
97  double evalStress(double stress);
98  protected:
99  DbTagData &getDbTagData(void) const;
100  int sendData(CommParameters &);
101  int recvData(const CommParameters &);
102 
103  public:
104  CableMaterial(int tag, double Prestress, double E, double unitWeightEff, double L_Element);
105  CableMaterial(int tag= 0);
106 
107  void setLength(const double &);
108  inline double getLength(void) const
109  { return L; }
110  int setTrialStrain(double strain, double strainRate = 0.0);
111  int setTrial(double strain, double &stress, double &tangent, double strainRate = 0.0);
112 
113  inline double getStrain(void) const
114  {return trialStrain;};
115  double getStress(void) const;
116  double getTangent(void) const;
117  inline double getInitialTangent(void) const
118  {return 1.0e-8;};
119 
121  inline void setPrestress(const double &d)
122  { Ps= d; }
124  double getPrestress(void) const
125  { return Ps; }
126 
127  int commitState(void);
128  int revertToLastCommit(void);
129  int revertToStart(void);
130 
131  UniaxialMaterial *getCopy(void) const;
132 
133  int sendSelf(CommParameters &);
134  int recvSelf(const CommParameters &);
135 
136  void Print(std::ostream &s, int flag =0);
137 
138 
139  //int setParameter(const std::vector<std::string> &argv, Parameter &param);
140  //int updateParameter(int parameterID, Information &info);
141  };
142 } // end of XC namespace
143 
144 
145 #endif
146 
double getTangent(void) const
Return the current value of the tangent for the trial strain.
Definition: CableMaterial.cpp:185
int recvSelf(const CommParameters &)
Receives object through the channel being passed as parameter.
Definition: CableMaterial.cpp:244
void setPrestress(const double &d)
Set value of cable prestress.
Definition: CableMaterial.h:121
double getPrestress(void) const
Return value of cable prestress.
Definition: CableMaterial.h:124
DbTagData & getDbTagData(void) const
Returns a vector to store the dbTags of the class members.
Definition: CableMaterial.cpp:206
Base class for uniaxial materials.
Definition: UniaxialMaterial.h:92
double E
Material trial strain.
Definition: ElasticBaseMaterial.h:42
Vector that stores the dbTags of the class members.
Definition: DbTagData.h:43
int sendSelf(CommParameters &)
Sends object through the channel being passed as parameter.
Definition: CableMaterial.cpp:229
int setTrialStrain(double strain, double strainRate=0.0)
Sets the value of the trial strain.
Definition: CableMaterial.cpp:89
UniaxialMaterial * getCopy(void) const
Virtual constructor.
Definition: CableMaterial.cpp:201
CableMaterial provides the abstraction of an elastic uniaxial material, the input parameters are the ...
Definition: CableMaterial.h:88
int recvData(const CommParameters &)
Receives object members through the channel being passed as parameter.
Definition: CableMaterial.cpp:221
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:34
int sendData(CommParameters &)
Send object members through the channel being passed as parameter.
Definition: CableMaterial.cpp:213
Communication parameters between processes.
Definition: CommParameters.h:65
void Print(std::ostream &s, int flag=0)
Print stuff.
Definition: CableMaterial.cpp:263
double getStress(void) const
Return the current value of stress.
Definition: CableMaterial.cpp:166
Base class for uniaxial elastic materials.
Definition: ElasticBaseMaterial.h:38