xc
EnvelopeData.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 EnvelopeData_h
30 #define EnvelopeData_h
31 
32 #include "utility/actor/actor/MovableObject.h"
33 
34 namespace XC {
35 class Vector;
36 class Matrix;
37 
39 //
43  {
44  private:
45  Matrix *data;
46  Vector *currentData;
47  bool first;
48  friend class EnvelopeElementRecorder;
49  friend class EnvelopeNodeRecorder;
50  void alloc(const size_t &);
51  void free(void);
52  protected:
53  int sendData(Communicator &);
54  int receiveData(const Communicator &);
55  public:
56  EnvelopeData(void);
57  ~EnvelopeData(void);
58 
59  inline const Matrix *getData(void) const
60  { return data; }
61  inline Matrix *getData(void)
62  { return data; }
63  inline const Vector *getCurrentData(void) const
64  { return currentData; }
65  inline Vector *getCurrentData(void)
66  { return currentData; }
67  inline const bool &First(void) const
68  { return first; }
69  inline bool &First(void)
70  { return first; }
71 
72  int restart(void);
73 
74  int sendSelf(Communicator &);
75  int recvSelf(const Communicator &);
76  };
77 } // end of XC namespace
78 
79 
80 #endif
Float vector abstraction.
Definition: Vector.h:94
int receiveData(const Communicator &)
Receive the object through the communicator being passed as parameter.
Definition: EnvelopeData.cc:82
Communication parameters between processes.
Definition: Communicator.h:66
Object that can move between processes.
Definition: MovableObject.h:100
int recvSelf(const Communicator &)
Receive the object.
Definition: EnvelopeData.cc:107
Stores the data corresponding to the envelope of a magnitude.
Definition: EnvelopeData.h:42
int sendData(Communicator &)
Send the object through the communicator being passed as parameter.
Definition: EnvelopeData.cc:72
A EnvelopeRecorder is used to record the envelop of specified DOF responses at a collection of nodes ...
Definition: EnvelopeNodeRecorder.h:76
Record the envelope of a magnitude (stress, strain, internal forces,...).
Definition: EnvelopeElementRecorder.h:71
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:35
Matrix of floats.
Definition: Matrix.h:111
int sendSelf(Communicator &)
Send the object.
Definition: EnvelopeData.cc:91
EnvelopeData(void)
Constructor.
Definition: EnvelopeData.cc:34
~EnvelopeData(void)
Destructor.
Definition: EnvelopeData.cc:60