mirror of
https://github.com/AtsushiSakai/PythonRobotics.git
synced 2026-01-13 11:38:27 -05:00
Replaced sqrt(x**2+y**2) with hypot in PathPlanning/DubinsPath/dubins_path_planning.py
This commit is contained in:
@@ -141,7 +141,7 @@ def dubins_path_planning_from_origin(ex, ey, eyaw, c, D_ANGLE):
|
||||
# normalize
|
||||
dx = ex
|
||||
dy = ey
|
||||
D = math.sqrt(dx ** 2.0 + dy ** 2.0)
|
||||
D = math.hypot(dx, dy)
|
||||
d = D * c
|
||||
# print(dx, dy, D, d)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user