Dear professor,
I think it may be better to add the notice in this lecture note that we can't use different variable notation other than "x" ("b" for example" when we want to get the value which achieves the optimal value.
When I did the least square optimization problem, I used letter b to represent variable, and surely it generated error when I run "sol.b". The situation is different from the that we did in the IVP lecture. So I think it's better to clarify this in the Optimization lecture.