Study the GPS tracking problem described on slides 22-26 in this lecture (from Predictive Control 2012).
Here is the Matlab code for producing the trade-off comparison figure. Make sure you understand the code and the performance trade-off between noise suppression and tracking speed that the lecture slides illustrate.
Your task is to implement a (non-causal) 5-time step smoother, and tune it to get an improved filter, giving a faster response during the turn taking when the direction changes abruptly. You should be able to achive performance similar to what is presented on slide 26.
As a help, you have this Matlab code (which is quite ugly, I know...). It is missing two critical lines, which you need to figure out.
A Julia solution of the assignment is encouraged and appreciated.