We received lots of correct answers to the first part of the problem.

An anonymous solver used a trial-and-improvement method:

First I added the two 15s which gave me a total of 30 so I knew that the square number and its square root had to have a difference of 30. So I tried out 5 squared = 25 but there was a difference of only 20 so next I tried 6 squared which gave me 36 and that had a difference of 30. So I halved 30 which gave me 15 and I added that to 6 and the answer was 21. So he/she is 21 years old.

Aporva used a neat numerical method:

To solve this problem, I wrote down the square numbers:

1, 4, 9, 16, 25, 36, 49, 64, 81, 100

Then, I crossed out all the numbers under 30, since my age couldn't be negative.

This left: 36, 49, 64, 81, 100

Then, I took away 30 from all the numbers, squared it, and looked if it was the same number.

If it was, I took away 15 from the square number to find my age.

$36 - 30 = 6, 6^2$ DOES equal $36, 36 - 15 = 21$

Therefore, my age must be 21

$49 - 30 = 19, 19^2$ DOES NOT equal $49$.

I realised that it was not logical to go on since I had the answer and since the the numbers where getting too big.

Kamal from St John's and Milena from Colegio Desafio in Brazil used algebra to solve the problem. Here is Milena's solution:

We can solve the problems which are presented to us through quadratic equations. For the first one, for instance:

$x + 15=(x - 15)^2$

$x + 15 = x^2 - 30x + 225$

$x^2 - 31x + 210 = 0$

Using the quadratic equation formula,

$x= \frac{31 \pm \sqrt{31^2 - 4\times1\times210}}{2 \times 1}$

$x = \frac{(31 +11)}{2} = 21$ or $x = \frac{(31 - 11)}{2} = 10$

As he had a birthday 15 years ago, he cannot be 10 years old so his age is 21.

It can be verified: $21 - 15 =6, 21 + 15 = 36, 6^2 = 36$

In order to find out if we can do with a number what was done with 15, we have to first think of a number and its square. Then, we have to subtract them; the result will always be even, for the square of an even number is always even and the square of an odd number is always odd. After that, we divide the result by two and add this quantity to the number with which we started.

For an age $y$ and an integer $x$, $y = x+ \frac{x^2 - x}{2}$

For example, $6 + \frac{6^2 - 6}{2} = 6 + \frac{36 - 6}{2} = 6 + 15 = 21$

I calculated it for different numbers:

$2 + \frac{2^2 - 2}{2} = 2 + \frac{4 - 2}{2} = 2 + 1 = 3$

$3 + \frac{3^2 - 3}{2} = 3 + \frac{9 - 3}{2} = 3 + 3 = 6$

$4 + \frac{4^2 - 4}{2} = 4 + \frac{16 - 4}{2} = 4 + 6 = 10$

$5 + \frac{5^2 - 5}{2} = 5 + \frac{25 - 5}{2} = 5 + 10 = 15$

Interestingly, I noted that the age y is always the sum of all integers from 1 up to the number which is represented by x in the equation:

$3 = 1 + 2 $

$6 = 1 + 2 + 3$

$10 = 1 + 2 + 3 + 4 $

$15 = 1 + 2 + 3 + 4 + 5 $

$21 = 1 + 2 + 3 + 4 + 5 + 6 $

Aurimas from Chatham Grammar School, Rajeev from Haberdashers' Aske's School, Ben from Hethersett High School and Shivin from the British School in Manila, also spotted that special birthdays occur when your age is a triangular number.

Connor from Gladesmore School described a way to work out the special birthdays:

Find the age squared, for example $6^2 = 36$, and then subract your original number: $36 - 6=30$.

Then halve this and add it to your original number: $\frac{30}{2}=15, 6+15=21$.

Using algebra to express this gives:

$$\frac{n^2-n}{2} + n = \frac{1}{2}n^2 + \frac{1}{2}n$$

Muntej from Wilson's School explained how he worked out that the age had to be a triangular number:

This problem will only work if your age is a triangular number.

Why?

If I start by doing the squares of various numbers with the difference between the square number and its root:

$3\times3=9$ difference $6$

$4\times4=16$ difference $12$

$5\times5=25$ difference $20$

Now halve the differences: $\frac{6}{2}=3, \frac{12}{2}=6, \frac{20}{2}10$

We can see a pattern emerging. When the difference is halved, the sequence of triangular numbers appears. We must use the difference as the age is halfway between the square and the square root. The triangular numbers are always halfway between a square number and its root, therefore "in N years time my age will be the square of how old I was N years ago" only works if N is a triangular number.

Toby from Repton School used algebra to explain:

Using the quadratic equation formula:

$$x=\frac{-b \pm \sqrt{b^2-4ac}}{2a}$$

$x$ is a whole number if $b^2-4ac$ is a square number.

$(x-n)^2=x+n$ rearranges to give $x^2-(2n+1)x+(n^2-n)$.

So $x$ is a whole number if $(2n+1)^2-4(n^2-n)$ is a square number.

So $8n+1$ must be a square number.

As $8n+1$ is clearly odd, our square number must be odd, $2r+1$, say.

$$8n+1 = (2r+1)^2$$

$$\Rightarrow 8n = (2r+1)^2-1$$

$$\Rightarrow 8n = (2r+1+1)(2r+1-1)$$

$$\Rightarrow 8n = (2r+2)(2r)$$

$$\Rightarrow n=\frac{4r(r+1)}{8} = \frac{r(r+1)}{2}$$

Therefore the birthdays that are special are triangular numbers.

Suzie from St Saviours & St Olaves also used algebra and imagined the three ages in the problem as the ages of three different people:

My age is $21$. $(21 - 15 = 6, 21 + 15 = 36)$

$A$, $B$ and $C$ are three people that fill the same rules, so if $A$ is $6$, $B$ is $21$ and $C$ is $36$ then these three people could have stood in for me in the initial problem

Looked at from $B$'s point of view this problem always looks difficult, but from $A$'s point of view $A$'s age is $n$ (any number); $C$'s age is $n \times n$ and $B$'s age is $\frac{C - A}{2} + A = \frac{n^2 - n}{2} + n = \frac{n(n+1)}{2}$

So, for every age of $A$, $n$, there is a person aged $B$, $\frac{n(n+1)}{2}$, and a person aged $C$, $n^2$, and the differences between the ages is $\frac{n(n-1)}{2}$.

Finally, Daniel from Savile Park Primary sent us this solution.