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()). Theelement_typemust 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
If
shape_function_derivativesare precomputed inIntegrationPoints, they will be used, otherwise they will be computed on the fly using theMesh.compute_shape_functions()method withreturn_derivativesset toTrue.
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 inelement_indiceswill result in the corresponding contribution to the property derivatives being skipped (i.e., not added to the property derivative values). Default isTrue.default (Union[
Real,numpy.ndarray], optional) – The default value to assign to property derivatives for integration points associated with an element index of -1 whenskip_m1isTrue. Default isnumpy.nan. The input can also be anumpy.ndarrayof 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:
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.