# If $n^2+4n+10$ is a perfect square, then find the possible integer values of $n$.

If $n^2+4n+10$ is a perfect square, then find the possible integer values of $n$.

I couldn't understand what the question is asking me to do. I could only do one step that would equate it to $k^2$ after that I wasn't able to solve it.

## 6 Answers

Hint. What is $( n + 2 ) ^ 2$?

• Aren't we suppose to scale down the whole into a perfect square or just $(n+2)^2+6$ would be fine? – The Dead Legend May 9 '17 at 12:21
• @TheDeadLegend: The point is that we're now looking for two perfect squares with a difference of $6$. I don't know which "scale down" you're talking about. – hmakholm left over Monica May 9 '17 at 12:22

Let $$n^2+4n+10 = k^2$$

Then $$k^2-(n+2)^2=6$$

$$\implies k^2=6+(n+2)^2$$

Since $$k^2 \equiv 0~ \text{or} ~1 \pmod4$$

And ,$$6+(n+2)^2 \equiv 2~ \text{or} ~3 \pmod4$$

No solution!

Write $n^2+4n+10 = m^2$. Then $6=m^2-(n+2)^2=(m+n+2)(m-n-2)$.

Now $6=ab=(\pm 1)(\pm 6)$ and $6=(\pm 2)(\pm 3)$ are the only possible factorizations of $6$.

Therefore, we need to solve $m+n+2 = a, m-n-2=b$ for $m,n$.

However, the determinant is $-2$ and we'd need $a,b$ to have the same parity, which never happens. Therefore, there are no integer solutions.

The same argument proves that an integer is the difference of two integer squares iff it is odd or a multiple of $4$.

• Instead of factoring $6$, it is probably just as easy to note that the gaps between successive squares from $9$ onwards are larger than $6$, and clearly none of $0,1,4,9$ have the desired difference. – hmakholm left over Monica May 9 '17 at 12:28
• @HenningMakholm. right, but my approach leads to solutions in other cases, and a characterization of difference of two squares. – lhf May 9 '17 at 13:06
• @lhf We can also use congruences to prove that there is no solution, as I have done in my answer. – Jaideep Khare May 9 '17 at 13:08

Clearly there are no positive integer solutions because we see from the inequality below that $k^{2}= (n+2)^{2}+6$ lies strictly between two consecutive squares:

$(n+2)^{2} < k^{2}<(n+3)^{2}$

It's easy to manually check that $n=-1,-2,-3,-4$ also fail to make $(n+2)^{2}+6$ a perfect square. The absence of all other negative integer solutions is similarly seen by setting $n=-m,$ for $m \in \mathbb{N}$ and by noting that $\forall \, m\geq 5$ we have:

$(m-2)^{2}<(m-2)^{2}+6<(m-1)^{2}$

• $n$ isn't given to be positive, this inequality isn't always true. – Jaideep Khare May 9 '17 at 13:56
• Thanks for catching that @JaideepKhare. I extended the same argument to take care of negative integers. – Aryaman Jal May 9 '17 at 14:19
• $m=4$ doesn't satisfy last inequality. – Takahiro Waki May 9 '17 at 14:57
• @TakahiroWaki Yes, corrected that. Equality holds for $m=4.5$ and I rounded down by mistake – Aryaman Jal May 9 '17 at 15:11

If $ax^2 + bx + c$ is a perfect square, then there exists only one solution to $ax^2 + bx + c = 0$ as it can then be written as $(x + p)^2$ for some p. This means $b^2 = 4ac$. But in the given equation it is not true ($4^2 != 4*10$), therefore the given equation can never be a perfect square for any real n.

For integers $n,k$ we have $$n^2+4n+10=k^2\implies |k|^2=6+|n+2|^2\implies$$ $$\implies |k|>|n+2|\implies |k|\geq 1+|n+2|\implies$$ $$\implies 6=|k|^2-|n+2|^2\geq (1+|n+2|)^2-|n+2|^2=1+2|n+2|\implies$$ $$\implies 6\geq 1+2|n+2|\implies 5\geq 2|n+2|\implies$$ $$\implies 2+\frac {1}{2}\geq |n+2|\implies 2\geq |n+2|\implies$$ $$\implies |n+2| \in \{0,1,2\} \implies |n+2|^2\in \{0,1,4\}\implies$$ $$\implies|k|^2=6+|n+2|^2\in \{6,7,10\}\implies 1=0.$$