pysdic.IntegrationPoints.keep_elements#

IntegrationPoints.keep_elements(element_indices, n_elements, *, propagate_properties=True)[source]#

Update the integration points after only some elements of their mesh are kept (see pysdic.Mesh.keep_connectivity_by_index()).

Equivalent to filter_elements() with a mask of \(N_e\) elements, True for the kept elements.

Parameters:
  • element_indices (ArrayLike) – An integer array of shape \((R,)\) with the indices of the kept elements, in \([0, N_e)\). Duplicates are allowed.

  • n_elements (Integral) – The number of elements \(N_e\) of the mesh before the operation.

  • propagate_properties (bool, optional (default: True)) – If False, the new integration points have no properties.

Returns:

The integration points consistent with the new mesh.

Return type:

pysdic.IntegrationPoints

Raises:

IndexError – If an element index is out of \([0, N_e)\), or if a point refers to an element \(\geq N_e\).