I try to prove the second order condition for convexity.
So far' I've done the following:
First, I prove second order => convexity:
Let $f$ be a function with positive semi-definite Hessian. Using second order Taylor expansion I have:
$f(y) = f(x)+\nabla f(x)^T(y-x)+(y-x)^T \nabla^2f(x+a(y-x))(y-x)$ for some value of $a \in [0,1]$. Let's note this by (*).
Now, since the Hessian is positive semi-definite, $(y-x)^T \nabla ^2f(x+a(y-x))(y-x) \geq 0$. Let's note this by (**).
Now I can use (*) and (**) to prove that $f$ is convex. (*) and (**) => $f(y) \geq f(x) + \nabla f(x)^T(y-x)$ => $f$ is convex by the first order of convexity. Q.E.D. (The second direction is quite similar).
Now, my question is how to formally prove (*) and (**). I know it's follows from Taylor's theorem and Lagrange form of the reminder.