Real Algebraic Geometry and Optimization