# MeshDomains¶

class dolfin.cpp.mesh.MeshDomains(*args)

Bases: object

The class MeshDomains stores the division of a Mesh into subdomains. For each topological dimension 0 <= d <= D, where D is the topological dimension of the Mesh, a set of integer markers are stored for a subset of the entities of dimension d, indicating for each entity in the subset the number of the subdomain. It should be noted that the subset does not need to contain all entities of any given dimension; entities not contained in the subset are “unmarked”.

Create empty mesh domains

clear()

Clear all data

get_marker()

Get marker (entity index, marker value) of a given dimension d. Throws an error if marker does not exist.

init()

Initialize mesh domains for given topological dimension

is_empty()

Check whether domain data is empty

markers()

• markers(dim)

Get subdomain markers for given dimension (shared pointer version)

• markers(dim)

Get subdomain markers for given dimension (const shared pointer version)

max_dim()

Return maximum topological dimension of stored markers

num_marked()

Return number of marked entities of given dimension

set_marker()

Set marker (entity index, marker value) of a given dimension d. Returns true if a new key is inserted, false otherwise.

thisown

The membership flag