xc
FiberData.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 //FiberData.h
28 
29 #ifndef FiberData_h
30 #define FiberData_h
31 
32 #include <vector>
33 #include <utility/matrix/Vector.h>
34 #include <utility/matrix/Matrix.h>
35 #include <material/section/repres/section/fiber_list.h>
36 
37 namespace XC {
38 
39 class Material;
40 class VectorCells;
41 class VectorReinfBar;
42 class RegionContainer;
43 class ListReinfLayer;
44  class GeomSection;
45 
47 //
49 class FiberData
50  {
51  std::vector<Material *> fibersMaterial;
52  Matrix fibersPosition;
53  Vector fibersArea;
54  size_t put_cells(const size_t &,const VectorCells &,Material *);
55  size_t put_reinf_bars(const size_t &,const VectorReinfBar &,Material *);
56 
57  inline Material *getPtrMaterial(const int &i) const
58  { return fibersMaterial[i]; }
59  inline const double &Position(const int &i,const int &j) const
60  { return fibersPosition(i,j); }
61  inline double &Position(const int &i,const int &j)
62  { return fibersPosition(i,j); }
64  inline const double &Area(const int &i) const
65  { return fibersArea(i); }
67  inline double &Area(const int &i)
68  { return fibersArea(i); }
69 
70  public:
71  FiberData(const int &sz);
72  FiberData(const GeomSection &);
73 
74  inline void setPtrMaterial(const int &i,Material *mat)
75  { fibersMaterial[i]= mat; }
76 
77  inline size_t size(void) const
78  { return fibersArea.Size(); }
79 
80  size_t PutCells(const size_t &,const RegionContainer &);
81  size_t putReinforcementLayers(const size_t &,const ListReinfLayer &);
82  void get2DFibers(fiber_list &) const;
83  void get3DFibers(fiber_list &) const;
84  };
85 
86 } // end of XC namespace
87 #endif
88 
Cross section geometry.
Definition: GeomSection.h:63
Float vector abstraction.
Definition: Vector.h:93
void get3DFibers(fiber_list &) const
Populates the fiber container with UniaxialFiber3d objects.
Definition: FiberData.cc:173
Fiber data.
Definition: FiberData.h:49
Section composed of some regions.
Definition: RegionContainer.h:52
Base class for materials.
Definition: Material.h:91
std::list< Fiber * > fiber_list
fiber list.
Definition: fiber_list.h:36
size_t putReinforcementLayers(const size_t &, const ListReinfLayer &)
Coloca las barras de la lista being passed as parameter.
Definition: FiberData.cc:113
int Size(void) const
Returns the size of the Vector.
Definition: Vector.h:228
Reinforcement bars vector.
Definition: VectorReinfBar.h:47
void get2DFibers(fiber_list &) const
Populates the fiber container with UniaxialFiber2d objects.
Definition: FiberData.cc:128
Reinf layer container (list).
Definition: ListReinfLayer.h:53
FiberData(const int &sz)
Constructor.
Definition: FiberData.cc:45
Cells vector.
Definition: VectorCells.h:42
Open source finite element program for structural analysis.
Definition: ContinuaReprComponent.h:34
Matrix of floats.
Definition: Matrix.h:108
size_t PutCells(const size_t &, const RegionContainer &)
Put the cells of the regions being passed as parameters.
Definition: FiberData.cc:99