Find the minimum of $\frac{a^2+b^2}{2}-\frac{|a-b|}{2}\sqrt{1+(a+b)^2}$ When $a\neq b$ $a,b\in\mathbb{R}$
find the minimum of
$\frac{a^2+b^2}{2}-\frac{|a-b|}{2}\sqrt{1+(a+b)^2}$
I think that the answer is $-\frac{1}{4}$ but not sure.
Please tell me a solution.
 A: Since swapping $a$ and $b$ does not change the value of the expression, let's restrict ourselves only to solutions where $a\geq b$. This allows us to rewrite $|a-b|$ as $a-b$, which makes our expression much easier to deal with.
Let $c=\frac{a+b}{2}$ and $d=\frac{a-b}{2}$. Then $c$ can be any real number, and $d$ can be any non-negative real. Written in terms of $c$ and $d$, our expression becomes:
$c^2 + d^2 - d\sqrt{4c^2+1}$
Differentiating with respect to $d$ gives $2d - \sqrt{4c^2+1}$. This is zero when $d = \sqrt{c^2 + 1/4}$ which means this value of $d$ minimises the expression.
If you plug this value of $d$ into the expression, the $c$s cancel out and the expression reaches its minimum value of $-1/4$ as you suggested.
If you have a particular value for $a$ and you want a corressponding value of $b$ that achieves this minimum, remember that $a=c+d$ and $d = \sqrt{c^2 + 1/4}$. Solving this gives $c=\frac{a}{2}-\frac{1}{8a}$ and $d=\frac{a}{2}+\frac{1}{8a}$. We get $b=c-d =-\frac{1}{4a}$. This only works if this value of $b$ is less than or equal to $a$, which we see is only when $a>0$.
