Linear optimal control problems Geometry and constraints mathematics