UPI Study › Courses › Discrete Mathematics › Free lessons › Lesson 3.6 Free with a free account
Sum of Arithmetic Series
Discrete Mathematics · Chapter 3: Sequences and SeriesSection 3.6 · lesson 22 of 879 min · free with a free account
Free preview
Create a free account to keep watching
It takes a minute and costs nothing. Your free account unlocks all of Chapter 1 and 3 more lessons of Discrete Mathematics.
Lesson complete
Earn the 4 college credits for Discrete Mathematics
Enrolling adds a quiz after each lesson, the graded work and the official transcript. Recommended for credit by NCCRS.
Next lesson: Sum of Geometric Series →← Sigma Notation and SeriesNext lesson: Sum of Geometric Series →
In this lesson
A whole sum collapsed into one closed-form expression.
- Define an arithmetic series
- Derive its sum by writing it forwards and backwards
- Apply both forms of the sum formula
- Compare the closed form with repeated addition
Transcript
Everything said in the video, section by section (1,315 words). Read along, or search it.
Sequences and Series
Sum of Arithmetic Series
Section three point five introduced sigma notation as a compact name for a sum. This section goes one step further, for an especially common kind of sum. When the terms form an arithmetic sequence, the whole sum collapses into a single closed-form expression. No loop, and no term-by-term addition. We'll derive it by writing the sum forwards and backwards, apply both forms of the formula, and compare it with repeated addition.
The Opening Problem
A Fiber Rollout's Grand Total
A regional internet provider is planning a multi-year fiber rollout. Crews activate more new connections each month than the month before, as trained crews are added and earlier street work matures. It's a steady, fixed increase, month over month. Sales forecasting doesn't want the month-by-month figures. It wants the grand total across the whole rollout, recomputed instantly every time a planning assumption changes. Re-adding dozens of numbers by hand, every time an assumption shifts, is exactly the kind of repeated, mechanical work discrete mathematics is good at eliminating.
Definition 3.6.1
Arithmetic Series
Recall that an arithmetic sequence has a fixed common difference d between consecutive terms. The i-th term is a one plus i minus one times d. Adding the terms of a finite arithmetic sequence produces its arithmetic series. S sub n is the sum of its n terms, a one through a n. In the notation of the previous section, it's the n-th, and final, partial sum. Adding the terms one at a time always works. But it costs n minus one additions, however the terms are structured. Because each term is just a one plus a fixed multiple of d, that structure makes a dramatic shortcut possible.
A Well-Known Story
1 + 2 + ... + 100
A well-known story in mathematical folklore, whose accuracy is disputed, holds that a young Carl Friedrich Gauss, was asked to add the whole numbers from one to one hundred. He produced the answer almost immediately. Instead of adding in order, he paired the first number with the last, the second with the second-to-last, and so on. One plus one hundred, two plus ninety-nine, three plus ninety-eight. Every one of the fifty pairs sums to one hundred one. Fifty pairs of one hundred one is five thousand fifty, with no adding in sequence.
Step 1
Write the Sum Forwards and Backwards
Here's the general argument, for any arithmetic series of n terms. Write the sum forwards, a one plus a two, up to a n. Since order doesn't matter in addition, write the same total backwards, a n plus a n minus one, down to a one. Now add the two expressions term by term. First with first, second with second, and so on. Two S sub n becomes a sum of exactly n bracketed pairs. The k-th pair is a sub k plus a sub n plus one minus k.
Step 2
Every Pair Sums to the Same Value
Now prove that every pair sums to the same value. Using the formula for a term, a sub k is a one plus k minus one times d. And a sub n plus one minus k is a one plus n minus k times d. Add them. Combining like terms, the k and minus k cancel, leaving two a one plus n minus one times d. And that's a one, plus a one plus n minus one times d. Which is a one plus a n. The crucial point is that the index k canceled out entirely. The value a one plus a n doesn't depend on which pair is examined. So every one of the n pairs sums to exactly that.
Theorem 3.6.1
The Sum of an Arithmetic Series
So two S sub n is n pairs, each equal to a one plus a n. Divide both sides by two. The theorem. For an arithmetic series of n terms, S sub n equals n over two, times a one plus a n. Substituting a n equals a one plus n minus one times d gives the equivalent form, n over two, times two a one plus n minus one times d. Both forms compute the sum with a fixed number of operations, however large n is. As a check, Gauss's problem has a one equal to one, a n equal to one hundred, and n equal to one hundred. That gives fifty times one hundred one, which is five thousand fifty.
Figure 3.6.1
Pairing From the Outside In
This figure shows an eight-term arithmetic series, starting at two, with common difference three. The terms are two, five, eight, eleven, fourteen, seventeen, twenty, and twenty-three. Pair them from the outside in. Two with twenty-three, five with twenty, eight with seventeen, eleven with fourteen. Every pair sums to twenty-five, which is the first term plus the last. That's exactly the fact proved algebraically, here for one specific sequence.
Worked Example 3.6.1
The Rollout Total
Back to the fiber rollout. Suppose month one activates sixty connections, and the monthly figure grows by twenty-five each month, for twelve months. First find the last term. a twelve is sixty plus eleven times twenty-five, which is three hundred thirty-five connections in month twelve. Then apply the theorem. S twelve is twelve over two, times sixty plus three hundred thirty-five. That's six times three hundred ninety-five, or two thousand three hundred seventy connections over the year. And when an assumption changes, the total is recomputed in a handful of operations.
Worked Example 3.6.2
Insertion Sort's Worst Case
Here's an example from algorithm analysis. In the worst case, insertion sort compares the i-th element against up to i of the elements already sorted. For an array of seven elements, the six passes compare one, two, three, four, five, and six times. That's an arithmetic series with first term one, difference one, and six terms. So the total is six over two, times one plus six, which is twenty-one comparisons. For an array of any size n, the passes contribute one through n minus one comparisons. By the theorem, that's n minus one, times n, over two. That quadratic expression is exactly why insertion sort's worst-case running time grows like n squared. An arithmetic series sits right inside a running-time analysis.
Table 3.6.1
3 Equivalent Approaches
This table compares three equivalent approaches. When the first and last terms are both known, use n over two times the first term plus the last. It takes a fixed number of operations. When only the first term and the common difference are known, use n over two, times two a one plus n minus one d. It substitutes for the last term directly. And adding term by term takes work that grows with n. It's useful for spot-checking a closed-form result, or when n is small.
Closed Form vs Repeated Addition
From a Loop to 3 Operations
Section three point five computed a running total with an accumulator, one addition per term. That cost grows with n. The theorem replaces the loop with one multiplication, one addition, and one division, however large n is. This code computes the same series both ways. The loop adds each term and steps it forward by d. The formula computes the last term, then applies the theorem. With first term five, difference three, and one thousand terms, the last term is three thousand two. So the sum is five hundred times three thousand seven, which is one million five hundred three thousand five hundred. Three operations, and the same answer the thousand-step loop produces.
Takeaways
Pair, Cancel, Collapse
To summarize. Every finite arithmetic series has a closed-form sum, n over two times the first term plus the last. It follows from writing the series forwards and backwards and adding. Every matched pair equals the same constant, the first term plus the last. The equivalent form, in terms of a one and d, is useful when the last term hasn't been computed yet. The argument works identically for even and odd n. And replacing a loop with the formula, turns work that grows with n into a fixed number of operations. Here's something to think about. Pair a five-term series literally, a one with a five, and a two with a four. What happens to the middle term, a three? Work through that case by hand. And explain why the forwards-plus-backwards version never has to answer that question at all.
About Discrete Mathematics at UPI Study
Discrete Mathematics (Math 230) is a self-paced online course of 87 video lessons in 13 chapters, from logic and proof to counting, probability, graph theory and trees. It carries a NCCRS credit recommendation for 4 semester credits.
Every lesson transcript is free on pages like this one, and the videos are free with a free UPI Study account. Enrolling adds a practice quiz after each lesson, the graded work and final exam that earn the credit, lifetime access, and an official transcript on completion. UPI Study has helped over 130,000 students with college credits. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.
Enroll now → Course details Download the syllabus Every course with PRO →
Why take it here
Why students take Discrete Mathematics with UPI Study
Where the credit goes
Universities that work with NCCRS
Discrete Mathematics carries a NCCRS credit recommendation. These universities work with NCCRS; some are UPI Study's signed partners. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.
Thomas Edison State UniversitySigned partner
University of the PeopleSigned partner
Charter Oak State CollegeSigned partner
Strayer UniversitySigned partner
Columbia Southern UniversitySigned partner
Indiana TechSigned partner
Penn StateWorks with NCCRS
Southern New Hampshire UniversityWorks with NCCRS
SUNYWorks with NCCRS
+many more cooperating universitiesFind my college →Find my college → Not listed? Ask Athena in the corner of this page, or book a 15-minute call.
FAQ
Questions students ask us
About Sum of Arithmetic Series
What is an arithmetic series, and how is it different from an arithmetic sequence?
How do you derive the sum formula for an arithmetic series by writing it forwards and backwards?
Which form of the arithmetic series formula should I use, and how do I apply it?
Why use the closed-form formula instead of just adding the terms one by one?
About the Discrete Mathematics course
How many college credits is Discrete Mathematics?
How much does Discrete Mathematics cost and what is included?
Which universities accept UPI Study credits?
How long does Discrete Mathematics take?
How are the exams done?
How do my credits reach my college?
Ready for the full course? Earn 4 credits in Discrete Mathematics.
87 video lessons, a quiz after each one, and the graded work that earns the credit. Recommended for credit by NCCRS.
4 credits · NCCRSEnroll →