In this paper, we give the general solution of the functional equation
{∥f(x)+f(y)∥,∥f(x)−f(y)∥}={∥x+y∥,∥x−y∥}(x,y∈X) where f:X→Y and X,Y are inner product spaces. Related equations are
also considered. Our main tool is a real version of Wigner's
unitary--antiunitary theorem