April 20, 2008

I decided I'd share a cute little power-summation formula I came up with.

Sum[k=0, n-1](x^k) = (x^(n)-1)/(x-1)

I came across it by accident. I noticed that the formula works for the x=2 case, and tried it for x=3. However, I excluded the (x-1) term since I hadn't yet discovered it- for x=2, it disappears. (It's just a 1.) So, I took a shot and added the term- and it worked! Magic!

Nothing special, but it's cool the way the terms cancel. (If you write out the sum and multiply by x-1, you can see that all but the first and last terms cancel out.)

No comments: