XC Open source finite element analysis program
Cad.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 //Cad.h
28 
29 #ifndef CAD_H
30 #define CAD_H
31 
32 #include "xc_utils/src/nucleo/EntCmd.h"
33 #include <map>
34 #include "boost/lexical_cast.hpp"
35 #include "preprocessor/cad/entidades/MapPuntos.h"
36 #include "preprocessor/cad/entidades/MapLineas.h"
37 #include "preprocessor/cad/entidades/MapSurfaces.h"
38 #include "preprocessor/cad/entidades/MapCuerpos.h"
39 #include "preprocessor/cad/entidades/MapUniformGrids.h"
40 #include "preprocessor/cad/trf/MapTrfGeom.h"
41 #include "preprocessor/cad/MapSisRef.h"
42 #include "preprocessor/cad/matrices/MapEsquemas2d.h"
43 #include "preprocessor/cad/matrices/MapEsquemas3d.h"
44 
45 class Pos3d;
46 class Recta3d;
47 class Plano3d;
48 class Vector3d;
49 
50 namespace XC {
51 
52 class Preprocessor;
53 class Pnt;
54 class UniformGrid;
55 class SetEstruct;
56 class SisRef;
57 
59 //
61 //
63 //
69 class Cad: public EntCmd
70  {
71  private:
72  Preprocessor *preprocessor;
73 
74  template <class L>
75  static void numera_lista(L &l);
76  void numera(void);
77  private:
78  MapSisRef reference_systems;
79  MapTrfGeom transformaciones_geometricas;
80 
81  MapPuntos puntos;
82  MapLineas edges;
83  MapSurfaces faces;
84  MapCuerpos cuerpos;
85  MapUniformGrids unif_grid;
86  MapEsquemas2d esquemas2d;
87  MapEsquemas3d esquemas3d;
88 
89  protected:
90 
91  friend class Preprocessor;
92  SetEstruct *busca_set_estruct(const MapUniformGrids::Indice &nmb);
93  public:
95  Cad(Preprocessor *mod= nullptr);
96  inline Preprocessor *getPreprocessor(void)
97  { return preprocessor; }
98  inline const Preprocessor *getPreprocessor(void) const
99  { return preprocessor; }
100 
101  Edge *busca_edge_extremos(const MapPuntos::Indice &,const MapPuntos::Indice &);
102  const Edge *busca_edge_extremos(const MapPuntos::Indice &,const MapPuntos::Indice &) const;
103 
104  void conciliaNDivs(void);
105 
106  void clearAll(void);
108  virtual ~Cad(void);
109 
110  inline const MapPuntos &getPuntos(void) const
111  { return puntos; }
112  inline MapPuntos &getPuntos(void)
113  { return puntos; }
114  inline const MapLineas &getLineas(void) const
115  { return edges; }
116  inline MapLineas &getLineas(void)
117  { return edges; }
118  inline const MapSurfaces &getSurfaces(void) const
119  { return faces; }
120  inline MapSurfaces &getSurfaces(void)
121  { return faces; }
122  inline const MapTrfGeom &getTransformacionesGeometricas(void) const
123  { return transformaciones_geometricas; }
124  inline MapTrfGeom &getTransformacionesGeometricas(void)
125  { return transformaciones_geometricas; }
126  inline const MapSisRef &getReferenceSystems(void) const
127  { return reference_systems; }
128  inline MapSisRef &getReferenceSystems(void)
129  { return reference_systems; }
130  inline const MapEsquemas2d &getEsquemas2d(void) const
131  { return esquemas2d; }
132  inline MapEsquemas2d &getEsquemas2d(void)
133  { return esquemas2d; }
134  inline const MapEsquemas3d &getEsquemas3d(void) const
135  { return esquemas3d; }
136  inline MapEsquemas3d &getEsquemas3d(void)
137  { return esquemas3d; }
138  inline const MapUniformGrids &getUniformGrids(void) const
139  { return unif_grid; }
140  inline MapUniformGrids &getUniformGrids(void)
141  { return unif_grid; }
142  };
143 
144 
145 } //end of XC namespace
146 #endif
void conciliaNDivs(void)
Conciliate number of divisions of the lines.
Definition: Cad.cc:123
Contenedor de puntos del modelo.
Definition: MapLineas.h:49
Base class for one-dimensional geometry objects.
Definition: Edge.h:46
Body contaainer.
Definition: MapCuerpos.h:40
Point container.
Definition: MapPuntos.h:51
Uniform grid container.
Definition: MapUniformGrids.h:44
virtual ~Cad(void)
Destructor.
Definition: Cad.cc:181
Three dimensional scheme container.
Definition: MapEsquemas3d.h:42
Finite element model generation tools.
Definition: Preprocessor.h:58
structured set, i. e. a set that can return a pointer a to a node or an element from its indices i...
Definition: SetEstruct.h:45
Contenedor de puntos del modelo.
Definition: MapSurfaces.h:41
Model geometry manager. Management of geometry entities: points, lines, surfaces, bodies...
Definition: Cad.h:69
Cad(Preprocessor *mod=nullptr)
Constructor.
Definition: Cad.cc:60
Reference systems container.
Definition: MapSisRef.h:42
void clearAll(void)
Erase all the geometry entities.
Definition: Cad.cc:167
SetEstruct * busca_set_estruct(const MapUniformGrids::Indice &nmb)
Search for the entity whose name is passed as a parameter.
Definition: Cad.cc:158
Bidimensional scheme container.
Definition: MapEsquemas2d.h:42
Contenedor de puntos del modelo.
Definition: MapTrfGeom.h:42
Edge * busca_edge_extremos(const MapPuntos::Indice &, const MapPuntos::Indice &)
Return the «edge» that has as end points those whose indices are passed as parameters.
Definition: Cad.cc:78
================================================================================
Definition: ContinuaReprComponent.h:34