Pointwise maximum of convex functions (source code)

= Pointwise maximum of convex functions

The pointwise maximum of finitely many convex functions is convex because
$$
\max_i f_i(tx+(1-t)y)
\leq t\max_i f_i(x)+(1-t)\max_i f_i(y).
$$