How does one show that the quadratic forms $x^2 + 3 y^2$ and $x^2 + x y + y^2$ represent the same set of integers?
I think it relates to a classical result of Euler about primes of form $6k+1$. In fact a positive integer $n$ is of the form $x^2 + 3 y^2$ if and only if the the primes $\equiv -1 \mod 3$ have an even exponent in $n$. Similarly for $x^2 + x y + y^2$.
However somebody told me that this can be shown without so much number theoretical background. Any ideas would be appreciated!
Just to deal easily with parity, you can see that if $f(x,y)=x^2+xy+y^2$, then $$f(x,y)=f(y,x)=f(-x-y,y)=f(-x-y,x)=f(x,-x-y)=f(y,-x-y)$$
So you can always assume that $x$ is even in $f(x,y)$, because if it's not, just consider $f(y,x)$ or $f(-x-y,y)$ (and either $y$ or $-x-y$ is even).
So $g(x,y)=4x^2+2xy+y^2$ has the same image in $\mathbb Z^2$ than $f$
But as it was explained in previous comments/answers, $$g(x,y)=(x+y)^2+3x^2$$
And if $u=x+y$ and $v=x$ then $x=v$ and $y=u-v$ this is a reversible transformation, so $g$ and $h(u,v)=u^2+3v^2$ has the same image.