Self-Driving Vehicle Control (ROB 599)

Problem Description:

Given the information of a track, design a control algorithm for a nonlinear bicycle model such that the car can (1) finish the track without collision as fast as possible (2) avoid obstacles generated randomly.

The Solution:

For the task one, we first approximated the track with piecewise linear functions. Then we used time-free nonlinear trajectory optimization to find feasible inputs for each piece of road. The cost function tried to minimize the time used for passing that piece of road as well as the distance b.w. the car and the centerline of the road. The difficulty for this part was that you needed to have a good guess of a feasible solution, otherwise it almost returned "no feasible solution" all the time. For a small piece of the road, it was good enough to set all the future steps as the initial condition of the car at that time point.

For the task two, we used the trajectory gotten from the previous task as the nominal trajectory and applied model predictive control to make the car avoid the obtacles. To have a larger time horizon such that the controller could 'see' the obtacles, we downsampled the nominal trajectory and the nominal control inputs. One problem in this task was that the optimal solution from quadratic programming wasn't consistent with the true trajectory given by ode45, for the car model had the stiffness problem, which made the forward Euler discretization in the optimization constraints unstable. But if the nominal trajectory was smooth enough, the error b.w. the ode45 and FE could be neglected. So some work was done for generating a smooth nominal trajectory. The simplest way to get a smooth trajectory was just to drive the car by yourself. Actually we finally used a 'hand-made' nominal trajectory in the task two.

My Contribution:

1. I was responsible for the math problems encountered in this project, such as how to form the optimization problems for trajectory optimization and MPC, how to transform the road into convex constraints and so on.

2. Implemented the time-free nonlinear trajectory code and figured out the 'good guess' in task one.

3. Implemented the framework of MPC for task two. Modified the cost function and tuned the parameters to make the algorithm more robust.