Skip to content

Commit

Permalink
fix(#17): fix of formula to calculate the z-coordinate of plane at x,…
Browse files Browse the repository at this point in the history
…y coordinates.
  • Loading branch information
Pablo Vasconez committed Nov 10, 2023
1 parent 648d8eb commit 68bddfa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plxcontroller/geometry_3d/operations_3d.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def project_vertically_point_onto_polygon_3d(
# point x and y coordinates input
a, b, c, d = plane.cartesian()
if not np.isclose(c, 0.0):
z = (d - a * point.x - b * point.y) / c
z = (-d - a * point.x - b * point.y) / c
else:
# if the coefficient c is close to zero, it means that
# the plane is parallel to the z-axis, so the z-coordinate
Expand Down

0 comments on commit 68bddfa

Please sign in to comment.