Description
In src/traj_builder.cpp, the variable ramp_up_dist is calculated using alpha_max_ (angular acceleration) instead of accel_max_ (linear acceleration).
This is a dimensional mismatch: speed_max_^2 / alpha_max_ results in m^2/rad, whereas a distance calculation requires m. This logic error occurs when determining whether to use a trapezoidal or triangular velocity profile for straight-line motion.
Location
|
double ramp_up_dist = 0.5 * speed_max_ * speed_max_ / alpha_max_; |
Proposed Solution
Replace the angular acceleration parameter with the linear acceleration parameter:
// Corrected Implementation
double ramp_up_dist = 0.5 * speed_max_ * speed_max_ / accel_max_;
Additional context
This issue was automatically flagged by our experimental LLM-assisted dimensional analysis tool and manually verified.
Description
In
src/traj_builder.cpp, the variableramp_up_distis calculated usingalpha_max_(angular acceleration) instead ofaccel_max_(linear acceleration).This is a dimensional mismatch:
speed_max_^2 / alpha_max_results inm^2/rad, whereas a distance calculation requiresm. This logic error occurs when determining whether to use a trapezoidal or triangular velocity profile for straight-line motion.Location
learning_ros/Part_4/traj_builder/src/traj_builder.cpp
Line 215 in c98c8a0
Proposed Solution
Replace the angular acceleration parameter with the linear acceleration parameter:
Additional context
This issue was automatically flagged by our experimental LLM-assisted dimensional analysis tool and manually verified.