Including function to calculate the 9 squares

And a test showing that the calculation of the squares are correct