Skip to main content

M01.3 · Functions and graphs

A free, illustrated module of 4 lessons and one interactive in M01 Math Foundations: A function is a machine; Straight lines: slope and intercept; Parabolas and the quadratic formula; Chaining and undoing: composition and inverse.

M01.3 L0 · Foundation 4 lessons · about 100 min Live · in review

Part of M01 Math Foundations in the Mathematics track.

A function is a machine that turns each allowed input into exactly one output, and its graph is every input drawn beside its output. These four lessons build the machine and its graph, read straight lines and parabolas straight off their formulas (slope and intercept, vertex and zeros, all without calculus), and then chain machines together and run them backwards. Every model in machine learning is such a machine, a neural network is a chain of them, and the loss of the course’s line turns out to be a parabola whose lowest point is the best slope.

What you need first. Numbers, expressions, solving a linear equation and reading notation (M01.1), and the coordinate plane, Pythagoras’ theorem and the distance between two points (M01.2). The code uses Python functions, loops, lists and dictionaries (P01.3, P01.4, P01.6) and imports math and NumPy (P01.5), explaining each line.

Lessons

  1. A function is a machine M01.3.1 25 min

    A function takes each allowed input to exactly one output. Meet the function machine, the notation f(x), domain and range, one function shown in words, as a formula, as a table and as a graph, and the vertical-line test that tells a function from a curve that is not one.

  2. Straight lines: slope and intercept M01.3.2 25 min

    The line y = mx + b: slope as rise over run and why every pair of points on a line gives the same slope, the intercept as the output at x = 0, the line through two given points, and two equations in two unknowns solved by substitution as the point where two lines cross.

  3. Parabolas and the quadratic formula M01.3.3 25 min

    Complete the square to write any quadratic in vertex form and read its lowest or highest point straight off, derive the quadratic formula, count the real zeros from the discriminant, and find the slope with the smallest squared error for the course’s data, all without calculus.

  4. Chaining and undoing: composition and inverse M01.3.4 25 min

    Put two function machines in a row and the output of one becomes the input of the next: composition, where the order matters. Run a machine backwards to undo it: the inverse, which exists only when no two inputs share an output, and whose graph is the mirror image in the line y = x.

The interactive

M01.3-X1 · Function machine. Choose a rule, a line, a parabola or an absolute value, and slide the input: the number drops through the machine and lands on the graph, so the curve builds up point by point. Chain a second machine and swap the order to see that composition depends on order. It lives in A function is a machine.

Back to top