I am now trying to solve the question that proving $$f(x,y) = |xy| + a(x^2 + y^2) \text{ is convex if and only if } a \ge 1/2$$ Proof of that $f(x,y) = |xy| + a(x^2 + y^2)$ is convex when $a \ge 1/2$ is provided in another question. I have tried to code some program for visualizing the convexity on some line $y=kx+b$ of function $f(x,y)$ which has the same convexity of the $f(x,y)$. But the plot I draw all seems to have the convexity so far. I am also wondering what is the usual way to prove that a function is not convex.
2026-03-27 16:39:46.1774629586
Proving $f(x,y) = |xy| + a(x^2 + y^2)$ is convex if and only if $a \ge 1/2$
73 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
1
If $f(x,y)$ is convex so it must be that $$f(\lambda(1,0)+(1-\lambda)(0,1))\le\lambda f(1,0)+(1-\lambda)f(0,1)$$or$$\lambda(1-\lambda)+a(\lambda^2+(1-\lambda)^2)\le a$$which leads to $$a\ge \dfrac{1}{2}$$so this constraint is necessary. Next we prove that this is also sufficient. If $a\ge \dfrac{1}{2}$ we have$$f(x,y)=(a-\dfrac{1}{2})(x^2+y^2)+\dfrac{1}{2}(|x|+|y|)^2$$which is convex since both $(a-\dfrac{1}{2})(x^2+y^2)$ and $\dfrac{1}{2}(|x|+|y|)^2$ are convex and summation of two convex functions always is a convex function. So the condition $a\ge\dfrac{1}{2}$ is necessary and sufficient.
Here is a sketch for $a=\dfrac{1}{2}$