https://medium.com/@monocosmo77/how-and-where-constrained-least-squares-is-used-part1-machine-learning-optimization-675b9af8919d