Sum of n, n², or n³ | Brilliant Math & Science Wiki (2024)

Sign up with Facebook or Sign up manually

Already have an account? Log in here.

Recommended Course

  • Algebra through Puzzles Supercharge your algebraic intuition and problem solving skills!

Wildan Bagus Wicaksono, Patrick Corn, Ameya Salankar, and

  • Christopher Williams
  • Pranshu Gaba
  • Kishlaya Jaiswal
  • Andres Gonzalez
  • Rishik Jain
  • Mahindra Jain
  • Munem Shahriar
  • Jongheun Lee
  • Mohammad Yasser
  • Jimin Khim

contributed

Sum of n, n², or n³ | Brilliant Math & Science Wiki (1)

The series \(\sum\limits_{k=1}^n k^a = 1^a + 2^a + 3^a + \cdots + n^a\) gives the sum of the \(a^\text{th}\) powers of the first \(n\) positive numbers, where \(a\) and \(n\) are positive integers. Each of these series can be calculated through a closed-form formula. The case \(a=1,n=100\) is famously said to have been solved by Gauss as a young schoolboy: given the tedious task of adding the first \(100\) positive integers, Gauss quickly used a formula to calculate the sum of \(5050.\)

The formulas for the first few values of \(a\) are as follows:

\[\begin{align}\sum_{k=1}^n k &= \frac{n(n+1)}2 \\\sum_{k=1}^n k^2 &= \frac{n(n+1)(2n+1)}6 \\\sum_{k=1}^n k^3 &= \frac{n^2(n+1)^2}4.\end{align}\]

Faulhaber's formula, which is derived below, provides a generalized formula to compute these sums for any value of \(a.\)

Manipulations of these sums yield useful results in areas including string theory, quantum mechanics, and complex numbers.

Contents

  • Sum of the First \(n\) Positive Integers
  • Sum of the Squares of the First \(n\) Positive Integers
  • Sum of the Cubes of the First \(n\) Positive Integers
  • Some Examples
  • Generalizations
  • Faulhaber's Formula
  • See Also

Sum of the First \(n\) Positive Integers

Let \(S_n = 1+2+3+4+\cdots +n = \displaystyle \sum_{k=1}^n k.\) The elementary trick for solving this equation (which Gauss is supposed to have used as a child) is a rearrangement of the sum as follows:

Sum of n, n², or n³ | Brilliant Math & Science Wiki (2)

\[\begin{eqnarray}S_n & = & 1 & + & 2 & + & 3 & + \cdots + & n \\S_n & = & n & + & n-1 & + & n-2 & + \cdots + & 1 .\\\end{eqnarray}\]

Grouping and adding the above two sums gives

\[\begin{eqnarray}2S_n & = & (1+n)+(2+n-1)+(3+n-2) + \cdots + (n+1) \\ & = & \underbrace{(n+1)+(n+1)+(n+1)+\cdots+(n+1)}_{n\ \text{times}} \\& = & n(n+1).\end{eqnarray}\]

Therefore,

\[S_n = \dfrac{n(n+1)}{2}.\]

Find the sum of the first \(100\) positive integers.

Plugging \(n=100\) in our equation,

\[1+2+3+4+\dots + 100 = \frac{100(101)}{2} = \frac{10100}{2},\]

which implies our final answer is 5050. \( _\square \)

Show that the sum of the first \(n\) positive odd integers is \(n^2.\)

There are several ways to solve this problem. One way is to view the sum as the sum of the first \(2n\) integers minus the sum of the first \(n\) even integers. The sum of the first \(n\) even integers is \(2\) times the sum of the first \(n\) integers, so putting this all together gives

\[\frac{2n(2n+1)}2 - 2\left( \frac{n(n+1)}2 \right) = n(2n+1)-n(n+1) = n^2.\]

Even more succinctly, the sum can be written as

\[\sum_{k=1}^n (2k-1) = 2\sum_{k=1}^n k - \sum_{k=1}^n 1 = 2\frac{n(n+1)}2 - n = n^2.\ _\square\]

In a similar vein to the previous exercise, here is another way of deriving the formula for the sum of the first \(n\) positive integers. Start with the binomial expansion of \((k-1)^2:\)

\[(k-1)^2 = k^2 - 2k + 1.\]

Rearrange the terms as below:

\[k^2-(k-1)^2 = 2k-1.\]

Now sum both sides:

\[\sum_{k=1}^n \big(k^2-(k-1)^2\big) = 2 \sum_{k=1}^n k - \sum_{k=1}^n 1.\]

The left sum telescopes: it equals \(n^2.\) The right side equals \(2S_n - n,\) which gives \(2S_n - n = n^2,\) so \(S_n = \frac{n(n+1)}2.\)

This technique generalizes to a computation of any particular power sum one might wish to compute.

Sum of the Squares of the First \(n\) Positive Integers

Continuing the idea from the previous section, start with the binomial expansion of \((k-1)^3:\)

\[(k-1)^3 = k^3 - 3k^2 + 3k - 1.\]

Rearrange the terms:

\[k^3-(k-1)^3=3k^2-3k+1.\]

As before, summing the left side from \(k=1\) to \(n\) yields \(n^3.\) This gives

\[\begin{align}n^3 &= 3 \left( \sum_{k=1}^n k^2 \right) - 3 \sum_{k=1}^n k + \sum_{k=1}^n 1 \\n^3 &= 3 \left( \sum_{k=1}^n k^2 \right) - 3 \frac{n(n+1)}2 + n \\3 \left( \sum_{k=1}^n k^2 \right) &= n^3 + 3 \frac{n(n+1)}2 - n \\\Rightarrow \sum_{k=1}^n k^2 &= \frac13 n^3 + \frac12 n^2 + \frac16 n \\&= \frac{n(n+1)(2n+1)}6.\end{align}\]

Find the sum of the squares of the first \(100\) positive integers.

Plugging in \(n=100,\)

\[1^2+2^2+3^2+4^2+\dots + 100^2 = \frac{100(101)(201)}{6} = \frac{2030100}{6} = 338350.\ _\square\]

Sum of the Cubes of the First \(n\) Positive Integers

Again, start with the binomial expansion of \((k-1)^4\) and rearrange the terms:

\[k^4-(k-1)^4=4k^3-6k^2+4k-1.\]

Sum from \(1\) to \(n\) to get

\[n^4 = 4 s_{3,n} - 6 s_{2,n} + 4 s_{1,n} - n.\]

Here \(s_{a,n}\) is the sum of the first \(n\) \(a^\text{th}\) powers. So

\[\begin{align}4s_{3,n} &= n^4 + 6 \frac{n(n+1)(2n+1)}6 - 4 \frac{n(n+1)}2 + n \\\\s_{3,n} &= \frac14 n^4 + \frac12 n^3 + \frac34 n^2 + \frac14 n - \frac12 n^2 - \frac12 n + \frac14 n \\\\s_{3,n} &= \frac14 n^4 + \frac12 n^3 + \frac14 n^2 \\\\&= \frac{n^2(n+1)^2}4.\end{align}\]

Find the sum of the cubes of the first \(200\) positive integers.

Plugging \(n=200\) in our equation,\[1^3+2^3+3^3+4^3+ 5^3 + 6^3 + 7^3 +8^3 \dots + 200^3 = \frac{200^2\big(201^2\big)}{4} = \frac{1616040000}{4} = 404010000.\ _\square\]

\[\large \displaystyle\sum_{n=1}^{10}n\big(1+n+n^2\big)= \, ? \]

Some Examples

Simplify

\[2 + 4 + 6 + \cdots + 2n.\]

We have

\[\begin{align}2+4+6+\cdots+2n&=\sum _{ i=1 }^{ n }{ 2i } \\ &=2(1+2+3+\cdots+n)\\ &=2\times \frac { n(n+1) }{ 2 } \\&=n(n+1).\ _\square\end{align}\]

Simplify

\[1+3+5+\cdots+(2n-1).\]

We have

\[\begin{align}1+3+5+\cdots+(2n-1)&=\sum _{ i=1 }^{ n }{ (2i-1) } \\&=\sum _{ i=1 }^{ n }{ 2i } -\sum _{ i=1 }^{ n }{ 1 } \\ &=2\sum _{ i=1 }^{ n }{ i } -n\\ &=2\times \frac { n(n+1) }{ 2 } -n\\ &=n(n+1)-n\\ &=n(n+1-1)\\ &={ n }^{ 2 }.\ _\square\end{align}\]

Simplify

\[2^2+4^2+6^2+\cdots+(2n)^2.\]

We have

\[\begin{align}2^2+4^2+6^2+\cdots+(2n)^2&=\sum_{i=1}^{n}(2i)^2\\&=\sum_{i=1}^{n}\big(2^2 i^2\big)\\ &=4\sum _{ i=1 }^{ n }{ { i }^{ 2 } } \\ &=4\cdot \frac { n(n+1)(2n+1) }{ 6 } \\ &=\frac { 2n(n+1)(2n+1) }{ 3 }.\ _\square\end{align} \]

Simplify

\[1^2+3^2+5^2+\cdots+(2n-1)^2.\]

We have

\[\begin{align}1^2+3^2+5^2+\cdots+(2n-1)^2&=\left(1^2+2^2+3^2+4^2+\cdots+(2n-1)^2+(2n)^2\right)-\left(2^2+4^2+6^2+\cdots+(2n)^2\right)\\&=\sum_{i=1}^{2n} i^2-\sum_{i=1}^{n}(2i)^2\\&=\frac{2n(2n+1)(4n+1)}{6}-\frac{2n(n+1)(2n+1)}{3}\\&=\frac{n(2n+1)\big((4n+1)-2(n+1)\big)}{3}\\&=\frac{n(2n-1)(2n+1)}{3}.\ _\square\end{align}\]

Generalizations

As in the previous section, let \(s_{a,n} = \sum\limits_{k=1}^n k^a.\) Then the relevant identity, derived in the same way from the binomial expansion, is

\[n^{a+1} = \binom{a+1}1 s_{a,n} - \binom{a+1}2 s_{a-1,n} + \binom{a+1}3 s_{a-2,n} - \cdots + (-1)^{a-1} \binom{a+1}{a} s_{1,n} + (-1)^a n.\]

This recursive identity gives a formula for \(s_{a,n}\) in terms of \(s_{b,n}\) for \(b < a.\) It is the basis of many inductive arguments. In particular, the first pattern that one notices after deriving \(s_{a,n}\) for \(a=1,2,3\) is the leading terms \(\frac12 n^2, \frac13 n^3, \frac14 n^4.\) Here is an easy argument that the pattern continues:

For a positive integer \(a,\) \(s_{a,n}\) is a polynomial of degree \(a+1\) in \(n.\) Its leading term is \(\frac1{a+1} n^{a+1}.\)

Induction. The statement is true for \(a=1,\) and now suppose it is true for all positive integers less than \(a.\) Then solve the above recurrence for \(s_{a,n}\) to get

\[s_{a,n} = \frac1{a+1} n^{a+1} + c_{a-1} s_{a-1,n} + c_{a-2} s_{a-2,n} + \cdots + c_1 s_{1,n} + c_0 n,\]

where the \(c_i\) are some rational numbers.

Now by the inductive hypothesis, all of the terms except for the first term are polynomials of degree \(\le a\) in \(n,\) so the statement follows. \(_\square\)

Note the analogy to the continuous version of the sum: the integral \(\int_0^n x^a \, dx = \frac1{a+1}n^{a+1}.\) The lower-degree terms can be viewed as error terms in the approximation of the area under the curve \(y=x^a\) by the rectangles of width \(1\) and height \(k^a.\)

Faulhaber's Formula

Having established that \(s_{a,n} = \frac1{a+1} n^{a+1} +\text{(lower terms)},\) the obvious question is whether there is an explicit expression for the lower terms. It turns out that the terms can be expressed quite concisely in terms of the Bernoulli numbers, as follows:

Faulhaber's Formula:

\[\sum_{k=1}^n k^a = \frac1{a+1} \sum_{j=0}^{a} (-1)^j \binom{a+1}{j} B_j n^{a+1-j}.\]

That is, if \(i=a+1-j\) is a positive integer, the coefficient of \(n^i\) in the polynomial expression for the sum is \(\dfrac{(-1)^{a+1-i}}{a+1} \binom{a+1}{i} B_{a+1-i}.\)

Show that \(\sum\limits_{k=1}^n k^a = \frac1{a+1} n^{a+1} + \frac12 n^a + (\text{lower terms}).\)

This can be read off directly from Faulhaber's formula: the \(j=0\) term is \(\frac1{a+1}n^{a+1},\) and the \(j=1\) term is

\[\frac1{a+1} (-1)^1 \binom{a+1}1 B_1 n^a,\]

and since \(B_1 = -\frac12,\) this simplifies to \(\frac12 n^a.\) \(_\square\)

To compute \(\sum\limits_{k=1}^n k^4\) using Faulhaber's formula, write

\[\sum_{k=1}^n k^4 = \frac15 \sum_{j=0}^4 (-1)^j \binom{5}{j} B_j n^{5-j}\]

and use \(B_0 = 1, B_1 = -\frac12, B_2 = \frac16, B_3 = 0, B_4 = -\frac1{30}\) to get

\[\sum_{k=1}^n k^4 = \frac15 \left( n^5 + \frac52 n^4 + \frac{10}6 n^3 + 0 n^2 - \frac16 n\right) = \frac15 n^5 + \frac12 n^4 + \frac13 n^3 - \frac16 n.\]

This happens to factor as

\[\sum_{k=1}^n k^4 = \frac{n(n+1)(2n+1)(3n^2+3n-1)}{30}.\]

Note that the \((-1)^j\) sign only affects the term when \(j=1,\) because the odd Bernoulli numbers are zero except for \(B_1 = -\frac12.\)

The proof of the theorem is straightforward (and is omitted here); it can be done inductively via standard recurrences involving the Bernoulli numbers, or more elegantly via the generating function for the Bernoulli numbers.

See Also

  • Bernoulli Numbers

Cite as: Sum of n, n², or n³. Brilliant.org. Retrieved from https://brilliant.org/wiki/sum-of-n-n2-or-n3/

Sum of n, n², or n³ | Brilliant Math & Science Wiki (2024)

FAQs

What is the sum of n square? ›

The sum of the first n squares, 1 + 4 + 9 + 16 + ... + n², is given by the formula ⅙n(n+1)(2n+1).

What is the rule of sum in math? ›

The rule of sum is a basic counting approach in combinatorics. A basic statement of the rule is that if there are n choices for one action and m choices for another action, and the two actions cannot be done at the same time, then there are n + m n+m n+m ways to choose one of these actions.

What is the formula for summation of N? ›

Sn = n(n+1)/2

Hence, this is the formula to calculate sum of 'n' natural numbers.

What is the sum of the n cube terms? ›

FAQs on Sum of Cubes of n Natural Numbers

It can be obtained by using a simple formula S = [n2 (n + 1)2]/4, where S is the sum and n is the number of natural numbers taken.

What is the rule for the sum of squares? ›

To calculate the sum of squares, subtract the mean from the data points, square the differences, and add them together. There are three types of sum of squares: total, residual, and regression.

Is there a special formula for the sum of squares? ›

To calculate the sum of two or more squares in an expression, the sum of squares formula is used. Thus, a few sums of squares formulas are, In statistics : Sum of squares of n data points = ∑ni=0 (xi - x̄) In algebra : Sum of squares = a2 + b2 = (a + b)2 - 2ab.

What is the sum theory in math? ›

The sum of the interior angles in a triangle is supplementary. In other words, the sum of the measure of the interior angles of a triangle equals 180°. So, the formula of the triangle sum theorem can be written as, for a triangle ABC, we have ∠A + ∠B + ∠C = 180°.

What does ∑ mean in math? ›

The symbol ∑ indicates summation and is used as a shorthand notation for the sum of terms that follow a pattern.

What is the basic rule of sum? ›

The summations rules are nothing but the usual rules of arithmetic rewritten in the Σ notation. 2S (n + 1) + (n + 1) + + (n + 1) = n(n + 1). n times This gives our desired formula, once we divide both sides of the above equality by 2. n(n + 1) 3S+3 +n=n³ + 3n² + 3n.

What is summation n 3? ›

The formula to find the sum of cubes of natural numbers is =(n(n+1)2)2. But sum of first n natural numbers is∑n=n(n+1)2. So, ∑n3=(∑n)2.

What is n squared? ›

The usual notation for the square of a number n is not the product n × n, but the equivalent exponentiation n2, usually pronounced as "n squared". The name square number comes from the name of the shape. The unit of area is defined as the area of a unit square (1 × 1). Hence, a square with side length n has area n2.

What does n mean in math? ›

Natural Numbers, Counting Numbers. The letter (N) is the symbol used to represent natural numbers. Natural numbers are also known as counting numbers, and they begin with the number 1 and continue to infinity (never ending), which is represented by three dots (...).

What is the cube sum problem? ›

The equation x3+y3+z3=k is known as the sum of cubes problem. While seemingly straightforward, the equation becomes exponentially difficult to solve when framed as a “Diophantine equation” — a problem that stipulates that, for any value of k, the values for x, y, and z must each be whole numbers.

What is the cube of n in math? ›

In arithmetic and algebra, the cube of a number n is its third power, that is, the result of multiplying three instances of n together. The cube of a number or any other mathematical expression is denoted by a superscript 3, for example 23 = 8 or (x + 1)3.

What is the formula for N square? ›

Formulas for Sum of Squares
Sum of Squares Formulas
In StatisticsSum of Squares: = Σ(xi + x̄)2
For “n” TermsSum of Squares Formula for “n” numbers = 12 + 22 + 32 ……. n2 = [n(n + 1)(2n + 1)] / 6
1 more row

What is the formula for n2? ›

Nitrogen gas has the chemical formula N2 which can be denoted by N≡N. It is categorized as one of the diatomic elements which are made up of two atoms of the same element joined by one or more covalent bonds because in the case of N2 also a triple covalent link connects the two nitrogen atoms.

What is the square sum of a sum? ›

The square of a sum is equal to the sum of the squares of all the summands plus the sum of all the double products of the summands in twos: ( ∑ i a i ) 2 = ∑ i a i 2 + 2 ⁢ ∑ i < j a i ⁢ a j . ( a + b + c + … ) 2 = ( a ) ⁢ a + ( 2 ⁢ a + b ) ⁢ b + ( 2 ⁢ a + 2 ⁢ b + c ) ⁢ c + …

What is the formula for SN in math? ›

Sum to n Terms of Arithmetic Progression Formula: Summing the first 'n' terms in an Arithmetic Progression (AP) is done with the formula: Sn = n/2 [2a + (n-1)d], where 'a' represents the initial term, 'd' is the consistent difference, and 'n' stands for the quantity of terms.

References

Top Articles
Latest Posts
Article information

Author: Tish Haag

Last Updated:

Views: 6574

Rating: 4.7 / 5 (47 voted)

Reviews: 86% of readers found this page helpful

Author information

Name: Tish Haag

Birthday: 1999-11-18

Address: 30256 Tara Expressway, Kutchburgh, VT 92892-0078

Phone: +4215847628708

Job: Internal Consulting Engineer

Hobby: Roller skating, Roller skating, Kayaking, Flying, Graffiti, Ghost hunting, scrapbook

Introduction: My name is Tish Haag, I am a excited, delightful, curious, beautiful, agreeable, enchanting, fancy person who loves writing and wants to share my knowledge and understanding with you.