XC Open source finite element analysis program
ResponseQuantities.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 //ResponseQuantities.h
28 
29 #ifndef ResponseQuantities_h
30 #define ResponseQuantities_h
31 
32 
33 #include "utility/actor/actor/MovableObject.h"
34 #include "utility/matrix/Vector.h"
35 
36 namespace XC {
37 
39 //
42  {
43  private:
44  Vector R, Rdot, Rdotdot;
45  protected:
46  int sendData(CommParameters &);
47  int recvData(const CommParameters &);
48  public:
49  ResponseQuantities(const int &size= 0);
50 
51  inline const Vector &get(void) const
52  { return R; }
53  inline const Vector &getDot(void) const
54  { return Rdot; }
55  inline const Vector &getDotDot(void) const
56  { return Rdotdot; }
57  inline Vector &get(void)
58  { return R; }
59  inline Vector &getDot(void)
60  { return Rdot; }
61  inline Vector &getDotDot(void)
62  { return Rdotdot; }
63  inline void set(const Vector &v)
64  { R= v; }
65  inline void setDot(const Vector &v)
66  { Rdot= v; }
67  inline void setDotDot(const Vector &v)
68  { Rdotdot= v; }
69 
70  void setDisp(const ID &,const Vector &);
71  void setVel(const ID &,const Vector &);
72  void setAccel(const ID &,const Vector &);
73 
74  void resize(const int &size);
75  void Zero(void);
76 
77  virtual int sendSelf(CommParameters &);
78  virtual int recvSelf(const CommParameters &);
79 
80  void Print(std::ostream &s);
81  };
82 } // end of XC namespace
83 
84 #endif
85 
virtual int recvSelf(const CommParameters &)
Receives object through the channel being passed as parameter.
Definition: ResponseQuantities.cc:119
Definition: Vector.h:82
virtual int sendSelf(CommParameters &)
Sends object through the channel being passed as parameter.
Definition: ResponseQuantities.cc:105
Object that can move between processes.
Definition: MovableObject.h:91
Definition: ID.h:77
int recvData(const CommParameters &)
Receives object members through the channel being passed as parameter.
Definition: ResponseQuantities.cc:95
int sendData(CommParameters &)
Send object members through the channel being passed as parameter.
Definition: ResponseQuantities.cc:85
Communication parameters between processes.
Definition: CommParameters.h:65
Response quantities.
Definition: ResponseQuantities.h:41
================================================================================
Definition: ContinuaReprComponent.h:34