I am trying to solve the equation $937=x^2+24x+24y+y^2$, where x and y are integers. What I've tried is changing the right side of the equation to $$(x+y)^2-2xy+24x+24y$$ $$(x+y)^2-2(x+y)(-12)+xy$$ $$(x+y)((x+y)++24+x+y)$$ $$2(x+y)(x+12+y)$$
and then trying to find integers that fit into the equation but it doesn't seem like the most efficient or proper way to solve this equation. Any suggestions?
Complete the square in each of the $x$ and $y$ quadratics:
$$\begin{align} (x^2+24x+144)+(y^2+24y+144)=937+288&=1225 \\ (x+12)^2+(y+12)^2=35^2 \end{align}$$
So we are seeking Pythagorean triples where the triangle has two sides of length $x+12,y+12$ and a hypotenuse of $35$. Irreducible Pythagorean triples are of the form:
$$(m^2-n^2,2mn,m^2+n^2)$$
The only primitive triples relevant here are those with $m^2+n^2\in\{5,7,35\}$ because these are all the factors of $35$ larger than one, and so are the only ones that can be scaled up to obtain a triangle with hypotenuse $35$.
The only one with integer solutions is $m^2+n^2=5 \implies m=2,n=1$ ($7$ and $35$ are of the form $4k+3$ so cannot be a sum of two integer squares) from which we have the primitive triple $(3,4,5)$. So
$$\begin{align} &3^2+4^2=5^2 \\ &\implies 21^2+28^2=35^2 \\ &\implies (\pm21)^2+(\pm28)^2=35^2 \\ &\implies (x+12,y+12)\in\{(21,28),(-21,28),(21,-28),(-21,-28),(28,21),(-28,21),(28,-21),(-28,-21)\} \\ &\implies (x,y)\in\{(9,16),(-33,16),(9,-40),(-33,-40),(16,9),(-40,9),(16,-33),(-40,-33)\} \end{align}$$
[Update]
As $\color{blue}{\text{coffeemath}}$ has pointed out, there are also trivial solutions (not Pythagorean triples) to the original equation, i.e.
$$(x+12,y+12)\in\{(\pm35,0),(0,\pm35)\}$$
whence
$$(x,y)\in\{(-47,-12),(23,-12),(-12,-47),(-12,23)\}$$
are also solutions.