v0.8.23
DeprecatedCoreInterface.cpp
Go to the documentation of this file.
1 /** \file DeprecatedCoreInterface.cpp
2  * \brief implementation of deprecated functions
3  */
4 
5 /* MoFEM is free software: you can redistribute it and/or modify it under
6  * the terms of the GNU Lesser General Public License as published by the
7  * Free Software Foundation, either version 3 of the License, or (at your
8  * option) any later version.
9  *
10  * MoFEM is distributed in the hope that it will be useful, but WITHOUT
11  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
13  * License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with MoFEM. If not, see <http://www.gnu.org/licenses/>
17  */
18 
19 namespace MoFEM {
20 
23  const BitRefLevel &bit, int verb) {
24  return getInterface<BitRefManager>()->setBitRefLevelByDim(meshset, 2, bit,
25  verb);
26 }
27 
30  const BitRefLevel &bit, int verb) {
31  return getInterface<BitRefManager>()->setBitRefLevelByDim(meshset, 3, bit,
32  verb);
33 }
34 
36  const BitRefLevel &bit,
37  const bool only_tets,
38  int verb) {
39  return getInterface<BitRefManager>()->setBitRefLevel(ents, bit, only_tets,
40  verb);
41 }
42 
44  const EntityHandle meshset, const BitRefLevel &bit, int verb) {
45  return getInterface<BitRefManager>()->setBitLevelToMeshset(meshset, bit,
46  verb);
47 }
48 
51  int verb) {
52 
54  Range entities;
55  CHKERR getInterface<CoreInterface>()->get_moab().get_entities_by_handle(
56  meshset, entities, true);
57  CHKERR getInterface<BitRefManager>()->setElementsBitRefLevel(
58  entities, BitRefLevel(), verb);
60 }
61 
63 DeprecatedCoreInterface::seed_finite_elements(const Range &entities, int verb) {
64  return getInterface<BitRefManager>()->setElementsBitRefLevel(
65  entities, BitRefLevel(), verb);
66 }
67 
69  const double alpha, const std::string &field_name_x,
70  const std::string &field_name_y, bool error_if_missing,
71  bool creat_if_missing) {
72  return getInterface<FieldBlas>()->fieldAxpy(
73  alpha, field_name_x, field_name_y, error_if_missing, creat_if_missing);
74 }
76 DeprecatedCoreInterface::set_field(const double val, const EntityType type,
77  const std::string &field_name) {
78  return getInterface<FieldBlas>()->setField(val, type, field_name);
79 }
81 DeprecatedCoreInterface::set_field(const double val, const EntityType type,
82  const Range &ents,
83  const std::string &field_name) {
84  return getInterface<FieldBlas>()->setField(val, type, ents, field_name);
85 }
88  const std::string &field_name) {
89  return getInterface<FieldBlas>()->fieldScale(alpha, field_name);
90 }
91 
93  const EntityHandle from_entiti, const int to_dimension,
94  Range &adj_entities) const {
95  return getInterface<BitRefManager>()->getAdjacenciesEquality(
96  from_entiti, to_dimension, adj_entities);
97 }
98 
101  const int to_dimension,
102  Range &adj_entities) const {
103  return getInterface<BitRefManager>()->getAdjacenciesAny(
104  from_entiti, to_dimension, adj_entities);
105 }
106 
108  const Problem *problem_ptr, const EntityHandle *from_entities,
109  const int num_netities, const int to_dimension, Range &adj_entities,
110  const int operation_type, const int verb) const {
111  return getInterface<BitRefManager>()->getAdjacencies(
112  problem_ptr, from_entities, num_netities, to_dimension, adj_entities,
113  operation_type, verb);
114 }
115 
117  const BitRefLevel &bit, const EntityHandle *from_entities,
118  const int num_netities, const int to_dimension, Range &adj_entities,
119  const int operation_type, const int verb) const {
120  return getInterface<BitRefManager>()->getAdjacencies(
121  bit, from_entities, num_netities, to_dimension, adj_entities,
122  operation_type, verb);
123 }
124 
126  RowColData rc,
127  Vec *V) const {
128  return getInterface<VecManager>()->vecCreateSeq(name, rc, V);
129 }
131  RowColData rc,
132  Vec *V) const {
133  return getInterface<VecManager>()->vecCreateGhost(name, rc, V);
134 }
136  const std::string &problem, RowColData rc, int min_order, int max_order,
137  IS *is, int verb) const {
138  return getInterface<ISManager>()->isCreateProblemOrder(problem, rc, min_order,
139  max_order, is);
140 }
142  const std::string &problem, RowColData rc, const std::string &field,
143  int min_coeff_idx, int max_coeff_idx, IS *is, int verb) const {
144  return getInterface<ISManager>()->isCreateProblemFieldAndRank(
145  problem, rc, field, min_coeff_idx, max_coeff_idx, is);
146 }
149  const std::string &x_problem, const std::string &x_field_name,
150  RowColData x_rc, const std::string &y_problem,
151  const std::string &y_field_name, RowColData y_rc, std::vector<int> &idx,
152  std::vector<int> &idy, int verb) const {
153  return getInterface<ISManager>()->isCreateFromProblemFieldToOtherProblemField(
154  x_problem, x_field_name, x_rc, y_problem, y_field_name, y_rc, idx, idy);
155 }
156 
159  const std::string &x_problem, const std::string &x_field_name,
160  RowColData x_rc, const std::string &y_problem,
161  const std::string &y_field_name, RowColData y_rc, IS *ix, IS *iy,
162  int verb) const {
163  return getInterface<ISManager>()->isCreateFromProblemFieldToOtherProblemField(
164  x_problem, x_field_name, x_rc, y_problem, y_field_name, y_rc, ix, iy);
165 }
167  Vec xin, const std::string &x_problem, const std::string &x_field_name,
168  RowColData x_rc, Vec yin, const std::string &y_problem,
169  const std::string &y_field_name, RowColData y_rc, VecScatter *newctx,
170  int verb) const {
171  return getInterface<VecManager>()->vecScatterCreate(
172  xin, x_problem, x_field_name, x_rc, yin, y_problem, y_field_name, y_rc,
173  newctx);
174 }
176  Vec xin, const std::string &x_problem, RowColData x_rc, Vec yin,
177  const std::string &y_problem, RowColData y_rc, VecScatter *newctx,
178  int verb) const {
179  return getInterface<VecManager>()->vecScatterCreate(xin, x_problem, x_rc, yin,
180  y_problem, y_rc, newctx);
181 }
183  const Problem *problem_ptr, RowColData rc, Vec V, InsertMode mode,
184  ScatterMode scatter_mode) const {
185  return getInterface<VecManager>()->setLocalGhostVector(problem_ptr, rc, V,
186  mode, scatter_mode);
187 }
189  const std::string &name, RowColData rc, Vec V, InsertMode mode,
190  ScatterMode scatter_mode) const {
191  return getInterface<VecManager>()->setLocalGhostVector(name, rc, V, mode,
192  scatter_mode);
193 }
195  const Problem *problem_ptr, RowColData rc, Vec V, InsertMode mode,
196  ScatterMode scatter_mode) const {
197  return getInterface<VecManager>()->setGlobalGhostVector(problem_ptr, rc, V,
198  mode, scatter_mode);
199 }
201  const std::string &name, RowColData rc, Vec V, InsertMode mode,
202  ScatterMode scatter_mode) const {
203  return getInterface<VecManager>()->setGlobalGhostVector(name, rc, V, mode,
204  scatter_mode);
205 }
207  const Problem *problem_ptr, const std::string &field_name,
208  const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode,
209  ScatterMode scatter_mode, int verb) {
210  return getInterface<VecManager>()->setOtherLocalGhostVector(
211  problem_ptr, field_name, cpy_field_name, rc, V, mode, scatter_mode);
212 }
214  const std::string &name, const std::string &field_name,
215  const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode,
216  ScatterMode scatter_mode, int verb) {
217  return getInterface<VecManager>()->setOtherLocalGhostVector(
218  name, field_name, cpy_field_name, rc, V, mode, scatter_mode);
219 }
221  const Problem *problem_ptr, const std::string &field_name,
222  const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode,
223  ScatterMode scatter_mode, int verb) {
224  return getInterface<VecManager>()->setOtherGlobalGhostVector(
225  problem_ptr, field_name, cpy_field_name, rc, V, mode, scatter_mode);
226 }
228  const std::string &name, const std::string &field_name,
229  const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode,
230  ScatterMode scatter_mode, int verb) {
231  return getInterface<VecManager>()->setOtherGlobalGhostVector(
232  name, field_name, cpy_field_name, rc, V, mode, scatter_mode);
233 }
234 
236  int verb) {
237  return getInterface<BitRefManager>()->shiftRightBitRef(
238  shift, BitRefLevel().set(), verb);
239 }
240 
242  const BitRefLevel &bit, const BitRefLevel &mask, const EntityType type,
243  const EntityHandle meshset, int verb) {
244  return getInterface<BitRefManager>()->getEntitiesByTypeAndRefLevel(
245  bit, mask, type, meshset, verb);
246 }
247 
249  const BitRefLevel &bit, const BitRefLevel &mask, const EntityType type,
250  Range &ents, int verb) {
251  return getInterface<BitRefManager>()->getEntitiesByTypeAndRefLevel(
252  bit, mask, type, ents, verb);
253 }
254 
257  const BitRefLevel &mask,
258  const EntityHandle meshset) {
259  return getInterface<BitRefManager>()->getEntitiesByRefLevel(bit, mask,
260  meshset);
261 }
262 
264  const BitRefLevel &bit, const BitRefLevel &mask, Range &ents) {
265  return getInterface<BitRefManager>()->getEntitiesByRefLevel(bit, mask, ents);
266 }
267 
269  const EntityHandle parent, const BitRefLevel &child_bit,
270  const EntityHandle child, EntityType child_type, const bool recursive,
271  int verb) {
272  return getInterface<BitRefManager>()->updateMeshsetByEntitiesChildren(
273  parent, child_bit, child, child_type, recursive, verb);
274 }
275 
278  const BitRefLevel &child_bit, int verb) {
279  return getInterface<BitRefManager>()->updateFieldMeshsetByEntitiesChildren(
280  child_bit, verb);
281 }
282 
285  const std::string name, const BitRefLevel &child_bit, int verb) {
286  return getInterface<BitRefManager>()->updateFieldMeshsetByEntitiesChildren(
287  name, child_bit, verb);
288 }
289 
292  const std::string name, const BitRefLevel &child_bit,
293  const EntityType fe_ent_type, int verb) {
294  return getInterface<BitRefManager>()
295  ->updateFiniteElementMeshsetByEntitiesChildren(name, child_bit,
296  fe_ent_type, verb);
297 }
298 
300  return getInterface<MeshsetsManager>()->printDisplacementSet();
302 }
303 
305  return getInterface<MeshsetsManager>()->printPressureSet();
306 }
307 
309  return getInterface<MeshsetsManager>()->printForceSet();
310 }
311 
313  return getInterface<MeshsetsManager>()->printMaterialsSet();
314 }
315 
317  const int ms_id, const CubitBCType cubit_bc_type) {
318  return getInterface<MeshsetsManager>()->checkMeshset(ms_id, cubit_bc_type);
319 }
320 
322  const CubitBCType cubit_bc_type, const int ms_id, const std::string name) {
323  return getInterface<MeshsetsManager>()->addMeshset(cubit_bc_type, ms_id,
324  name);
325 }
326 
328  const CubitBCType cubit_bc_type, const int ms_id,
329  const std::vector<double> &attributes, const std::string name) {
330  return getInterface<MeshsetsManager>()->setAtributes(cubit_bc_type, ms_id,
331  attributes, name);
332 }
335  const CubitBCType cubit_bc_type, const int ms_id,
336  const GenericAttributeData &data, const std::string name) {
337  return getInterface<MeshsetsManager>()->setAtributesByDataStructure(
338  cubit_bc_type, ms_id, data, name);
339 }
341  const CubitBCType cubit_bc_type, const int ms_id,
342  const GenericCubitBcData &data) {
343  return getInterface<MeshsetsManager>()->setBcData(cubit_bc_type, ms_id, data);
344 }
347  const int ms_id) {
348  return getInterface<MeshsetsManager>()->deleteMeshset(cubit_bc_type, ms_id);
349 }
351  const int ms_id, const CubitBCType cubit_bc_type,
352  const CubitMeshSets **cubit_meshset_ptr) {
353  return getInterface<MeshsetsManager>()->getCubitMeshsetPtr(
354  ms_id, cubit_bc_type, cubit_meshset_ptr);
355 }
357  const int msId, const CubitBCType cubit_bc_type, const int dimension,
358  Range &entities, const bool recursive) {
359  return getInterface<MeshsetsManager>()->getEntitiesByDimension(
360  msId, cubit_bc_type.to_ulong(), dimension, entities, recursive);
361 }
363  const int msId, const CubitBCType cubit_bc_type, Range &entities,
364  const bool recursive) {
365  return getInterface<MeshsetsManager>()->getEntitiesByDimension(
366  msId, cubit_bc_type.to_ulong(), entities, recursive);
367 }
369  const int ms_id, const unsigned int cubit_bc_type, const int dimension,
370  Range &entities, const bool recursive) {
371  return get_cubit_msId_entities_by_dimension(ms_id, CubitBCType(cubit_bc_type),
372  dimension, entities, recursive);
373 }
375  const int ms_id, const unsigned int cubit_bc_type, Range &entities,
376  const bool recursive) {
377  return get_cubit_msId_entities_by_dimension(ms_id, CubitBCType(cubit_bc_type),
378  entities, recursive);
379 }
380 
382  const int ms_id, const unsigned int cubit_bc_type, EntityHandle &meshset) {
383  return getInterface<MeshsetsManager>()->getMeshset(ms_id, cubit_bc_type,
384  meshset);
385 }
386 
388 DeprecatedCoreInterface::get_cubit_meshsets(const unsigned int cubit_bc_type,
389  Range &meshsets) {
390  return getInterface<MeshsetsManager>()->getMeshsetsByType(cubit_bc_type,
391  meshsets);
392 }
393 
395  const std::string &name, const bool square_matrix, int verb) {
396  return getInterface<ProblemsManager>()->buildProblemOnDistributedMesh(
397  name, square_matrix, verb);
398 }
400  Problem *problem_ptr, const bool square_matrix, int verb) {
401  return getInterface<ProblemsManager>()->buildProblemOnDistributedMesh(
402  problem_ptr, square_matrix, verb);
403 }
404 
406  const bool square_matrix,
407  int verb) {
408  return getInterface<ProblemsManager>()->buildProblem(problem_ptr,
409  square_matrix, verb);
410 }
411 
413 DeprecatedCoreInterface::build_problem(const std::string &problem_name,
414  const bool square_matrix, int verb) {
415  return getInterface<ProblemsManager>()->buildProblem(problem_name,
416  square_matrix, verb);
417 }
418 
421  int verb) {
422  return getInterface<ProblemsManager>()->partitionSimpleProblem(name, verb);
423 }
424 
426  const std::string &name, const std::string &problem_for_rows,
427  bool copy_rows, const std::string &problem_for_cols, bool copy_cols,
428  int verb) {
429  return getInterface<ProblemsManager>()->inheritPartition(
430  name, problem_for_rows, copy_rows, problem_for_cols, copy_cols, verb);
431 }
432 
434  const std::string &out_name, const std::vector<std::string> &fields_row,
435  const std::vector<std::string> &fields_col, const std::string &main_problem,
436  const bool square_matrix, int verb) {
437  return getInterface<ProblemsManager>()->buildSubProblem(
438  out_name, fields_row, fields_col, main_problem, square_matrix, nullptr,
439  nullptr, verb);
440 }
441 
443 DeprecatedCoreInterface::partition_problem(const std::string &name, int verb) {
444  return getInterface<ProblemsManager>()->partitionProblem(name, verb);
445 }
446 
448  const std::string &name, bool part_from_moab, int low_proc, int hi_proc,
449  int verb) {
450  return getInterface<ProblemsManager>()->partitionFiniteElements(
451  name, part_from_moab, low_proc, hi_proc, verb);
453 }
454 
457  int verb) {
458  return getInterface<ProblemsManager>()->partitionGhostDofs(name, verb);
459 }
460 
462  const std::string &name, const std::string &fe_name, PetscLayout *layout,
463  int verb) {
464  return getInterface<ProblemsManager>()->getProblemElementsLayout(
465  name, fe_name, layout);
466 }
467 
469  const int dim,
470  const int adj_dim,
471  const int n_parts,
472  int verb) {
473  return getInterface<ProblemsManager>()->partitionMesh(
474  ents, dim, adj_dim, n_parts, NULL, NULL, NULL, verb);
475 }
476 
479  const BitRefLevel &mask, int verb) {
480  return clear_dofs_fields_by_bit_ref(bit, mask, verb);
481 }
482 
485  const BitRefLevel &mask, int verb) {
486  return clear_ents_fields_by_bit_ref(bit, mask, verb);
487 }
488 
490  const BitRefLevel &bit, const BitRefLevel &mask, int verb) {
491  return clear_finite_elements_by_bit_ref(bit, mask, verb);
492 }
493 
495  const Range &edges, const std::string &name, int verb) {
496  return add_ents_to_field_by_type(edges, MBEDGE, name, verb);
497 }
498 
500  const EntityHandle meshset, const std::string &name, int verb) {
501  return add_ents_to_field_by_type(meshset, MBEDGE, name, true, verb);
502 }
503 
505  const EntityHandle meshset, const std::string &name, int verb) {
506  return add_ents_to_field_by_type(meshset, MBTRI, name, true, verb);
507 }
508 
510  const Range &tris, const std::string &name, int verb) {
511  return add_ents_to_field_by_type(tris, MBTRI, name, verb);
512 }
513 
515  const Range &nodes, const std::string &name, int verb) {
516  return add_ents_to_field_by_type(nodes, MBVERTEX, name, verb);
517 }
518 
520  const EntityHandle meshset, const std::string &name, int verb) {
521  return add_ents_to_field_by_type(meshset, MBVERTEX, name, true, verb);
522 }
523 
525  const Range &tets, const std::string &name, int verb) {
526  return add_ents_to_field_by_type(tets, MBTET, name, verb);
527 }
528 
530  const EntityHandle meshset, const std::string &name, int verb) {
531  return add_ents_to_field_by_type(meshset, MBTET, name, true, verb);
532 }
533 
535  const Range &quads, const std::string &name, int verb) {
536  return add_ents_to_field_by_type(quads, MBQUAD, name, verb);
537 }
538 
540  EntityHandle meshset, const std::string &name, int verb) {
541  return add_ents_to_field_by_type(meshset, MBQUAD, name, true, verb);
542 }
543 
545  const Range &prisms, const std::string &name, int verb) {
546  return add_ents_to_field_by_type(prisms, MBPRISM, name, verb);
547 }
548 
550  EntityHandle meshset, const std::string &name, int verb) {
551  return add_ents_to_field_by_type(meshset, MBPRISM, name, true, verb);
552 }
553 
556  Mat *Aij, int verb) {
557  return getInterface<MatrixManager>()
558  ->createMPIAIJWithArrays<PetscGlobalIdx_mi_tag>(name, Aij, verb);
559 }
560 
562  const std::string &name, Mat *Adj, int verb) {
563  return getInterface<MatrixManager>()->createMPIAdjWithArrays<Idx_mi_tag>(
564  name, Adj, verb);
565 }
566 
568  const std::string &name, Mat *Aij, PetscInt **i, PetscInt **j,
569  PetscScalar **v, int verb) {
571  if (i || j || v)
572  SETERRQ(PETSC_COMM_SELF, MOFEM_NOT_IMPLEMENTED, "Not implemented");
573  CHKERR getInterface<MatrixManager>()
574  ->createSeqAIJWithArrays<PetscLocalIdx_mi_tag>(name, Aij, verb);
576 }
577 
579  const Problem *problem_ptr, const std::string &fe_name, FEMethod &method,
580  int lower_rank, int upper_rank, MoFEMTypes bh, int verb) {
581  return getInterface<CoreInterface>()->loop_finite_elements(
582  problem_ptr, fe_name, method, lower_rank, upper_rank, nullptr, bh, verb);
583 }
584 
586  const std::string &problem_name, const std::string &fe_name,
587  FEMethod &method, int lower_rank, int upper_rank, MoFEMTypes bh, int verb) {
588  return getInterface<CoreInterface>()->loop_finite_elements(
589  problem_name, fe_name, method, lower_rank, upper_rank, nullptr, bh, verb);
590 }
591 
593  const std::string &problem_name, const std::string &fe_name,
594  FEMethod &method, MoFEMTypes bh, int verb) {
595  return getInterface<CoreInterface>()->loop_finite_elements(
596  problem_name, fe_name, method, get_comm_rank(), get_comm_rank(), nullptr,
597  bh, verb);
598 }
599 
600 } // namespace MoFEM
Generic bc data structure.
Definition: BCData.hpp:30
DEPRECATED MoFEMErrorCode update_meshset_by_entities_children(const EntityHandle parent, const BitRefLevel &child_bit, const EntityHandle child, EntityType child_type, const bool recursive=false, int verb=-1)
Get child entities form meshset containing parent entities.
structure for User Loop Methods on finite elementsIt can be used to calculate stiffness matrices,...
DEPRECATED MoFEMErrorCode MatCreateMPIAdj_with_Idx_mi_tag(const std::string &name, Mat *Adj, int verb=DEFAULT_VERBOSITY)
DEPRECATED bool check_msId_meshset(const int msId, const CubitBCType cubit_bc_type)
check for CUBIT Id and CUBIT type
DEPRECATED MoFEMErrorCode partition_mesh(const Range &ents, const int dim, const int adj_dim, const int n_parts, int verb=-1)
Set partition tag to each finite element in the problem.
DEPRECATED MoFEMErrorCode print_cubit_force_set() const
DEPRECATED MoFEMErrorCode set_global_ghost_vector(const Problem *problem_ptr, RowColData rc, Vec V, InsertMode mode, ScatterMode scatter_mode) const
set values of vector from/to mesh database (collective)collective - need tu be run on all processors ...
DEPRECATED MoFEMErrorCode get_entities_by_ref_level(const BitRefLevel &bit, const BitRefLevel &mask, const EntityHandle meshset)
add all ents from ref level given by bit to meshset
DEPRECATED MoFEMErrorCode build_sub_problem(const std::string &out_name, const std::vector< std::string > &fields_row, const std::vector< std::string > &fields_col, const std::string &main_problem, const bool square_matrix=true, int verb=-1)
build sub problem
DEPRECATED MoFEMErrorCode seed_finite_elements(const EntityHandle meshset, int verb=-1)
DEPRECATED MoFEMErrorCode get_cubit_meshsets(const unsigned int cubit_bc_type, Range &meshsets)
get all CUBIT meshsets by CUBIT type
DEPRECATED MoFEMErrorCode ISCreateProblemFieldAndRank(const std::string &problem, RowColData rc, const std::string &field, int min_coeff_idx, int max_coeff_idx, IS *is, int verb=-1) const
create IS for given problem, field and rank range (collective)
DEPRECATED MoFEMErrorCode partition_simple_problem(const std::string &name, int verb=-1)
partition problem dofs
DEPRECATED MoFEMErrorCode shift_right_bit_ref(const int shift, int verb=-1)
right shift bit ref level
virtual DEPRECATED MoFEMErrorCode seed_ref_level_2D(const EntityHandle meshset, const BitRefLevel &bit, int verb=-1)
seed 2D entities (Triangles entities only) in the meshset and their adjacencies (only TRIs adjacencie...
DEPRECATED MoFEMErrorCode clear_finite_elements(const BitRefLevel &bit, const BitRefLevel &mask, int verb=-1)
DEPRECATED MoFEMErrorCode ISCreateFromProblemFieldToOtherProblemField(const std::string &x_problem, const std::string &x_field_name, RowColData x_rc, const std::string &y_problem, const std::string &y_field_name, RowColData y_rc, std::vector< int > &idx, std::vector< int > &idy, int verb=-1) const
create IS for give two problems and field
DEPRECATED MoFEMErrorCode get_adjacencies(const Problem *problem_ptr, const EntityHandle *from_entities, const int num_netities, const int to_dimension, Range &adj_entities, const int operation_type=moab::Interface::INTERSECT, const int verb=0) const
Get the adjacencies associated with a entity to entities of a specified dimension....
DEPRECATED MoFEMErrorCode set_cubit_msId_attribites(const CubitBCType cubit_bc_type, const int ms_id, const std::vector< double > &attributes, const std::string name="")
set attributes to cubit meshset
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:476
DEPRECATED MoFEMErrorCode set_local_ghost_vector(const Problem *problem_ptr, RowColData rc, Vec V, InsertMode mode, ScatterMode scatter_mode) const
set values of vector from/to meshdatabase
this struct keeps basic methods for moab meshset about material and boundary conditions
DEPRECATED MoFEMErrorCode clear_ents_fields(const BitRefLevel &bit, const BitRefLevel &mask, int verb=-1)
DEPRECATED MoFEMErrorCode add_ents_to_field_by_PRISMs(const Range &prisms, const std::string &name, int verb=-1)
set field entities from adjacencies of prismsThe lower dimension entities are added depending on the ...
DEPRECATED MoFEMErrorCode get_adjacencies_equality(const EntityHandle from_entiti, const int to_dimension, Range &adj_entities) const
Get the adjacencies associated with a entity to entities of a specified dimension....
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:507
DEPRECATED MoFEMErrorCode get_adjacencies_any(const EntityHandle from_entiti, const int to_dimension, Range &adj_entities) const
Get the adjacencies associated with a entity to entities of a specified dimension....
keeps basic data about problemThis is low level structure with information about problem,...
RowColData
RowColData.
Definition: definitions.h:185
DEPRECATED MoFEMErrorCode add_ents_to_field_by_EDGEs(const Range &edges, const std::string &name, int verb=-1)
set field entities form adjacencies of edgesThe lower dimension entities are added depending on the s...
implementation of Data Operators for Forces and Sources
Definition: Common.hpp:21
DEPRECATED MoFEMErrorCode add_cubit_msId(const CubitBCType cubit_bc_tyep, const int msId, const std::string name="")
add cubit meshset
virtual MoFEMErrorCode clear_dofs_fields_by_bit_ref(const BitRefLevel &bit, const BitRefLevel &mask, int verb=DEFAULT_VERBOSITY)=0
DEPRECATED MoFEMErrorCode build_problem_on_distributed_mesh(const std::string &name, const bool square_matrix=true, int verb=-1)
build problem data structures, assuming that mesh is distributed (collective)
DEPRECATED MoFEMErrorCode set_other_global_ghost_vector(const Problem *problem_ptr, const std::string &field_name, const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode, ScatterMode scatter_mode, int verb=-1)
Copy vector to field which is not part of the problem (collective)collective - need tu be run on all ...
DEPRECATED MoFEMErrorCode seed_ref_level(const Range &ents, const BitRefLevel &bit, const bool only_tets=true, int verb=-1)
seed entities in the range and their adjacencies in a particular BitRefLevel
DEPRECATED MoFEMErrorCode field_scale(const double alpha, const std::string &field_name)
scale field
DEPRECATED MoFEMErrorCode get_problem_elements_layout(const std::string &name, const std::string &fe_name, PetscLayout *layout, int verb=-1)
Get layout of elements in the problemIn layout is stored information how many elements is on each pro...
DEPRECATED MoFEMErrorCode partition_finite_elements(const std::string &name, bool part_from_moab=false, int low_proc=-1, int hi_proc=-1, int verb=-1)
partition finite elements
virtual MoFEMErrorCode clear_finite_elements_by_bit_ref(const BitRefLevel &bit, const BitRefLevel &mask, int verb=DEFAULT_VERBOSITY)=0
DEPRECATED MoFEMErrorCode add_ents_to_field_by_TRIs(const EntityHandle meshset, const std::string &name, int verb=-1)
set field entities form adjacencies of trianglesThe lower dimension entities are added depending on t...
virtual int get_comm_rank() const =0
DEPRECATED MoFEMErrorCode add_ents_to_field_by_VERTICEs(const Range &nodes, const std::string &name, int verb=-1)
set field entities on verticesThe lower dimension entities are added depending on the space type
DEPRECATED MoFEMErrorCode clear_dofs_fields(const BitRefLevel &bit, const BitRefLevel &mask, int verb=-1)
DEPRECATED MoFEMErrorCode set_cubit_msId_bc_data_structure(const CubitBCType cubit_bc_type, const int ms_id, const GenericCubitBcData &data)
set boundary data structure to meshset
DEPRECATED MoFEMErrorCode set_other_local_ghost_vector(const Problem *problem_ptr, const std::string &fiel_name, const std::string &cpy_field_name, RowColData rc, Vec V, InsertMode mode, ScatterMode scatter_mode, int verb=-1)
Copy vector to field which is not part of the problem.
DEPRECATED MoFEMErrorCode get_cubit_msId(const int msId, const CubitBCType cubit_bc_type, const CubitMeshSets **cubit_meshset_ptr)
get cubit meshset
DEPRECATED MoFEMErrorCode MatCreateSeqAIJWithArrays(const std::string &name, Mat *Aij, PetscInt **i, PetscInt **j, PetscScalar **v, int verb=DEFAULT_VERBOSITY)
virtual MoFEMErrorCode add_ents_to_field_by_type(const Range &ents, const EntityType type, const std::string &name, int verb=DEFAULT_VERBOSITY)=0
Add entities to field meshset.
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
Definition: Exceptions.hpp:66
DEPRECATED MoFEMErrorCode build_problem(const std::string &name, const bool square_matrix, int verb=-1)
build problem data structures
DEPRECATED MoFEMErrorCode partition_compose_problem(const std::string &name, const std::string &problem_for_rows, const bool copy_rows, const std::string &problem_for_cols, const bool copy_cols, int verb=-1)
build indexing and partition problem inheriting indexing and partitioning from two other problems
DEPRECATED MoFEMErrorCode print_cubit_pressure_set() const
DEPRECATED MoFEMErrorCode partition_problem(const std::string &name, int verb=-1)
partition problem dofs (collective)
DEPRECATED MoFEMErrorCode set_field(const double val, const EntityType type, const std::string &field_name)
use FieldBlas
DEPRECATED MoFEMErrorCode VecCreateGhost(const std::string &name, RowColData rc, Vec *V) const
create ghost vector for problem (collective)collective - need to be run on all processors in communic...
DEPRECATED MoFEMErrorCode VecScatterCreate(Vec xin, const std::string &x_problem, const std::string &x_field_name, RowColData x_rc, Vec yin, const std::string &y_problem, const std::string &y_field_name, RowColData y_rc, VecScatter *newctx, int verb=-1) const
create scatter for vectors form one to another problem (collective)User specify what name of field on...
DEPRECATED MoFEMErrorCode set_cubit_msId_attribites_data_structure(const CubitBCType cubit_bc_type, const int ms_id, const GenericAttributeData &data, const std::string name="")
set (material) data structure to cubit meshset
Generic attribute data structure.
#define CHKERR
Inline error check.
Definition: definitions.h:595
DEPRECATED MoFEMErrorCode get_cubit_msId_entities_by_dimension(const int ms_id, const CubitBCType cubit_bc_type, const int dimension, Range &entities, const bool recursive=false)
std::bitset< BITREFLEVEL_SIZE > BitRefLevel
Bit structure attached to each entity identifying to what mesh entity is attached.
Definition: Types.hpp:51
DEPRECATED MoFEMErrorCode partition_ghost_dofs(const std::string &name, int verb=-1)
determine ghost nodes
DEPRECATED MoFEMErrorCode delete_cubit_msId(const CubitBCType cubit_bc_type, const int msId)
delete cubit meshset
DEPRECATED MoFEMErrorCode get_cubit_msId_meshset(const int msId, const unsigned int cubit_bc_type, EntityHandle &meshset)
get meshset from CUBIT Id and CUBIT type
DEPRECATED MoFEMErrorCode seed_ref_level_MESHSET(const EntityHandle meshset, const BitRefLevel &bit, int verb=-1)
std::bitset< 32 > CubitBCType
Definition: Types.hpp:63
DEPRECATED MoFEMErrorCode print_cubit_displacement_set() const
DEPRECATED MoFEMErrorCode VecCreateSeq(const std::string &name, RowColData rc, Vec *V) const
create local vector for problem
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:406
DEPRECATED MoFEMErrorCode ISCreateProblemOrder(const std::string &problem, RowColData rc, int min_order, int max_order, IS *is, int verb=-1) const
create IS for given order range (collective)
DEPRECATED MoFEMErrorCode MatCreateMPIAIJWithArrays(const std::string &name, Mat *Aij, int verb=DEFAULT_VERBOSITY)
DEPRECATED MoFEMErrorCode seed_ref_level_3D(const EntityHandle meshset, const BitRefLevel &bit, int verb=-1)
seed 2D entities in the meshset and their adjacencies (only TETs adjacencies) in a particular BitRefL...
DEPRECATED MoFEMErrorCode add_ents_to_field_by_TETs(const EntityHandle meshset, const std::string &name, int verb=-1)
set field entities from adjacencies of tetrahedronThe lower dimension entities are added depending on...
virtual MoFEMErrorCode clear_ents_fields_by_bit_ref(const BitRefLevel &bit, const BitRefLevel &mask, int verb=DEFAULT_VERBOSITY)=0
DEPRECATED MoFEMErrorCode add_ents_to_field_by_QUADs(const Range &quads, const std::string &name, int verb=-1)
set field entities from adjacencies of quadsThe lower dimension entities are added depending on the s...
DEPRECATED MoFEMErrorCode update_finite_element_meshset_by_entities_children(const std::string name, const BitRefLevel &child_bit, const EntityType fe_ent_type, int verb=-1)
update finite element mesheset by child entities
DEPRECATED MoFEMErrorCode get_entities_by_type_and_ref_level(const BitRefLevel &bit, const BitRefLevel &mask, const EntityType type, const EntityHandle meshset, int verb=-1)
add all ents from ref level given by bit to meshset
DEPRECATED MoFEMErrorCode update_field_meshset_by_entities_children(const BitRefLevel &child_bit, int verb=-1)
update fields meshesets by child entities
MoFEMTypes
Those types control how functions respond on arguments, f.e. error handling.
Definition: definitions.h:182
DEPRECATED MoFEMErrorCode loop_finite_elements(const Problem *problem_ptr, const std::string &fe_name, FEMethod &method, int lower_rank, int upper_rank, MoFEMTypes bh, int verb=DEFAULT_VERBOSITY)
DEPRECATED MoFEMErrorCode field_axpy(const double alpha, const std::string &fiel_name_x, const std::string &field_name_y, bool error_if_missing=false, bool creat_if_missing=false)
axpy fields
DEPRECATED MoFEMErrorCode print_cubit_materials_set() const