M01.7 · Sums, products and sequences
M01.7 L0 · Foundation 4 lessons · about 100 min Live · in review
Part of M01 Math Foundations in the Mathematics track.
Machine-learning formulas are full of long lists of numbers that are added or multiplied together, and a training run is itself a list of weights, each made from the one before. These four lessons read such lists as sequences with a rule, write their totals with the sigma sign and read it as a loop, add whole arithmetic and geometric sums in one line (and watch a geometric total level off), and finish with the product sign, empty sums and products, the logarithm that turns a product into a sum, and double sums over a table.
What you need first. Whole-number powers and the order of operations (M01.1), straight lines and functions (M01.3), and exponentials and logarithms (M01.4). Proof by induction (M01.6.4) confirms one formula in the third lesson, and the distance formula (M01.2.3) returns in the second.
Lessons
Sequences: lists with a rule M01.7.1 25 min
A sequence is a list of numbers in order, made by a formula or by a rule that builds each term from the one before. Unroll the two simplest rules, add d and multiply by r, to reach any term in one line, and find a line and an exponential behind them.
Sigma notation M01.7.2 25 min
The capital Greek letter sigma writes a long sum as one symbol, and it reads as a loop: a counter, where it starts and stops, and the term to add. Expand and fold sums, rename the counter, derive three rules, and write the mean, the mean squared error and a distance with it.
Arithmetic and geometric sums M01.7.3 25 min
Add 1 + 2 + … + n by pairing the first term with the last, any arithmetic sum as n times the average of its ends, and a geometric sum by multiplying by the ratio and subtracting. With a ratio between -1 and 1 the total levels off, which is why a discounted reward stays finite.
Products and double sums M01.7.4 25 min
The capital pi multiplies the way the sigma adds, and n factorial is its best-known product. See why a sum of nothing is 0 and a product of nothing is 1, turn a product of probabilities into a sum of logarithms, and add a whole table by rows or by columns.
The interactive
M01.7-X1 · Sum builder. Set the first term, the step or the ratio and the number of terms of an arithmetic or a geometric sequence. Bars show the terms, the running total climbs beside them, and the sigma, the terms written out and the closed formula are shown together; with a ratio between 0 and 1 the total levels off. It lives in Arithmetic and geometric sums.