I've never had to do this before, so I'm not really sure how to do it. These problems also don't even really relate to what the subject of the book is as well.
Given: $f(px+(1-p)y)\le pf(x)+(1-p)f(y)$
Consider the function
$f(x)\left\{ \begin{array}{cc} x & x\le1\\ 2-x & x>1\end{array}\right\} $
Show that $f(x)$ is convex on $-\infty < x \le 1$ and convex on $1 < x < \infty$ but not convex on $-\infty < x < \infty$
Another problem using the same convex definition:
Suppose $f(x)$ is defined on the interval I. If $x_{1} Thanks Edit: Im not sure how to use the definition. Thats kind of where i am stuck. I'm sure it's easy, but like i said i've never seen this before, the book has nothing to do with this, it's just randomly thrown in here. There are no examples for this either.