Math for Data Science

Last modified: 2026-09-28 23:45:45 (PDT)

Welcome

Math is not just a way of calculating numerical answers; it is a way of thinking, using clear definitions for concepts and rigorous logic to organize our thoughts and back up our assertions.

Cheng (2025)

These notes collect the mathematics that data science courses assume: mathematical notation, algebra (including exponentials and logarithms), univariate calculus, linear algebra, vector calculus, and proof writing. Some key results are listed here, organized by topic:

  • Notation: common symbols, natural numbers, the percent sign, proof symbols, and indicator functions
  • Sets and Functions: sets, subsets and supersets, the empty set, unions, intersections, and set differences, countable sets, functions with their domains, codomains, and images, and the extended non-negative real numbers
  • Algebra: equalities and inequalities, infimum and supremum, sums, products, quotients, exponentials and logarithms
  • Measures: \(\sigma\)-algebras, pairwise disjoint sets, finite and countable additivity, measures, and the counting measure
  • Calculus: derivative rules, antiderivatives, regularity conditions, the Fundamental Theorem of Calculus, and double integrals
  • Linear Algebra: vectors, matrices and their operations, special matrices, quadratic forms, eigendecompositions, definite matrices, determinants, and the design matrix
  • Vector Calculus: derivatives with respect to vectors and matrices, quadratic forms, and the vector chain rule
  • Proof Writing: showing and annotating every step of a derivation

Using these notes in another site

Course sites include these notes as a git submodule named mds at the site’s root, and include fragments with paths that start with mds/, for example {{< include mds/_notation.qmd >}}. This site includes its own fragments the same way, through a mds symlink that points at the repository root.

Each page is a thin wrapper around one or more fragments:

Page Fragment(s) to include
Notation mds/_notation.qmd
Sets and Functions mds/_sets-functions.qmd
Algebra mds/_algebra.qmd
Measures mds/_measures.qmd
Calculus mds/_calc-derivatives.qmd, mds/_calc-integrals.qmd, and the double-integral subfiles mds/_subfiles/_*fubini*.qmd
Linear Algebra mds/_subfiles/_sec_linear_algebra.qmd
Vector Calculus mds/_subfiles/_sec_vector_calc.qmd
Proof Writing mds/_proof-writing.qmd

_notation.qmd, _sets-functions.qmd, _algebra.qmd, and _measures.qmd include latex-macros/macros.qmd themselves; a host page that includes any of the other fragments must include latex-macros/macros.qmd first, as the pages of this site do.

Quarto resolves @id cross-references only within one rendered page, so a host site that links to a result here uses an explicit link, [text](notation.qmd#id).

References

Cheng, Eugenia. 2025. “Opinion | How Math Turned Me from a D.E.I. Skeptic to a Supporter.” The New York Times. https://www.nytimes.com/2025/09/05/opinion/math-dei.html.