Several years ago, we noted the procedure given by the Tosafos to calculate the triangular numbers. I recently came across an analysis by the non-pareil Rav Eliyahu Kalatzkin of the Tosafos and a cognate source, which concludes with a parenthetical excursus into the case of the square pyramidal numbers. This analysis seemingly has no significance at all for any point of Torah, and R. Kalatzkin apparently engages in it merely for the joy of doing mathematics. See his שו”ת אבן הראשה סוף סימן כ”ד1.
R. Kalatzkin’s concluding line notes that his method can be extended to the calculation of the sum of the first n cubes (the four-dimensional hyperpyramidal numbers), although he leaves this as an exercise for the reader.
The general formula for the sum of the p-th powers of the first n positive integers is known as Faulhaber’s formula, named after the sixteenth / seventeenth century German mathematician Johann Faulhaber.
- I have not reproduced the text here as I usually do, due to the difficulty and tediousness of getting the HTML necessary to represent the mathematical notation, combined with the bidirectionality, correct. Furthermore, reading mathematical equations written (as R. Kalatzkin does) from right to left is an experience everyone should have at least once.