pysdic.Mesh.compute_property_derivative#

Mesh.compute_property_derivative(property_array, integration_points, *, skip_m1=True, default=nan)[source]#

Compute the derivative of a property defined at the nodes of a mesh to given integration points within elements with respect to global coordinates \((x,y,z,...)\) from mesh and integration point information (convenient method for pysdic.compute_property_derivative()). The element_type must be specified in the mesh connectivity to compute the shape functions for the elements of the mesh, which are used to perform the computation of the property derivatives.

Note

The function is a convenience wrapper around the pysdic.compute_property_derivative() function.

Important

Warning

No test are performed to check if the provided integration points are consistent with the mesh (i.e., existing element indices). Only shape check is performed. The behavior of the function is undefined if the provided integration points are not consistent with the mesh.

Parameters:
  • property_array (numpy.ndarray) – An array of shape \((N_{v}, P)\) containing the property values defined at the \(N_{v}\) vertices of the mesh. If 1D-array is provided, it will be treated as a single-component property of shape \((N_{v}, 1)\).

  • integration_points (pysdic.objects.IntegrationPoints) – The integration points at which the property derivatives are to be computed.

  • skip_m1 (bool, optional) – If set to True, any element index of -1 in element_indices will result in the corresponding contribution to the property derivatives being skipped (i.e., not added to the property derivative values). Default is True.

  • default (Union[Real, numpy.ndarray], optional) – The default value to assign to property derivatives for integration points associated with an element index of -1 when skip_m1 is True. Default is numpy.nan. The input can also be a numpy.ndarray of shape (P,) to assign different default values for each property component.

Returns:

property_derivatives – An array of shape \((N_{p}, P, E)\) containing the computed derivatives of the property with respect to global coordinates at each of the \(N_{p}\) integration points, where \(E\) is the dimension of the global coordinate system.

Return type:

numpy.ndarray

See also

pysdic.compute_shape_functions()

For more information on shape functions and their role in computing property derivatives.

pysdic.compute_property_derivative()

For more information on the algorithm used to compute the property derivatives and an example of how to use it.