how would you show that $$f(x) = argmax_{yinmathbb{R}}{ay+bx+c-left|left|y-xright|right|^2}$$ is continuous? It is well defined since the expression under argmax is strictly concave and thus is has just one maximum. But why the continuity?

I feel it is very simple but I just can’t figure it out. I kindly ask for a hint.

## Answer

Firstly, the expression inside argmax is not convex, it is concave. Secondly, you can find an analytical solution for $f(x)$ by expanding the quadratic term and complete the square involving $y$.