[music] What do I get if I take one cubed plus two cubed plus three cubed plus so on plus K cubed? This is a truly remarkable fact it's called Nicomachus' Theorem, and it says that the sum of the first K perfect cubes is the square of just the sum of the first K whole numbers, and it's literally a remarkable fact that these two things are, are equal, right? I mean, you know, it just doesn't look like this should be true at all, but it is. Now, once you believe something like this you could rewrite this sum of cubes formula in maybe a slightly easier way. Right, once you've got the sum of cubes is the square of just the sum of the first k whole numbers, while we already know a formula for some of the first k whole numbers. It's k times k plus 1 over 2, and I'm just squaring that. So now here is a formula for the sum of the first k perfect cubes. It's k squared times k plus 1 squared over 4. Right? I just took this formula and squared it. Again there's a slick geometric proof of this fact. So let's add 1 cubed plus 2 cubed plus 3 cubed plus 4 cubed pictorially, of course the same arguments going to work in general, if I add up the first k perfect cubes. Alright, well here's 1 cubed. Alright. Here's 2 cubed. It's 8 dots, but I've arranged them in a, in a cube. Here's 3 cubed, all right? It's 3 times 3 times 3, 27 dots, but I've arranged them again in, in a cube shape. And then 4 cubed would be 64 dots, but I haven't drawn all the dots in, right? So I want to count all of these dots, and the trick is to rearrange these dots. So that's how most of these sort of pictorial arguments end up going. So I'm going to rearrange these dots like, like this. So here I've made a square, and here's the 1 cube, I added just, just 1 dot. Here's the 2 cube, but I've rearranged it where 1 of the layers of the 2 by 2 by 2 cube is right here, and I've split the other layer in half. So if I take this vertical 2 by 1 piece and this horizontal 1 by 2 piece, I can rearrange them to make it 2 by 2 square that I stack on top of that one, which then gives me this again. Here's the 3 by 3 by 3 cube, it's 3, 3 by 3 squares. Here's the 4 by 4 by 4 cube. It's 4 squares, but that top square is been cut in half. Right, so this piece here, and this piece here, would combine to give me another 4 by 4 square, which I can stack on top of these three to recover the 4 by 4 by 4 cube. Now I could put five 5 by 5 squares around, and then around that I could put six 6 by 6 squares, but I'd cut one of those squares in half just like this. So the even layers I use square that's been cut in half, and the odd layers, I can just stack them down. The, the point here is that I end up producing a square whose side length is 1 plus 2 plus 3 plus 4. You know, and of course this is being general. Alright, it would be plus k. So this is 1 plus 2 plus 3 plus 4. I've rearranged the sum of cubes into a square, and that side length of that square is the sum of the first k whole numbers. Good news now is that I've got a formula for the sum of the first k whole numbers. It's k times k plus 1 over 2. So the resulting square has side length k times k plus 1 over 2, which then means that if I take the sum of the first K cubes it's that number squared. These kinds of formulas enable us to perform calculations that would be extraordinarily painful without access to these formulas. For instance, what if I wanted to add up the first 100 perfect cubes, right. That's the same thing as computing the sum, n goes from 1 to 100, of n cubed. Now, because I've got a formula for this, because this is, the same as, just the sum of The first hundred whole numbers squared, right? I know how to compute this, right? What's the sum of the first hundred whole numbers, well that's 100 times 101 over 2, and I just have to square that. What's a 100 times 101 over 2? What's the sum of the first hundred numbers? It's 5,050 and I just have to square this. And if I square this I get 2, 5, 5, 0, 2, 5, 0, 0. All right? So I get about 25 million, and this makes possible, you know, this calculation that would have been horrible tedious, right? But because I've got access to this formula, I can perform really amazing numeric feats, right? This would be horrible to calculate, but with this formula, I can just write down the answer. If you like these kinds of formulas, here's a challenge. Here's the challenge. What's the sum of fourth powers. The answer's going to be some polynomial in K, right, but you've gotta figure out which polynomial that is. One trick would be to plug in values. Say K equals one, K equals two, K equals three. And then try to find the polynomial that passes through those points. Now that's your challenge. And there's a long tradition here. Bernoulli for instance computed the sum of the first thousand tenths powers, and he did it 300 years ago. People have been thinking about these kinds of formulas for a really long time.