Lecture Notes Geometry and Optimization