Are the standard rules for determining convexity of composition of 2 functions all encompassing?
While going through Boyd & Vandenberghe's Convex Optimization, I saw the following rules, where $f(x) = (h \circ g)(x)$.
-
$f$ is convex if $h$ is convex, $\tilde{h}$ is nondecreasing, and $g$ is convex
-
$f$ is convex if $h$ is convex, $\tilde{h}$ is nonincreasing, and $g$ is concave
-
$f$ is concave if $h$ is concave, $\tilde{h}$ is nondecreasing, and $g$ is concave
-
$f$ is concave if $h$ is concave, $\tilde{h}$ is nonincreasing, and $g$ is convex
Consider the convexity of $f(x)= \sqrt{ 1 + x^2 }$, here $h(x)=\sqrt{x}$ and $g(x)=1+x^2$. The extended value extension $h̃$ is $h=-\infty$ for $x<0.$
Clearly, $h$ is concave and nondecreasing, and $g$ is a convex function.
I want to know if the the above rules are if and only if, i.e if the function does not fit in any of the above conditions, can it still be convex?
Solution 1:
Okay, so if the conditions don't fit, the function might still be convex or concave. Consider f to be twice differentiable (not actually necessary, just to illustrate why this is true).
$$f=h(g(x))$$
$$f''(x)=g'(x)^2h''(g(x))+h′(g(x))g''(x).$$
Clearly, the conditions above correspond to both of the terms being individually positive. There can also be the case where one is positive and the other negative, but one is more positive than the other, making the term $f''(x)$ positive, and $f(x)$ convex, while not being included in the cases above.