TITLE: Prove that if $f^2(x+y)+f^2(x-y)=2f^2(x)+2f^2(y)$ then $f(x+y) \leq f(x)+f(y)$ for all $x,y \in \mathbb R$
QUESTION [5 upvotes]: Let $f: \mathbb{R} \rightarrow [0, \infty)$ be a function that:
$$f^2(x+y)+f^2(x-y)=2f^2(x)+2f^2(y) \forall x,y \in \mathbb{R}$$
Prove that $f(x+y) \leq f(x)+f(y) \forall x,y \in \mathbb{R}$
This problem is from this AOPS link.
Let $x=y=0$,then $f(0)=0$. then let $x=y$,we have
$$f^2(2x)=4f^2(x)\Longrightarrow f(2x)=2f(x)$$
let $x=2y$,then we have
$$f^2(3y)+f^2(y)=2f^2(2y)+2f^2(y)=10f^2(y)\Longrightarrow f(3x)=3f(x)$$
let $x=3y$ then we have $f(4x)=4f(x)$,and use induction we have
$$f(kx)=kf(x),\forall k\in N^{+}$$ then I can't it

REPLY [4 votes]: This is a standard result in linear algebra. Here I write a solution accessible to high school students, as the question is originally posted as a high school contest question.
You have already shown that $f(kz) = kf(z)$ for all $k \in \Bbb Z_{\geq 0}$ and all $z \in \Bbb R$.
Let $x, y$ be any real number.
If $f(x) = f(y) = 0$, then we have $f(x + y)^2 + f(x - y)^2 = 0$ and hence $f(x + y) = 0$.
Thus in the following we assume without loss of generality that $f(y) \neq 0$.
We write $p = \frac 1 2(f(x + y)^2 - f(x)^2 - f(y)^2)$ and prove by induction on $m + n$ that $$f(mx + ny)^2 = m^2f(x)^2 + 2mnp + n^2f(y)^2\tag{*}$$ for all nonnegative integers $m, n$.
The claim is clearly true for $m + n \leq 2$. When $m + n \geq 3$, we assume without loss of generality that $m \geq 2$ and use the original functional equation with $x, y$ replaced with $(m - 1)x + ny$ and $x$ to finish the inductive step.
We have thus proved $(*)$ for all nonnegative integers $m, n$. Using the original functional equation with $x, y$ replaced with $mx, ny$, we see that $(*)$ is in fact true for all $m \in \Bbb Z_{\geq 0}$ and all $n \in \Bbb Z$.
Applying the identity $f(kz) = kf(z)$, we have $f(x + \lambda y)^2 = f(x)^2 + 2\lambda p + \lambda^2f(y)^2$ for all rational number $\lambda$.
Thus we know that the quadratic polynomial $Q(\lambda) = f(y)^2 \lambda^2 + 2p\lambda + f(x)^2$ takes nonnegative values for all rational number $\lambda$.
This is only possible when its discriminant is not positive. Therefore we have $p^2 \leq f(x)^2f(y)^2$, or equivalently, $|p| \leq f(x)f(y)$.
Consequently, we have $f(x + y)^2 = f(x)^2 + 2p + f(y)^2 \leq (f(x) + f(y))^2$ and hence $f(x + y) \leq f(x) + f(y)$.