xc
CreepShrinkageStateBase.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 #ifndef CreepShrinkageStateBase_h
30 #define CreepShrinkageStateBase_h
31 
32 #include "utility/kernel/CommandEntity.h"
33 #include "utility/actor/actor/MovableObject.h"
34 namespace XC {
35 
36 
41  {
42  protected:
43 
44  double age;
45  double tcast;
46  //Added by AMK:
47  double epsInit;
48  double sigInit;
49 
50  double eps_m;
51  double epsP_m;
52 
53  double eps_total;
54  double epsP_total;
55 
56  double t;
57  double t_load;
58  double Et;
59 
60  int crack_flag;
61  int crackP_flag;
62 
63  void commit_eps_and_sig_init(const int &count, const double &hstvP_sig, const double &currentTime);
64  int sendData(Communicator &);
65  int recvData(const Communicator &);
66  public:
68  CreepShrinkageStateBase(const double &_age, const double &_tcast, const double &_Et);
69  void setup_parameters(const double &);
70 
71  void set_eps_m_total(const double &_eps_m, const double &_eps_total)
72  {
73  this->eps_m= _eps_m; // Mechanical strain.
74  this->eps_total= eps_total; // Total strain.
75  }
76  double get_total_strain(void) const
77  { return this->eps_total; }
78  void set_total_strain(const double &d)
79  { this->eps_total= d; }
80  double getStrain(void) const // Added by AMK
81  { return eps_total; }
82 
83  double getMech(void) const // Added by AMK
84  { return eps_m; }
85 
87  void setEt(const double &d)
88  { Et= d; }
89 
91  double getEt(void) const
92  { return Et; }
93 
95  void setAge(const double &d)
96  { this->age= d; }
98  double getAge(void) const
99  { return this->age; }
100 
102  void setTCast(const double &d)
103  { tcast= d; }
105  double getTCast(void) const
106  { return tcast; }
107 
108  double getCastingAge(const double &t) const
109  { return t-this->tcast; }
110 
111  void setCrackFlag(const int &i)
112  { crack_flag= i; }
113  int getCrackFlag(void) const
114  { return crack_flag; }
115  void revertCrackFlag(void)
116  { crack_flag = crackP_flag; }
117 
118  int commit_state(const int &count, const double &hstvP_sig, const double &currentTime);
119  int revert_to_last_commit(void);
120  int revert_to_start(const double &_Et);
121 
122  int sendSelf(Communicator &);
123  int recvSelf(const Communicator &);
124 
125  void Print(std::ostream &s, int flag =0) const;
126 
127  };
128 } // end of XC namespace
129 
130 
131 #endif
132 
void setAge(const double &d)
Assign the concrete age at first loading.
Definition: CreepShrinkageStateBase.h:95
int sendData(Communicator &)
Send object members through the communicator argument.
Definition: CreepShrinkageStateBase.cc:148
double t_load
Loaded time.
Definition: CreepShrinkageStateBase.h:57
Communication parameters between processes.
Definition: Communicator.h:66
int recvData(const Communicator &)
Receives object members through the communicator argument.
Definition: CreepShrinkageStateBase.cc:156
Object that can move between processes.
Definition: MovableObject.h:100
double age
concrete age at first loading, Added by AMK
Definition: CreepShrinkageStateBase.h:44
double t
Time.
Definition: CreepShrinkageStateBase.h:56
double epsP_total
Commited total strain.
Definition: CreepShrinkageStateBase.h:54
Base class that groups the variables that keep track of the creep and shrinkage strains.
Definition: CreepShrinkageStateBase.h:40
double getAge(void) const
Return the concrete age at first loading.
Definition: CreepShrinkageStateBase.h:98
double getTCast(void) const
Return the analysis time corresponding to concrete casting in days.
Definition: CreepShrinkageStateBase.h:105
void setTCast(const double &d)
Assign the analysis time corresponding to concrete casting in days.
Definition: CreepShrinkageStateBase.h:102
void setup_parameters(const double &)
Sets initial values for the concrete parameters.
Definition: CreepShrinkageStateBase.cc:71
double tcast
the analysis time corresponding to concrete casting in days.
Definition: CreepShrinkageStateBase.h:45
Objet that can execute python scripts.
Definition: CommandEntity.h:40
void setEt(const double &d)
Assign current concrete stiffness.
Definition: CreepShrinkageStateBase.h:87
double Et
Stiffness at time t.
Definition: CreepShrinkageStateBase.h:58
double eps_total
Total strain.
Definition: CreepShrinkageStateBase.h:53
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
int sendSelf(Communicator &)
Sends object through the communicator argument.
Definition: CreepShrinkageStateBase.cc:165
double eps_m
Mechanical strain.
Definition: CreepShrinkageStateBase.h:50
double epsP_m
Commited mechanical strain.
Definition: CreepShrinkageStateBase.h:51
int recvSelf(const Communicator &)
Receives object through the communicator argument.
Definition: CreepShrinkageStateBase.cc:181
double getEt(void) const
Returns current concrete stiffness.
Definition: CreepShrinkageStateBase.h:91