The points module defines the Points base class, which bundles point coordinates, point weights, a local triangulation and a hull triangulation. The module provides several different implementations such as TensorPoints and SimplexGaussPoints that reflect the variety of elements in the nutils.element module.

class nutils.points.Points(npoints, ndims)

Bases: nutils.types.Singleton

Collection of points on an element.

The Points base class bundles point coordinates, point weights, a local triangulation and hull triangulation. Of these only the coordinates are mandatory, and should be provided by the derived class in the form of the coords attribute. Of the remaining properties only hull() has a functional base implementation that relies on the availability of tri.


Coordinates of the points as a float array.


Weights of the points as a float array.

  • npoints (int) – Number of discrete points.
  • ndims (int) – Number of spatial dimensions.
__mul__(self, other)

Return self*other.

product(self, other)

Return the product with other.

Parameters:other (Points) –
Returns:product – The product.
Return type:Points
class nutils.points.CoordsPoints(coords)

Bases: nutils.points.Points

Manually supplied points.

class nutils.points.CoordsWeightsPoints(coords, weights)

Bases: nutils.points.CoordsPoints

Manually supplied points and weights.

class nutils.points.CoordsUniformPoints(coords, volume)

Bases: nutils.points.CoordsPoints

Manually supplied points with uniform weights.

class nutils.points.TensorPoints(points1, points2)

Bases: nutils.points.Points

Tensor product of two Points instances.

class nutils.points.SimplexGaussPoints(ndims, degree)

Bases: nutils.points.CoordsWeightsPoints

Gauss quadrature points on a simplex.

class nutils.points.SimplexBezierPoints(ndims, n)

Bases: nutils.points.CoordsUniformPoints

Bezier points on a simplex.

class nutils.points.TransformPoints(points, trans)

Bases: nutils.points.Points

Affinely transformed Points.

class nutils.points.ConcatPoints(allpoints, duplicates=frozenset())

Bases: nutils.points.Points

Concatenation of several Points objects.

An optional duplicates argument lists all points that are equal, triggering deduplication and resulting in a smaller total point count.


Gauss quadrature for line.


Gauss quadrature for triangle.

Reference: http://www.cs.rpi.edu/~flaherje/pdf/fea6.pdf


Gauss quadrature for tetrahedron.

Reference http://www.cs.rpi.edu/~flaherje/pdf/fea6.pdf