GetFEM
5.4.2
|
structure used to hold a set of convexes and/or convex faces. More...
#include <getfem_mesh_region.h>
Classes | |
class | visitor |
"iterator" class for regions. More... | |
Public Member Functions | |
mesh_region (size_type id__) | |
a mesh_region can be built from a integer parameter (a region number in a mesh), but it won't be usable until 'from_mesh(m)' has been called Note that these regions are read-only, this constructor is mostly used for backward-compatibility. | |
mesh_region (mesh &m, size_type id__, size_type type=size_type(-1)) | |
internal constructor. More... | |
mesh_region (const dal::bit_vector &bv) | |
build a mesh_region from a convex list stored in a bit_vector. | |
int | region_is_faces_of (const getfem::mesh &m1, const mesh_region &rg2, const getfem::mesh &m2) const |
Test if the region is a boundary of a list of faces of elements of region rg . More... | |
void | allow_partitioning () |
In multithreaded part of the program makes only a partition of the region visible in the index() and size() operations, as well as during iterations with mr_visitor. More... | |
void | bounding_box (base_node &Pmin, base_node &Pmax) const |
Return the bounding box [Pmin - Pmax] of the mesh_region. | |
void | prohibit_partitioning () |
Disregard partitioning, which means being able to see the whole region in multithreaded code. More... | |
const mesh_region & | from_mesh (const mesh &m) const |
For regions which have been built with just a number 'id', from_mesh(m) sets the current region to 'm.region(id)'. More... | |
const dal::bit_vector & | index () const |
Index of the region convexes, or the convexes from the partition on the current thread. | |
size_type | size () const |
Region size, or the size of the region partition on the current thread if the region is partitioned. | |
size_type | nb_convex () const |
Number of convexes in the region, or on the partition on the current thread. | |
bool | is_only_faces () const |
Return true if the region do contain only convex faces. | |
bool | is_only_convexes () const |
Return true if the region do not contain any convex face. | |
Static Public Member Functions | |
static mesh_region | all_convexes () |
provide a default value for the mesh_region parameters of assembly procedures etc. | |
static mesh_region | intersection (const mesh_region &a, const mesh_region &b) |
return the intersection of two mesh regions | |
static mesh_region | merge (const mesh_region &a, const mesh_region &b) |
return the union of two mesh_regions | |
static mesh_region | subtract (const mesh_region &a, const mesh_region &b) |
subtract the second region from the first one | |
static size_type | free_region_id (const getfem::mesh &m) |
Extract the next region number that does not yet exists in the mesh. | |
structure used to hold a set of convexes and/or convex faces.
Definition at line 55 of file getfem_mesh_region.h.
getfem::mesh_region::mesh_region | ( | mesh & | m, |
size_type | id__, | ||
size_type | type = size_type(-1) |
||
) |
internal constructor.
You should used m.region(id) instead.
Definition at line 47 of file getfem_mesh_region.cc.
int getfem::mesh_region::region_is_faces_of | ( | const getfem::mesh & | m1, |
const mesh_region & | rg2, | ||
const getfem::mesh & | m2 | ||
) | const |
Test if the region is a boundary of a list of faces of elements of region rg
.
Return 0 if not, -1 if only partially, 1 if the region contains only some faces which are all faces of elements of rg
.
Definition at line 467 of file getfem_mesh_region.cc.
void getfem::mesh_region::allow_partitioning | ( | ) |
In multithreaded part of the program makes only a partition of the region visible in the index() and size() operations, as well as during iterations with mr_visitor.
This is a default behaviour
Definition at line 204 of file getfem_mesh_region.cc.
void getfem::mesh_region::prohibit_partitioning | ( | ) |
Disregard partitioning, which means being able to see the whole region in multithreaded code.
Can be used, for instance, for contact problems where master region is partitioned, while the slave region is not
Definition at line 220 of file getfem_mesh_region.cc.
const mesh_region & getfem::mesh_region::from_mesh | ( | const mesh & | m | ) | const |
For regions which have been built with just a number 'id', from_mesh(m) sets the current region to 'm.region(id)'.
(works only once)
Definition at line 72 of file getfem_mesh_region.cc.