You may also like

problem icon

2-digit Square

A 2-Digit number is squared. When this 2-digit number is reversed and squared, the difference between the squares is also a square. What is the 2-digit number?

problem icon

Consecutive Squares

The squares of any 8 consecutive numbers can be arranged into two sets of four numbers with the same sum. True of false?

problem icon

Plus Minus

Can you explain the surprising results Jo found when she calculated the difference between square numbers?

Hollow Squares

Age 14 to 16 Challenge Level:

Kunal from Ecole Internationale de Manosque in France used Charlie's method to find the numbers of dots in the first hollow squares:


Pablo from King's College Alicante in Spain and Adithya from Hymers College in the UK both used Charlie's method and some algebra. This is Pablo's working:
Since they are two squares, one inside the other, we can express the total number of soldiers as a difference of squares. In this case:
$20^2 - 8^2$ and $16^2 -10^2$

A simpler version of the difference of squares is $a^2-b^2 = (a+b)(a-b)$
$20^2 - 8^2 = (20+8)(20-8) = 28\times12 = 336$
$16^2 - 10^2 = (16+10)(16-10) = 26\times6 = 156$

Persassy from Annie Gale School in Canada sent in a method for finding hollow squares using $960$ soldiers:
1) The side lengths (large-small) must equal an even number

2) The difference between the large and small square areas must be the
number ($960$)

Solving (where I started)
e.g., the square root of $960$ is $30.98...$
$961-960=1,$ and $961-1=960$ (even number, can have equal "walls" around)
$1$ is also a perfect square

Then, I would move to the next number for the outside length (in this case
$32,$ and would continue with the multiplying ($32\times32=1024$))

e.g., $33$
$1089-960= 129$
because it is not a whole number, it isn't an applicable hollow square formation.

Adam from Nower Hill High School in the UK also used a detailed trial approach. Click here to see Adam's work.

Jonathan from Chairo Christian School in Australia and 10Ma1 at Woodrush High in England also found some solutions for 960 soldiers. This is 10Ma1's work and observations.
For 960 soldiers we found 5 solutions for a symmetrical hollow square.
These pairs were:
31 and 1
32 and 8
34 and 14
38 and 22
46 and 34
We then looked for patterns and noticed all but 1 pair had a difference in multiples of 4.
We then decided that all multiples of 4 would work for the value of $n$ (the total number of soldiers).

Tony and Laurenc from Greenacre Public School in Australia, Agathiyan from Hymers College in the UK, Parth, Nicolas and Zawad from Perth Modern School in Australia, Weijie from BSKL in Malaysia and Sumayyah, Anshika, Shyam, Hafsah and Suhasini from Nower Hill High School in the UK all used Alison's method to find hollow squares using $960$ soldiers. Anskih'a work is shown below. At the bottom, when listing the possibilities for the hollow squares, Anshika has forgotten to put $^2$ outside the brackets, but otherwise the work is correct.


Pablo used a different method to get to $240$, and Pablo's method explains 10Ma1's assertion that mutliples of $4$ can be divided into symmertrical hollow squares. This is Pablo's diagram and working:
If we divide the square up like in the picture, we can say that:
$$\begin{align}(a+b)^2-(b-a)^2 =& 960\\
[(a+b)+(b-a)][(a+b)-(b-a)] =& 960\\
[(a+b)+(b-a)] = b + b + a - a = 2b\\
[(a+b)-(b-a)] = b - b + a + a = 2a\\
(2b)(2a) =& 960\\
4ab = &960\\
ab = &240\end{align}$$
$$4ab = [\text{Number of Soldiers}]$$From this we can see that only battalions with sizes that are multiples of $4$ can be arranged. It also generalises this problem, so all the possible hollow square formations can be obtained!

Adithya from Hymers College in the UK and Emer, Emily, Kayaan, Kanusha and Shyam from Nower Hill High School in the UK continued to use Charlie's method to find hollow squares using $960$ soldiers. Adithya said:
Using $x$ and $y$ as integer values of the hollow square lengths, wherein $x>y$, $x^2-y^2=960$. When factorised this gives $(x+y)(x-y)=960$.

As a result, this means that $x+y$ is equal to a certain factor of $960$ and $x-y$ is the corresponding factor of $960$ (e.g. if $x+y=48$ then $x-y$ must equal $20$ to satisfy the equation).

The factor pairs of $960$ are as follows: $1$ and $960,$ $2$ and $480,$ $3$ and $320,$ $4$ and $240,$ $5$ and $192,$ $6$ and $160,$ $8$ and $120,$ $10$ and $96,$ $12$ and $80,$ $15$ and $64,$ $16$ and $60,$ $20$ and $48,$ $24$ and $40,$ $30$ and $32.$ This means that there are $14$ factor pairs of $960$ without reversing the order of the numbers in the factor pairs.

Emer noticed that the midpoint of the factor pair - so the midpont of $x+y$ and $x-y$ - is $x$, ie the side length of the larger square, so
The pair $5, 192$ did not work because the midpoint was not an integer, so this factor pair can not be turned into a hollow square. So I looked at the factor pairs of $960$ again and eliminated any factor pairs that would not create a midpoint that is an integer (so any where one number was even and one was odd).

This is Emily's method for finding hollow squares for differently sized battalions:
1) Find all the factor pairs
2) Get rid of any where the pair is an odd and an even number
3) For each remaining factor pair, firstly find the difference between the two numbers
4) Next, divide this answer by 2 - the answer is the $y$ value of the equation $x^2-y^2=\text{total number of soldiers}$
5) Subtract the $y$ value from the larger factor to get the $x$ value

In order to find the number of possibilities you simply count the number of remaining factor pairs after step 2.

Shyam pointed out that 
All batallions consisting of a prime number, or odd number or a number from which you can factorise a single 2 only cannot be written or constructed as a symmetrical hollow square. 

Agathiyan explained how to use Alison's method to make hollow squares out of battalions of $n$ soldiers, where $n$ is a multiple of $4$:
Since we need 4 rectangles take $n$ soldiers and split into to four, then using the four groups, form them into as many differently sized rectangles as possible, but not squares (because if it was a square, then the shape wouldn’t form a hollow square, but just a square, as four squares would form that shape) and all groups should be in the same shaped rectangle. Then arranging them all in the same way Alison did, it should be that there will be every single possible combination for a symmetrical hollow square.

Shyam and Agathiyan both used Charlie's method to find out more about hollow squares that are not necessarily symmetrical. Shyam said:
Integers with only one 2 able to be factored out of it is not possible to make any hollow square because: when the number is written as $(x+y)(x-y)$, the one 2 must either be a factor of $(x+y)$ or of $(x-y)$, so only one of them is even.
But this does not work as any 2 pairs of numbers when added and subtracted from each other have to create either 2 odd numbers or 2 even numbers, meaning the given circumstance is impossible.

However, every other number that can't make a symmetrical hollow square (all odd numbers) can make a non-symmetrical square as: $(x+y)(x-y)=x^2-y^2$ and even for primes, you can make $x-y=1$, so $x+y=the \text{ }prime$, so $x$ will be $\frac{prime}{2}+0.5$ and $y$ will be $\frac{prime}2-0.5$. However when $x-y=1$, it will only be a right angle (L shape), not a proper hollow square as for it to be a proper hollow square $x-y\ge2$, $1$ for each border so no primes can make a symmetrical hollow square. Meanwhile other odd numbers can work if $x-y$ is one of their factors and $x+y$ is the other factor in the factor pair.

Agathiyan considered moving the smaller square to different positions inside the larger square, since this is possible when the squares do not have to be symmetrical. This is Agathian's work, where $a$ represents the side length of the larger square and $b$ represents the side length of the smaller square.
Letting $a-b=f_1$ and $a+b=f_2$, $$f_2-f_1=2b\\
I knew that there must be at least one soldier on each of the square's sides, thus the width of the square in which the inner square can move into is:
$a-2$ (As there needs to be one soldier at each edge, thus the width is reduced by $2$)
And since both the range and the inner square are both squares, then the range in which the square can move laterally squared is equal to the range the square can move in 2 dimensions since area of a square is equal to its length squared. So to find the range the square can travel laterally, I tried a few widths and derived the following equation for the range of lateral travel:
$w-b+1=r$, where $w$ is the 'width' the square can occupy, as defined above, $b$ is still the side length of the smaller square, and $r$ is the range of lateral travel, or number of possible positions when moving horizontally.
Therefore the total 2 dimensional area the inner square can be placed is:
Now that I had finally found the number of possible combinations relative to the square sizes, I formed an equation. $f_{x_1},f_{x_2}$ are pairs of factors with even difference of a number and $n$ is the number of pairs of factors with even difference the number has. Since for each pair of factors with an even difference [there are $f_1-1)^2$ possible positions for the 'hole'] then the number of possible arrangements any number has is: $$(f_{1_1}-1)^2+(f_{2_1}-1)^2+...+(f_{n_1}-1)^2$$