https://123dok.org/document/8ydlp2ez-notes-numerical-methods-solving-optimal-control-problems.html