We make use of two key facts. First, we have the factorisation $n^2 -1 = (n-1)(n+1)$. Second, when a square number is factorised, each prime factor appears an even number of times.

Now $2^2 -1 = 1\times 3$.

We next get a prime factor $3$ with $4^2-1= 3\times 5$.

We next get a prime factor $5$ with $6^2-1= 5\times 7$.

We next get a prime factor $7$ with $8^2-1= 7\times 9$.

As $9=3^2$, it does not require any further factors. Hence we need $n\geq 8$. Checking the product $n=8$, we get$$\eqalign{

(2^2 -1)(3^2 -1)(4^2 -1)(5^2 -1)(6^2 -1)(7^2 -1)(8^2 -1) &= 1\times 3\times 2\times4\times3\times5\times4\times6\times5\times7\times6\times8\times7\times9\cr

&= 2\times8 \times 3 \times 3\times4\times4\times5\times5\times6\times6\times7\times7\times3\times3\cr

&=4\times4\times3\times3\times4\times4\times5\times5\times6\times6\times7\times7\times3\times3\cr

&=(4\times3\times4\times5\times6\times7\times3)^2}$$

So in fact $n=8$ is sufficient, and is thus the minimum.

*This problem is taken from the UKMT Mathematical Challenges.**View the archive of all weekly problems grouped by curriculum topic*

View the current weekly problem