XC Open source finite element analysis program
FVector.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 //FVector.h
28 
29 #ifndef FVector_h
30 #define FVector_h
31 
32 #include <iostream>
33 #include <cstddef>
34 
35 namespace XC {
36 class Vector;
37 
39 //
41 //
44 class FVector
45  {
46  public:
47  virtual const double &operator[](size_t i) const= 0;
48  virtual double &operator[](size_t i)= 0;
49  virtual void zero(void)= 0;
50  virtual size_t size(void) const
51  { return 0; }
52  virtual double *getPtr(void)
53  { return nullptr; }
54  virtual void Print(std::ostream &os) const= 0;
55  virtual ~FVector(void)
56  {}
57 
58  virtual void addForce(const size_t &inod,const double &,const double &,const double &);
59  virtual void addMoment(const size_t &inod,const double &,const double &,const double &);
60  };
61 
62 std::ostream &operator<<(std::ostream &,const FVector &f);
63 
64 } // end of XC namespace
65 
66 #endif
67 
68 
Element internal forces.
Definition: FVector.h:44
virtual void addMoment(const size_t &inod, const double &, const double &, const double &)
Adds the bending moment being passed as parameter.
Definition: FVector.cc:38
virtual void addForce(const size_t &inod, const double &, const double &, const double &)
Adds the force being passed as parameter.
Definition: FVector.cc:32
================================================================================
Definition: ContinuaReprComponent.h:34