Let's have the following function $f:\mathbb{R}^{2}\to\mathbb{R}$ defined by $|x+y|$, is it convex? We have $\lambda\in (0,1),x,y\in$ dom$(f)$, so $|\lambda x+(1-\lambda)y|\le \lambda |x| + (1-\lambda)|y|$. It means the function is convex according to the definition of a convex function. Is it correct?
2026-03-27 07:47:40.1774597660
Is the function convex?
34 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
The function is convex, but your reasoning is a bit off (or at least a bit too terse, in my opinion). Remember, the elements of the domain of $f$ are pairs $(x,y) \in \mathbb R^2$. You need to show that for $(x,y), (z,w) \in \mathbb R^2$, you have $$f(\lambda \cdot (x,y) + (1-\lambda)\cdot (z,w)) \le \lambda f(x,y) + (1-\lambda)f(z,w).$$ In this case, we see \begin{align*} f(\lambda \cdot (x,y) + (1-\lambda)\cdot (z,w)) &= f(\lambda x + (1-\lambda)z, \lambda y + (1-\lambda)w) \\ &= \lvert \lambda x + (1-\lambda)z + \lambda y + (1-\lambda)w \rvert\\ &= \lvert \lambda(x+y) + (1-\lambda)(z+w)\rvert\\ &\le \lambda\lvert x+y \rvert + (1-\lambda) \lvert z+w \rvert \\ & = \lambda f(x,y) + (1-\lambda)f(z,w) \end{align*} which shows that $f$ is indeed convex.