Show that $f:\mathbb{R}^2\to\mathbb{R}$, $f \in C^{2}$ satisfies the equation $$\frac{\partial^2 f}{\partial x^2} - \frac{\partial^2 f}{\partial y^2} = 0$$ for all points $(x,y) \in \mathbb{R}^2$ if and only if for all $(x,y)\in \mathbb{R}^2$ and $t \in \mathbb{R}$ we have: $$f(x, y + 2t) + f(x, y) = f(x + t,y + t) + f(x - t, y +t).$$
Note. In such case, $f$ is said to satisfy the parallelogram's law.
First assume that (replacing $y$ by $y-t$ in the assumption) $$ f(x, y + t) + f(x, y) = f(x + t,y) + f(x - t, y -t), $$ for all $t,x,y\in\mathbb R$. This implies that $$ \frac{f(x, y + t) -2f(x,y)+ f(x, y-t)}{t^2} = \frac{f(x + t,y)-2f(x,y) + f(x - t, y)}{t^2}, $$ for $x,y\in\mathbb R$ and $t\ne 0$. We shall now explain why, the left hand side tends to $f_{yy}(x,y)$, while the right hand side tends to $f_{xx}(x,y)$, as $t\to 0$. In general, if $g$ is $C^2$, then \begin{align} \frac{g(x+h)-2g(x)+g(x-h)}{h^2}&=\frac{\int_0^h g'(x+t)\,dt-\int_0^h g'(x-h+t)\,dt}{h^2}\\ &=\frac{\int_0^h\int_0^h g''(x-h+t+s)\,ds\,dt}{h^2}\to g''(x), \end{align} when $h\to 0$, as $g''$ is continuous.
Assume now that $f_{xx}(x,y)=f_{yy}(x,y)$. We shall use the following fact:
Fact. If $g_x=g_y$, then $g$ is of the form $g(x,y)=h(x+y)$.
Let now $F(x,y)=f_x(x,y)+f_y(x,y)$. Clearly, $$ F_x-F_y=(f_x+f_y)_x-(f_x+f_y)_y=f_{xx}+f_{yx}-f_{xy}-f_{yy}=f_{xx}-f_{yy}=0, $$ as $f_{xy}=f_{yx}$ since $f$ is $C^2$. Thus, using the above fact, $F(x,y)=H(x+y)$, where $H\in C^1$. Thus $$ f_x(x,y)+f_y(x,y)=H(x+y). $$ Now, let see how $f$ behaves along lines of the form $x-y=s$, parametrised as $x=t+s, y=t$. Then $$ \frac{d}{dt}f\big(x(t),y(t)\big)=\frac{d}{dt}f(t+s,t)=f_x(t+s,t)+f_y(t+s,t)=H(2t+s), $$ and thus $$ f(t+s,t)-f(s,0)=\int_0^t H(2\tau+s)\,d\tau, $$ or, setting $x=s+t$ and $y=t$ $$ f(x,y)=f(x-y,0)+\int_0^{y} H(2\tau+x-y)\,d\tau. $$ If $g'=H$, then \begin{align} f(x,y)&=f(x-y,0)+\int_0^{y} H(2\tau+x-y)\,d\tau =f(x-y,0)+\left.\frac{1}{2}g(2\tau+x-y)\right|_0^y\\ &= f(x-y,0)+\frac{1}{2}g(2y+x-y)-\frac{1}{2}g(x-y)=f_1(x-y)+f_2(x+y), \end{align} where $$ f_1(x)=f(x,0)-\frac{1}{2}g(x) \quad\text{and}\quad f_2(x)=\frac{1}{2}g(x). $$
Proof of the Fact. Fix $s\in\mathbb R$ and Let $\big(x(t),y(t)\big)=(t,s-t)$, $t\in\mathbb R$. Then $$ \frac{d}{dt}g\big(x(t),y(t)\big)=\frac{d}{dt}g(t,s-t)=g_x-g_y=0. $$ Thus $g(t,s-t)=g(0,s)$. Now $t=x$ and $s=x+y$, and therefore $$ g(x,y)=g(t,s-t)=g(0,s)=g(0,x+y)=H(x+y). $$