pysdic.Mesh.validate_integration_points#

Mesh.validate_integration_points(integration_points)[source]#

Check that integration points are consistent with the mesh.

The following conditions are checked:

  • integration_points is a pysdic.IntegrationPoints.

  • The element type of the mesh is set, and its topological dimension \(K\) is the number of natural coordinates of the points.

  • The element indices of the located points are lower than \(N_e\) (the unlocated points, with element index -1, are accepted).

The natural coordinates are not checked against the reference element: the pysdic.fem functions handle the points outside it.

Parameters:

integration_points (pysdic.IntegrationPoints) – The integration points to check.

Raises:
Return type:

None

Examples

1from pysdic import Mesh, IntegrationPoints
2
3mesh = Mesh([[0, 0, 0], [1, 0, 0], [0, 1, 0]], [[0, 1, 2]], element_type="triangle_3")
4
5mesh.validate_integration_points(IntegrationPoints.from_gauss_points("triangle_3", 1))  # OK
6mesh.validate_integration_points(IntegrationPoints([[0.2, 0.2]], [1]))  # IndexError