Open afibacer opened 5 years ago
Dear Sir,
In Apollo MPC control code, we have two parts, feedforward and feedback. feedback term is result of MPC solver.
Following is the feedforward code.
void MPCController::FeedforwardUpdate(SimpleMPCDebug debug) { const double v = VehicleStateProvider::Instance()->linearvelocity(); const double kv = lr mass / 2 / cf / wheelbase - lf mass / 2 / cr / wheelbase_; steer_anglefeedforwardterm = Wheel2SteerPct( wheelbase_ debug->curvature() + kv v v * debug->curvature()); }
Do you have any reference why feedforward term is set like this? Thanks.
Please refer to this book vehicel dynamic and control.
Dear Sir,
In Apollo MPC control code, we have two parts, feedforward and feedback. feedback term is result of MPC solver.
Following is the feedforward code.
void MPCController::FeedforwardUpdate(SimpleMPCDebug debug) { const double v = VehicleStateProvider::Instance()->linearvelocity(); const double kv = lr mass / 2 / cf / wheelbase - lf mass / 2 / cr / wheelbase_; steer_anglefeedforwardterm = Wheel2SteerPct( wheelbase_ debug->curvature() + kv v v * debug->curvature()); }
Do you have any reference why feedforward term is set like this? Thanks.