All courses

Advanced · module A3

Advanced Mathematics for AI

By the end: Read and work with the mathematics in machine learning papers

Covers
The linear algebra, calculus, probability, information theory and optimisation used in modern deep learning
Contents
5 chapters, 15 topics
Time
About 4 hours
Level
Advanced
Your progress
0 / 15

This module builds on Mathematics for AI. We suggest looking at it first, but the choice is yours.

Chapter 1 Linear Algebra

  1. 1.1

    Linear Transformations and Rank

    Matrices as transformations, span, basis and rank

    Code: visualise a transformation

    15 minBeing written
  2. 1.2

    Eigenvalues and Eigenvectors

    Definition, computation and meaning

    Code: eigen-decomposition

    Av = λv

    15 min Read
  3. 1.3

    Singular Value Decomposition

    Decomposition and low-rank approximation

    Code: compress an image with SVD

    A = UΣVᵀ

    15 minBeing written

Chapter 2 Calculus

  1. 2.1

    Multivariable Calculus and Gradients

    Partial derivatives and the gradient vector

    Code: numerical gradients

    ∇f = [∂f/∂x₁, …, ∂f/∂xₙ]

    15 min Read
  2. 2.2

    The Chain Rule and Automatic Differentiation

    How backpropagation follows from the chain rule

    Code: a tiny autograd engine

    ∂L/∂x = ∂L/∂y · ∂y/∂x

    20 min Read
  3. 2.3

    Jacobians and Hessians

    Second-order information and curvature

    Code: compute a Hessian

    12 minBeing written

Chapter 3 Probability and Statistics

  1. 3.1

    Probability Distributions

    Bernoulli, binomial, Poisson, normal, multivariate normal and others

    Code: sample and plot distributions

    15 minBeing written
  2. 3.2

    Maximum Likelihood and MAP Estimation

    Where common loss functions come from

    Code: derive and fit a model by MLE

    θ̂ = argmax Σ log p(xᵢ|θ)

    15 min Read
  3. 3.3

    Bayesian Inference

    Priors, posteriors and uncertainty

    Code: Bayesian coin estimation

    12 minBeing written

Chapter 4 Information Theory

  1. 4.1

    Entropy, Cross-Entropy and KL Divergence

    Measuring uncertainty and the difference between distributions

    Code: compute all three

    H(p,q) = −Σ p log q

    15 min Read

Chapter 5 Optimisation

  1. 5.1

    Convex Optimisation

    Convex functions, minima and why convexity helps

    Interactive: convex and non-convex surfaces

    12 minBeing written
  2. 5.2

    Optimisers: SGD, Momentum, RMSProp and Adam

    How modern optimisers adjust each step

    Interactive: race the optimisers

    θ ← θ − η·m̂ / (√v̂ + ε)

    15 minBeing written
  3. 5.3

    Constrained Optimisation

    Lagrange multipliers and duality

    Code: solve a constrained problem

    L = f(x) + λg(x)

    12 minBeing written
  4. 5.4

    Numerical Stability

    Overflow, underflow and stable softmax

    Code: make a function stable

    10 minBeing written
  5. 5.5

    Module Review and Assessment

    Derivations and a scored quiz

    Graded problem set

    20 minBeing written