Hi,

I am trying to work out a formula to tell you how many squares there are no a chessboard. I want to write the formula in a way that you could work it out for any size grid.

The formula for a chessboard is x=8²+7²+6²+5²+4²+3²+2²+1².

Is there a function similar to Factorial but for addition not multiplication? This is so I could express the formula in the format of x=(n²)! (replacing the factorial function for an appropriate one)?

Any help would be greatly appreciated, as I am rusty on my mathematics and I'm trying to help my son with his maths project!

PS: I have managed to write a program to work out the answer in the following, which loops until it has added the square of n until n is equal to 1. However, I don't think the maths teacher would be impressed with this, as I know she doesn't approve of computers doing the work for you!