diff --git a/control/autoware_mpc_lateral_controller/src/mpc_lateral_controller.cpp b/control/autoware_mpc_lateral_controller/src/mpc_lateral_controller.cpp index efa17e5236907..a42f6b7fc0d2d 100644 --- a/control/autoware_mpc_lateral_controller/src/mpc_lateral_controller.cpp +++ b/control/autoware_mpc_lateral_controller/src/mpc_lateral_controller.cpp @@ -524,7 +524,7 @@ bool MpcLateralController::isMpcConverged() // Find the maximum and minimum values of the steering angle in the past 1 second. double min_steering_value = m_mpc_steering_history[0].first.steering_tire_angle; - double max_steering_value = m_mpc_steering_history[0].first.steering_tire_angle; + double max_steering_value = min_steering_value; for (size_t i = 1; i < m_mpc_steering_history.size(); i++) { if (m_mpc_steering_history.at(i).first.steering_tire_angle < min_steering_value) { min_steering_value = m_mpc_steering_history.at(i).first.steering_tire_angle;