# Is a jointly convex function of x and y convex as a function of x when y=z(x)?

Hi,

Suppose that $x \in R^m, y \in R^n, z(x) \in R^n$, and $f(x,y)$ is convex in $(x,y)$.

Is $f(x,z(x))$ a convex function in $x$ for arbitrary continuous functions $z(x)$?

Thanks!

-
Not appropriate for MathOverflow. –  Igor Rivin Aug 31 '12 at 19:27

Here is a counterexample for $m=n=1$. Let $f(x,y)=x^2+y^2$ which is convex, and let $z(x)$ be continuous such that $z(0)=0$, $z(1)=2$, $z(2)=1$. Then $$2f(1,z(1))=10>0+5=f(0,z(0))+f(2,z(2)),$$ hence $f(x,z(x))$ is not convex.