weldx.transformations.orientation_point_plane_containing_origin#

weldx.transformations.orientation_point_plane_containing_origin(point, p_a, p_b)#

Determine a points orientation relative to a plane containing the origin.

The side is defined by the winding order of the triangle ‘origin - A - B’. When looking at it from the left-hand side, the ordering is clockwise and counter-clockwise when looking from the right-hand side.

The function returns 1 if the point lies left of the plane, -1 if it is on the right and 0 if it lies on the plane.

Note, that this function is not appropriate to check if a point lies on a plane since it has no tolerance to compensate for numerical errors.

Additional note: The points A and B can also been considered as two vectors spanning the plane.

Parameters:
  • point – Point

  • p_a – Second point of the triangle ‘origin - A - B’.

  • p_b – Third point of the triangle ‘origin - A - B’.

Returns:

1, -1 or 0 (see description)

Return type:

int