v0.14.0
BCMultiIndices.hpp
Go to the documentation of this file.
1 /** \file BCMultiIndices.hpp
2  * \brief Multi-index containers, data boundary data structures and other
3  * low-level functions
4  *
5  */
6 
7 
8 
9 #ifndef __BCMULTIINDICES_HPP__
10 #define __BCMULTIINDICES_HPP__
11 
12 namespace MoFEM {
13 
14 /**
15  * \brief this struct keeps basic methods for moab meshset about material and
16  * boundary conditions \ingroup mofem_bc
17  *
18  */
19 struct CubitMeshSets {
20 
22  CubitBCType cubitBcType; ///< type of meshset from cubit NodeSet, BlockSet,
23  ///< SideSet and more
24  std::vector<Tag>
25  tag_handles; ///< vector of tag handles to types of data passed from cubit
26  int *msId = nullptr; ///< cubit meshset ID
27  char *tagBcData = nullptr;
28  int tagBcSize;
29  unsigned int *tagBlockHeaderData = nullptr;
30  double *tagBlockAttributes = nullptr;
32  char *tagName = nullptr;
34 
36  CubitMeshSets(Interface &moab, const CubitBCType cubit_bc_type,
37  const int msId);
38 
39  /**
40  * \brief get meshset id as it set in preprocessing software
41  * @return id of meshset
42  */
43  inline int getMeshsetId() const { return msId ? *msId : -1; }
44 
45  // /** \deprecated use getMeshsetId() instead
46  // */
47  // DEPRECATED inline int get_msId() const { return getMeshsetId(); }
48 
49  /**
50  * \brief get type of meshset
51  *
52  * See CubitBC for set of types of meshsets.
53  *
54  * @return meshset type
55  */
56  inline CubitBCType getBcType() const { return cubitBcType; }
57 
58  /**
59  * \brief get bc meshset
60  * @return meshset entity handle
61  */
62  inline EntityHandle getMeshset() const { return meshset; }
63 
64  /**
65  * \brief get bc meshset type
66  * @return return type as unsigned int
67  */
68  inline unsigned long int getBcTypeULong() const {
69  return cubitBcType.to_ulong();
70  }
71 
72  /**
73  * \brief get meshset type and mask
74  * @return type is returned as unsigned integer
75  */
76  inline unsigned long int getMaskedBcTypeULong() const {
77  return (cubitBcType & meshsetsMask).to_ulong();
78  }
79 
80  /** @deprecated use getMaskedBcTypeULong */
81  DEPRECATED unsigned long int getMaksedBcTypeULong() const {
82  return (cubitBcType & meshsetsMask).to_ulong();
83  }
84 
85  /**
86  * @brief Get the meshset entities dimension
87  *
88  * \note If dimension is -1, then dimension for meshset ins undetermined.
89  *
90  * @return unsigned int
91  */
92  unsigned int getMeshsetEntitiesDimension() const {
94  return tagBlockHeaderData[2];
95  else
96  return -1;
97  }
98 
99  /**
100  * \brief get entities form meshset
101  * @param moab moab instance
102  * @param dimension dimension of entities
103  * @param entities range of returned entities
104  * @param recursive true if meshset should be searched recursively
105  * @return error code
106  */
108  getMeshsetIdEntitiesByDimension(Interface &moab, const int dimension,
109  Range &entities,
110  const bool recursive = false) const;
111 
112  /**
113  * \brief get entities form meshset
114  *
115  * Use if meshset have predefined dimension
116  *
117  * @param moab moab instance
118  * @param entities range of returned entities
119  * @param recursive true if meshset should be searched recursively
120  * @return error code
121  *
122  */
125  const bool recursive = false) const;
126 
127  /**
128  * \brief get entities by type
129  * @param moab moab instance
130  * @param type type of entity
131  * @param entities returned entities
132  * @param recursive true if meshset should be searched recursively
133  * @return error code
134  */
136  const EntityType type,
137  Range &entities,
138  const bool recursive = false) const;
139 
140  /**
141  * \brief Function that returns the CubitBCType type of the contents of
142  * bc_data
143  */
144  MoFEMErrorCode getTypeFromBcData(const std::vector<char> &bc_data,
145  CubitBCType &type) const;
146 
147  /**
148  * \brief Function that returns the CubitBCType type of the contents of
149  * bc_data
150  */
152 
153  /**
154  * \brief get bc_data vector from MoFEM database
155  *
156  * \param bc_data is the in/out vector were bc_data will be stored
157  */
158  MoFEMErrorCode getBcData(std::vector<char> &bc_data) const;
159 
160  /**
161  * \brief get block_headers vector from MoFEM database
162  *
163  * \param material_data is the in/out vector were the material data will be
164  * stored
165  */
167  getBlockHeaderData(std::vector<unsigned int> &material_data) const;
168 
169  /**
170  * \brief print material_data int stream given by os
171  *
172  * f.e. it->print_Cubit_material_data(cout), i.e. printing to standard output
173  * f.e. it->print_Cubit_material_data(std::cerr), i.e. printing to standard
174  * error output
175  */
176  MoFEMErrorCode printBlockHeaderData(std::ostream &os) const;
177 
178  /**
179  * \brief print bc_data int stream given by os
180  *
181  * f.e. it->printBcData(cout), i.e. printing to standard output
182  * f.e. it->printBcData(std::cerr), i.e. printing to standard error output
183  */
184  MoFEMErrorCode printBcData(std::ostream &os) const;
185 
186  /**
187  * \brief Function that returns the CubitBCType type of the block name,
188  * sideset name etc.
189  */
190  MoFEMErrorCode getTypeFromName(const std::string &name,
191  CubitBCType &type) const;
192 
193  /**
194  * \brief Function that returns the CubitBCType type of the block name,
195  * sideset name etc.
196  */
198 
199  /**
200  * \brief get Cubit block attributes
201  *
202  * \param attributes is the vector where the block attribute data will be
203  * stored
204  */
205  MoFEMErrorCode getAttributes(std::vector<double> &attributes) const;
206 
207  /**
208  * \brief cet Cubit block attributes
209  *
210  * \param attributes is the vector where the block attribute data will be
211  * stored
212  */
214  const std::vector<double> &attributes);
215 
216  /**
217  * \brief print the attributes vector
218  *
219  * f.e. it->printAttributes(cout), i.e. printing to standard output
220  * f.e. it->printAttributes(std::cerr), i.e. printing to standard error output
221  */
222  MoFEMErrorCode printAttributes(std::ostream &os) const;
223 
224  /**
225  * \brief get name of block, sideset etc. (this is set in Cubit block
226  properties)
227  *
228  * Block Name Conventions:
229 
230  * Materials are defined with block names starting with MAT_
231  * e.g. MAT_ELASTIC_abcd.
232  *
233  * List of materials/solution procedures
234 
235  * Block name / Number of attributes / (1) Attribute 1, (2) Attribute 2 etc.
236  *
237  * MAT_ELASTIC / 10 / (1) Young's modulus
238  * (2) Poisson's ratio
239  * (3) User attribute 8
240  * ...
241  * (10) User attribute 8
242  *
243  * MAT_ELASTIC_TRANSISO / 5 / (1) Young's modulus in xy plane (Ep)
244  * (2) Young's modulus in z-direction (Ez)
245  * (3) Poisson's ratio in xy plane (vp)
246  * (4) Poisson's ratio in z-direction (vpz)
247  * (5) Shear modulus in z-direction (Gzp)
248  *
249  * MAT_INTERF / 1 / (1) Elastic modulus multiplier
250  *
251  * To be extended as appropriate
252  */
253  std::string getName() const;
254 
255  /**
256  * \brief print name of block, sideset etc. (this is set in Cubit setting
257  * properties)
258  *
259  * e.g. it->printName(cout), i.e. printing to standard output
260  * e.g it->printName(std::cerr), i.e. printing to standard error output
261  */
262  MoFEMErrorCode printName(std::ostream &os) const;
263 
264  /**
265  * \brief fill data structure with data saved on meshset
266  */
267  template <class ATTRIBUTE_TYPE>
268  MoFEMErrorCode getAttributeDataStructure(ATTRIBUTE_TYPE &data) const {
270  if ((cubitBcType & data.getType()).none()) {
271  SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
272  "attributes are not for ATTRIBUTE_TYPE structure");
273  }
274  std::vector<double> attributes;
275  CHKERR getAttributes(attributes);
276  CHKERR data.fill_data(attributes);
278  }
279 
280  /**
281  * \brief fill meshset data with data on structure
282  */
283  template <class ATTRIBUTE_TYPE>
284  MoFEMErrorCode setAttributeDataStructure(const ATTRIBUTE_TYPE &data) {
286  if ((cubitBcType & data.getType()).none()) {
287  SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
288  "attributes are not for ATTRIBUTE_TYPE structure");
289  }
290  double *ptr = const_cast<double *>(tagBlockAttributes);
291  CHKERR data.set_data(ptr, 8 * tagBlockAttributesSize);
293  }
294 
295  template <class CUBIT_BC_DATA_TYPE>
296  MoFEMErrorCode getBcDataStructure(CUBIT_BC_DATA_TYPE &data) const {
298 
299  if ((cubitBcType & data.tYpe).none()) {
300  SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
301  "bc_data are not for CUBIT_BC_DATA_TYPE structure");
302  }
303  std::vector<char> bc_data;
304  getBcData(bc_data);
305  ierr = data.fill_data(bc_data);
306  CHKERRG(ierr);
308  }
309 
310  template <class CUBIT_BC_DATA_TYPE>
311  MoFEMErrorCode setBcDataStructure(CUBIT_BC_DATA_TYPE &data) {
313 
314  char *ptr = const_cast<char *>(tagBcData);
315  ierr = data.set_data(ptr, tagBcSize);
316  CHKERRG(ierr);
318  }
319 
320  friend std::ostream &operator<<(std::ostream &os, const CubitMeshSets &e);
321 
324 
326 };
327 
328 /**
329  * \typedef CubitMeshSet_multiIndex
330  * \brief Stores data about meshsets (see CubitMeshSets) storing data about
331  * boundary conditions, interfaces, sidesets, nodests, blocksets
332  *
333  * \param Meshset_mi_tag index by meshset handle
334  * \param CubitMeshsetType_mi_tag index by bc type, see CubitBC
335  * \param CubitMeshsetMaskedType_mi_tag index by NODESET, SIDESET, BLOCKSET
336  * only
337  *
338  * \param CubitMeshsets_name index by meshset name
339  *
340  * \param Composite_Cubit_msId_And_MeshsetType_mi_tag index by meshset id and
341  * type NODESET, SIDESET or BLOCKSET
342  *
343  * Example:
344  * \code
345  * MeshsetsManager *m_mng;
346  * CHKERR m_field.getInterface(m_mng);
347  * auto &index = m_mng->getMeshsetsMultindex();
348  *
349  *
350  * auto mit =
351  * index.get<CubitMeshsetMaskedType_mi_tag>().lower_bound(BLOCKSET); auto
352  * hi_mit =
353  * index.get<CubitMeshsetMaskedType_mi_tag>().upper_bound(BLOCKSET);
354  *
355  * // Make a loop over all BLOCKSET
356  * for(;mit!=hi_mit;mit++) {
357  * int id = mit->getMeshsetId(); // get blockset id
358  * EntityHandle handle = mit->getMeshset(); // get block meshset
359  * std::vector< double > attributes;
360  * // get block attributes
361  * auto mit->getAttributes(attributes);
362  * // do something
363  * }
364  * \endcode
365  *
366  */
367 typedef multi_index_container<
369  indexed_by<
370  hashed_unique<tag<Meshset_mi_tag>, member<CubitMeshSets, EntityHandle,
372  ordered_non_unique<tag<CubitMeshsetType_mi_tag>,
373  const_mem_fun<CubitMeshSets, unsigned long int,
375  ordered_non_unique<tag<CubitMeshsetMaskedType_mi_tag>,
376  const_mem_fun<CubitMeshSets, unsigned long int,
378  ordered_non_unique<
379  tag<CubitMeshsets_name>,
380  const_mem_fun<CubitMeshSets, std::string, &CubitMeshSets::getName>>,
381  hashed_unique<
382  tag<Composite_Cubit_msId_And_MeshsetType_mi_tag>,
383  composite_key<
385  const_mem_fun<CubitMeshSets, int, &CubitMeshSets::getMeshsetId>,
386  const_mem_fun<CubitMeshSets, unsigned long int,
389 
390 /** \brief change meshset type
391  */
395  : bIt(bit){};
396  void operator()(CubitMeshSets &e);
397 };
398 
399 /**
400  * \brief change meshset name
401  */
404  std::string nAme;
405  CubitMeshSets_change_name(Interface &moab, const std::string &name)
406  : mOab(moab), nAme(name){};
407  void operator()(CubitMeshSets &e);
408 };
409 
410 /**
411  * change meshset attributes
412  */
415  const std::vector<double> &aTtr;
417  const std::vector<double> &attr)
418  : mOab(moab), aTtr(attr) {}
419  void operator()(CubitMeshSets &e);
420 };
421 
422 /**
423  * change meshset attributes for material data structure
424  */
429  Interface &moab, const GenericAttributeData &attr)
430  : mOab(moab), aTtr(attr) {}
431  void operator()(CubitMeshSets &e);
432 };
433 
434 /**
435  * change meshset attributes for material data structure
436  */
441  const GenericCubitBcData &bc_data)
442  : mOab(moab), bcData(bc_data) {}
443  void operator()(CubitMeshSets &e);
444 };
445 
446 } // namespace MoFEM
447 
448 #endif // __BCMULTIINDICES_HPP__
449 
450 /**
451  * \defgroup mofem_bc Boundary conditions
452  * \ingroup mofem
453  */
MoFEMFunctionReturnHot
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:460
MoFEM::CubitMeshSets::cubitBcType
CubitBCType cubitBcType
Definition: BCMultiIndices.hpp:22
MoFEM::CubitMeshSets::getMaksedBcTypeULong
DEPRECATED unsigned long int getMaksedBcTypeULong() const
Definition: BCMultiIndices.hpp:81
MoFEM::CubitMeshSets_change_bc_data_structure
Definition: BCMultiIndices.hpp:437
MoFEM::CubitMeshSets::CubitMeshSets
CubitMeshSets(Interface &moab, const EntityHandle meshset)
MoFEM::GenericCubitBcData
Generic bc data structure.
Definition: BCData.hpp:20
MoFEM::CubitMeshSets::msId
int * msId
cubit meshset ID
Definition: BCMultiIndices.hpp:26
MoFEM::CubitMeshSets_change_attributes_data_structure::CubitMeshSets_change_attributes_data_structure
CubitMeshSets_change_attributes_data_structure(Interface &moab, const GenericAttributeData &attr)
Definition: BCMultiIndices.hpp:428
DEPRECATED
#define DEPRECATED
Definition: definitions.h:17
MoFEM::CubitMeshSets::printAttributes
MoFEMErrorCode printAttributes(std::ostream &os) const
print the attributes vector
Definition: BCMultiIndices.cpp:314
EntityHandle
MoFEM::CubitMeshSets::bhTag
Tag bhTag
Definition: BCMultiIndices.hpp:322
MoFEM::CubitMeshSets_change_attributes_data_structure::mOab
Interface & mOab
Definition: BCMultiIndices.hpp:426
MoFEM::CubitMeshSet_multiIndex
multi_index_container< CubitMeshSets, indexed_by< hashed_unique< tag< Meshset_mi_tag >, member< CubitMeshSets, EntityHandle, &CubitMeshSets::meshset > >, ordered_non_unique< tag< CubitMeshsetType_mi_tag >, const_mem_fun< CubitMeshSets, unsigned long int, &CubitMeshSets::getBcTypeULong > >, ordered_non_unique< tag< CubitMeshsetMaskedType_mi_tag >, const_mem_fun< CubitMeshSets, unsigned long int, &CubitMeshSets::getMaskedBcTypeULong > >, ordered_non_unique< tag< CubitMeshsets_name >, const_mem_fun< CubitMeshSets, std::string, &CubitMeshSets::getName > >, hashed_unique< tag< Composite_Cubit_msId_And_MeshsetType_mi_tag >, composite_key< CubitMeshSets, const_mem_fun< CubitMeshSets, int, &CubitMeshSets::getMeshsetId >, const_mem_fun< CubitMeshSets, unsigned long int, &CubitMeshSets::getMaskedBcTypeULong > > > > > CubitMeshSet_multiIndex
Stores data about meshsets (see CubitMeshSets) storing data about boundary conditions,...
Definition: BCMultiIndices.hpp:388
MoFEM::CubitMeshSets::bhTag_header
Tag bhTag_header
Definition: BCMultiIndices.hpp:322
MoFEM::Exceptions::MoFEMErrorCode
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
Definition: Exceptions.hpp:56
MoFEM::CubitMeshSets
this struct keeps basic methods for moab meshset about material and boundary conditions
Definition: BCMultiIndices.hpp:19
MoFEM::CubitMeshSets::operator<<
friend std::ostream & operator<<(std::ostream &os, const CubitMeshSets &e)
Definition: BCMultiIndices.cpp:360
MoFEM::CubitMeshSets_change_attributes::mOab
Interface & mOab
Definition: BCMultiIndices.hpp:414
MoFEM::CubitMeshSets_change_bc_data_structure::mOab
Interface & mOab
Definition: BCMultiIndices.hpp:438
MoFEM::CubitMeshSets::printBlockHeaderData
MoFEMErrorCode printBlockHeaderData(std::ostream &os) const
print material_data int stream given by os
Definition: BCMultiIndices.cpp:191
MoFEM::CubitMeshSets::tagBcSize
int tagBcSize
Definition: BCMultiIndices.hpp:28
MoFEM::CubitMeshSets_change_attributes_data_structure
Definition: BCMultiIndices.hpp:425
MoFEM::CubitMeshSets::tagBlockAttributes
double * tagBlockAttributes
Definition: BCMultiIndices.hpp:30
MoFEM::CubitMeshSets::tagName
char * tagName
Definition: BCMultiIndices.hpp:32
MoFEM::CubitMeshSets::getMeshsetIdEntitiesByType
MoFEMErrorCode getMeshsetIdEntitiesByType(Interface &moab, const EntityType type, Range &entities, const bool recursive=false) const
get entities by type
Definition: BCMultiIndices.cpp:162
MoFEM::CubitMeshSets_change_add_bit_to_cubit_bc_type::CubitMeshSets_change_add_bit_to_cubit_bc_type
CubitMeshSets_change_add_bit_to_cubit_bc_type(const CubitBCType &bit)
Definition: BCMultiIndices.hpp:394
MoFEM::CubitMeshSets_change_add_bit_to_cubit_bc_type::operator()
void operator()(CubitMeshSets &e)
Definition: BCMultiIndices.cpp:414
MoFEM::CubitMeshSets::getMaskedBcTypeULong
unsigned long int getMaskedBcTypeULong() const
get meshset type and mask
Definition: BCMultiIndices.hpp:76
MoFEM::CubitMeshSets_change_bc_data_structure::operator()
void operator()(CubitMeshSets &e)
Definition: BCMultiIndices.cpp:438
MoFEM::CubitMeshSets::entityNameTag
Tag entityNameTag
Definition: BCMultiIndices.hpp:323
MoFEM::CubitMeshSets_change_attributes::aTtr
const std::vector< double > & aTtr
Definition: BCMultiIndices.hpp:415
MoFEM::CubitMeshSets::setAttributes
MoFEMErrorCode setAttributes(moab::Interface &moab, const std::vector< double > &attributes)
cet Cubit block attributes
Definition: BCMultiIndices.cpp:301
MoFEM::CubitMeshSets::getBcDataStructure
MoFEMErrorCode getBcDataStructure(CUBIT_BC_DATA_TYPE &data) const
Definition: BCMultiIndices.hpp:296
MoFEM::CubitMeshSets::getMeshsetEntitiesDimension
unsigned int getMeshsetEntitiesDimension() const
Get the meshset entities dimension.
Definition: BCMultiIndices.hpp:92
MoFEM::CubitMeshSets::getTagsHandlers
MoFEMErrorCode getTagsHandlers(Interface &moab)
Definition: BCMultiIndices.cpp:8
MoFEM::DeprecatedCoreInterface
Deprecated interface functions.
Definition: DeprecatedCoreInterface.hpp:16
MoFEM::CubitMeshSets::thBlockAttribs
Tag thBlockAttribs
Definition: BCMultiIndices.hpp:322
MoFEM::Interface
DeprecatedCoreInterface Interface
Definition: Interface.hpp:2010
MoFEM::CubitMeshSets_change_name::mOab
Interface & mOab
Definition: BCMultiIndices.hpp:403
MoFEM::CubitMeshSets_change_name::operator()
void operator()(CubitMeshSets &e)
Definition: BCMultiIndices.cpp:389
MoFEM::CubitMeshSets::tag_handles
std::vector< Tag > tag_handles
vector of tag handles to types of data passed from cubit
Definition: BCMultiIndices.hpp:25
MoFEM::CubitMeshSets::nsTag
Tag nsTag
Definition: BCMultiIndices.hpp:322
MoFEM::CubitMeshSets::getName
std::string getName() const
get name of block, sideset etc. (this is set in Cubit block properties)
Definition: BCMultiIndices.cpp:213
MoFEM::CubitMeshSets_change_name
change meshset name
Definition: BCMultiIndices.hpp:402
CHKERR
#define CHKERR
Inline error check.
Definition: definitions.h:548
MoFEM::CubitMeshSets::getBcType
CubitBCType getBcType() const
get type of meshset
Definition: BCMultiIndices.hpp:56
MoFEM
implementation of Data Operators for Forces and Sources
Definition: Common.hpp:10
MoFEM::CubitMeshSets::setBcDataStructure
MoFEMErrorCode setBcDataStructure(CUBIT_BC_DATA_TYPE &data)
Definition: BCMultiIndices.hpp:311
MoFEM::CubitMeshSets::printName
MoFEMErrorCode printName(std::ostream &os) const
print name of block, sideset etc. (this is set in Cubit setting properties)
Definition: BCMultiIndices.cpp:221
MoFEM::CubitMeshSets_change_add_bit_to_cubit_bc_type
change meshset type
Definition: BCMultiIndices.hpp:392
bit
auto bit
set bit
Definition: hanging_node_approx.cpp:75
convert.type
type
Definition: convert.py:64
MoFEM::CubitMeshSets_change_attributes
Definition: BCMultiIndices.hpp:413
MoFEM::CubitMeshSets::getAttributeDataStructure
MoFEMErrorCode getAttributeDataStructure(ATTRIBUTE_TYPE &data) const
fill data structure with data saved on meshset
Definition: BCMultiIndices.hpp:268
MoFEM::CubitMeshSets::meshset
EntityHandle meshset
Definition: BCMultiIndices.hpp:21
MoFEM::CubitMeshSets::setAttributeDataStructure
MoFEMErrorCode setAttributeDataStructure(const ATTRIBUTE_TYPE &data)
fill meshset data with data on structure
Definition: BCMultiIndices.hpp:284
MoFEM::CubitMeshSets_change_name::nAme
std::string nAme
Definition: BCMultiIndices.hpp:404
MoFEM::CubitMeshSets_change_attributes::CubitMeshSets_change_attributes
CubitMeshSets_change_attributes(Interface &moab, const std::vector< double > &attr)
Definition: BCMultiIndices.hpp:416
MoFEM::CubitMeshSets_change_name::CubitMeshSets_change_name
CubitMeshSets_change_name(Interface &moab, const std::string &name)
Definition: BCMultiIndices.hpp:405
MoFEM::CubitMeshSets_change_add_bit_to_cubit_bc_type::bIt
CubitBCType bIt
Definition: BCMultiIndices.hpp:393
MoFEM::CubitMeshSets_change_attributes_data_structure::operator()
void operator()(CubitMeshSets &e)
Definition: BCMultiIndices.cpp:423
MoFEM::CubitMeshSets::ssTag
Tag ssTag
Definition: BCMultiIndices.hpp:322
MoFEM::GenericAttributeData
Generic attribute data structure.
Definition: MaterialBlocks.hpp:17
MoFEM::CubitMeshSets::tagBlockAttributesSize
int tagBlockAttributesSize
Definition: BCMultiIndices.hpp:31
MoFEM::CubitMeshSets_change_bc_data_structure::bcData
const GenericCubitBcData & bcData
Definition: BCMultiIndices.hpp:439
MoFEM::CubitMeshSets::meshsetsMask
const CubitBCType meshsetsMask
Definition: BCMultiIndices.hpp:33
MoFEM::CubitMeshSets_change_bc_data_structure::CubitMeshSets_change_bc_data_structure
CubitMeshSets_change_bc_data_structure(Interface &moab, const GenericCubitBcData &bc_data)
Definition: BCMultiIndices.hpp:440
MoFEM::CubitMeshSets::tagBlockHeaderData
unsigned int * tagBlockHeaderData
Definition: BCMultiIndices.hpp:29
Range
MoFEM::Types::CubitBCType
std::bitset< 32 > CubitBCType
Definition: Types.hpp:52
MoFEM::CubitMeshSets::getAttributes
MoFEMErrorCode getAttributes(std::vector< double > &attributes) const
get Cubit block attributes
Definition: BCMultiIndices.cpp:290
MoFEM::CubitMeshSets::getMeshset
EntityHandle getMeshset() const
get bc meshset
Definition: BCMultiIndices.hpp:62
MoFEM::CubitMeshSets::getMeshsetId
int getMeshsetId() const
get meshset id as it set in preprocessing software
Definition: BCMultiIndices.hpp:43
MoFEM::CubitMeshSets::getBcData
MoFEMErrorCode getBcData(std::vector< char > &bc_data) const
get bc_data vector from MoFEM database
Definition: BCMultiIndices.cpp:176
MoFEM::Exceptions::ierr
static MoFEMErrorCodeGeneric< PetscErrorCode > ierr
Definition: Exceptions.hpp:76
MOFEM_DATA_INCONSISTENCY
@ MOFEM_DATA_INCONSISTENCY
Definition: definitions.h:31
MoFEM::CubitMeshSets::getTypeFromName
MoFEMErrorCode getTypeFromName(const std::string &name, CubitBCType &type) const
Function that returns the CubitBCType type of the block name, sideset name etc.
Definition: BCMultiIndices.cpp:328
MoFEM::CubitMeshSets_change_attributes_data_structure::aTtr
const GenericAttributeData & aTtr
Definition: BCMultiIndices.hpp:427
MoFEM::CubitMeshSets::nsTag_data
Tag nsTag_data
Definition: BCMultiIndices.hpp:322
MoFEM::CubitMeshSets_change_attributes::operator()
void operator()(CubitMeshSets &e)
Definition: BCMultiIndices.cpp:419
MoFEM::CubitMeshSets::getTypeFromBcData
MoFEMErrorCode getTypeFromBcData(const std::vector< char > &bc_data, CubitBCType &type) const
Function that returns the CubitBCType type of the contents of bc_data.
Definition: BCMultiIndices.cpp:230
MoFEMFunctionBeginHot
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:453
MoFEM::CubitMeshSets::ssTag_data
Tag ssTag_data
Definition: BCMultiIndices.hpp:322
MoFEM::CubitMeshSets::getMeshsetIdEntitiesByDimension
MoFEMErrorCode getMeshsetIdEntitiesByDimension(Interface &moab, const int dimension, Range &entities, const bool recursive=false) const
get entities form meshset
convert.int
int
Definition: convert.py:64
MoFEMFunctionReturn
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:429
MoFEM::CubitMeshSets::getBlockHeaderData
MoFEMErrorCode getBlockHeaderData(std::vector< unsigned int > &material_data) const
get block_headers vector from MoFEM database
Definition: BCMultiIndices.cpp:183
MoFEM::CubitMeshSets::getBcTypeULong
unsigned long int getBcTypeULong() const
get bc meshset type
Definition: BCMultiIndices.hpp:68
MoFEM::CubitMeshSets::tagBcData
char * tagBcData
Definition: BCMultiIndices.hpp:27
CHKERRG
#define CHKERRG(n)
Check error code of MoFEM/MOAB/PETSc function.
Definition: definitions.h:496
MoFEMFunctionBegin
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:359
MoFEM::CubitMeshSets::printBcData
MoFEMErrorCode printBcData(std::ostream &os) const
print bc_data int stream given by os
Definition: BCMultiIndices.cpp:271