XC Open source finite element analysis program
MEDGroupInfo.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 // XC is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by
9 // the Free Software Foundation, either version 3 of the License, or
10 // (at your option) any later version.
11 //
12 // This software is distributed in the hope that it will be useful, but
13 // WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU General Public License for more details.
16 //
17 //
18 // You should have received a copy of the GNU General Public License
19 // along with this program.
20 // If not, see <http://www.gnu.org/licenses/>.
21 //----------------------------------------------------------------------------
22 //MEDGroupInfo.h
23 
24 #ifndef MEDGROUPINFO_H
25 #define MEDGROUPINFO_H
26 
27 #include "MEDCellBaseInfo.h"
28 
29 namespace XC {
30 class Set;
31 class MEDMeshing;
32 
34 //
37  {
38  public:
39  typedef std::map<int,std::vector<int> > map_indices_tipo;
40  private:
41  std::string nombre;
42  map_indices_tipo indices_tipo;
43  MED_EN::medEntityMesh tipo_entidad;
44  mutable MEDMEM::GROUP *med_group;
45  protected:
46  friend class MEDMeshing;
47  friend class MEDFieldInfo;
48  MEDGroupInfo(MEDMeshing *mesh,const std::string &);
49  MEDGroupInfo(MEDMeshing *mesh,const Set &);
50 
51  std::vector<int> &getElementOfTypeIndices(const MED_EN::medGeometryElement &);
52  std::vector<int> getVectorIndicesTipos(void) const;
53  std::vector<int> getElementIndices(void) const;
54 
55  const MEDMeshing &getMesh(void) const;
56  MEDMEM::GROUP *getGrupoMED(void) const;
57  public:
58  ~MEDGroupInfo(void);
59  const std::string &getNombre(void) const;
60 
61  void new_vertice(size_t i,const MEDMapIndices &);
62  void nueva_celda(size_t i,const MED_EN::medGeometryElement &);
63  void to_med(void) const;
64  };
65 } // end of XC namespace
66 #endif
std::vector< int > getElementIndices(void) const
Returns a vector with the indexes of the elements ordered by type.
Definition: MEDGroupInfo.cc:139
void new_vertice(size_t i, const MEDMapIndices &)
Appends a vertex to the group.
Definition: MEDGroupInfo.cc:99
Information about node and element sets.
Definition: MEDGroupInfo.h:36
std::vector< int > getVectorIndicesTipos(void) const
Returns the vector with the positions of the different element types int the vector of element indexe...
Definition: MEDGroupInfo.cc:124
Envoltorio para el objeto MESHING de MED.
Definition: MEDMeshing.h:45
void to_med(void) const
Dumps group definition on mesh MED.
Definition: MEDGroupInfo.cc:148
std::vector< int > & getElementOfTypeIndices(const MED_EN::medGeometryElement &)
Returns the vector with the indexes of the elements that match the type being passed as parameter...
Definition: MEDGroupInfo.cc:89
Map between the indexes in XC and in MEDMEM.
Definition: MEDMapIndices.h:36
MEDGroupInfo(MEDMeshing *mesh, const std::string &)
Constructor.
Definition: MEDGroupInfo.cc:33
Information about a field defined over a mesh subset.
Definition: MEDFieldInfo.h:38
~MEDGroupInfo(void)
Destructor.
Definition: MEDGroupInfo.cc:70
void nueva_celda(size_t i, const MED_EN::medGeometryElement &)
Appends a cell to the group.
Definition: MEDGroupInfo.cc:109
Object set.
Definition: Set.h:63
const std::string & getNombre(void) const
Returns the nombre del grupo.
Definition: MEDGroupInfo.cc:119
Basic information about mesh cells.
Definition: MEDCellBaseInfo.h:39
================================================================================
Definition: ContinuaReprComponent.h:34