We say the function $f$ is convex if :
$1)$ $f(λx+(1-λ)y) \le λf(x)+(1-λ)f(y)$ where $0 \le λ \le 1$
$2)$ $\frac{f(u)-f(s)}{u-s} \le \frac{f(t)-f(u)}{t-u}$ Where $s<u<t$
How can I prove that $2$ implies $1$ ?
We say the function $f$ is convex if :
$1)$ $f(λx+(1-λ)y) \le λf(x)+(1-λ)f(y)$ where $0 \le λ \le 1$
$2)$ $\frac{f(u)-f(s)}{u-s} \le \frac{f(t)-f(u)}{t-u}$ Where $s<u<t$
How can I prove that $2$ implies $1$ ?
Assume $y>x$ and let $u = \lambda x + (1- \lambda)y$. Then $x<u<y$, so we can apply (2) to get
$$\frac{f(u) - f(x)}{u-x} \leq \frac{f(y) - f(u)}{y-u}.$$
The rest of the proof is just algebra. Use the definition of $u$ in the inequality above and simplify. Can you finish?