element¶
The element module defines reference elements such as the
LineReference
and TriangleReference
, but also more exotic
objects like the MosaicReference
. A set of (interconnected) elements
together form a nutils.topology.Topology
. Elements have edges and
children (for refinement), which are in turn elements and map onto self by an
affine transformation. They also have a well defined reference coordinate
system, and provide pointsets for purposes of integration and sampling.
- class nutils.element.Reference(ndims)¶
Bases:
Singleton
Reference element.
- vertices¶
Array of shape
nverts x ndims
that defines the coordinates of the element’s vertices.
- edge_vertices¶
Sequence of integer arrays that specifies per edge (outer sequence, corresponding to
edges
) for each vertex (inner sequence, corresponding toedges[iedge].vertices
) its index invertices
.
- property simplices¶
Partition of the element consisting of simplices.
The simplices attribute is a sequence of integer arrays that specify per simplex the indices of the vertices in
vertices
.
- property simplex_transforms¶
Sequence of transforms from simplex to parent element.
The simplex_transforms attribute is a sequence of objects of type
nutils.transform.TransformItem
that provide per simplex the coordinate mapping from the simplex to the parent element. The origin of the simplex-local coordinate system maps to its first vertex, the first unit vector to the second, the second to the third, and so on.
- __mul__(self, other)¶
Return
self*other
.
- trim(self, levels, maxrefine, ndivisions)¶
trim element along levelset
- class nutils.element.PointReference¶
Bases:
SimplexReference
0D simplex
- class nutils.element.LineReference¶
Bases:
SimplexReference
1D simplex
- class nutils.element.TriangleReference¶
Bases:
SimplexReference
2D simplex
- class nutils.element.TetrahedronReference¶
Bases:
SimplexReference
3D simplex