Skip to content
coden

How to read mathematical notation: symbols, indices, sums and quantifiers

A glossary of about forty symbols that lets you read every definition in the AI basics series — from indices and Greek letters through ∑ and argmin to ∀ and ∃. With a cheat sheet at the end.

12 minutes Matěj Žalmánek 2026-10-15

Series AI basics Part 4 of 52
  1. Map of artificial intelligence: what is what and how it all fits together
  2. A brief history of artificial intelligence: from Turing to language models
  3. Data, model, training, inference: the basic terms on a single example
  4. How to read mathematical notation: symbols, indices, sums and quantifiers
  5. Sets and relations: the building blocks of definitions in AI
  6. Functions and mappings: why every AI model is a function
  7. Logic and proofs: the rules AI reasons by
  8. Graphs and trees: the structure that both search and neural networks stand on
  9. Linear algebra for machine learning: vectors, matrices and why AI mostly multiplies
  10. Derivatives, the gradient and the chain rule: how a model finds out which way to learn
  11. Gradient descent: how a model learns
  12. What probability is: from rolling dice to the Kolmogorov axioms
  13. Conditional probability and Bayes’ theorem: how to update your estimate when you learn something new
  14. Random variables and the cumulative distribution function: one function that tells you everything about a distribution
  15. Probability density and probability mass functions: why a continuous variable has zero probability at a point
  16. Expected value, variance and covariance: where a distribution lies, how wide it is and what goes with what
  17. Overview of probability distributions: Bernoulli, binomial, Poisson, uniform, normal and exponential
  18. Law of large numbers and central limit theorem: why averages behave so predictably
  19. Statistics and parameter estimation: maximum likelihood, MAP and confidence intervals
  20. Information theory: entropy, cross-entropy and KL divergence — where loss functions come from
  21. State-space search: BFS, DFS, UCS and A* with animations
  22. Games and adversaries: minimax, alpha-beta pruning and Monte Carlo tree search
  23. Constraint satisfaction: backtracking, constraint propagation and AC-3 on sudoku and a map of Czech regions
  24. Logic and knowledge systems: forward and backward chaining, resolution and expert systems
  25. Planning: STRIPS, the blocks world, heuristics from relaxation and planning in AI agents
  26. Local search and simulated annealing: a travelling salesman through the Czech regional capitals
  27. Genetic algorithms: population, crossover, mutation and selection on a backpack for a hike
  28. Evolution strategies and genetic programming: from the one-fifth rule to Kepler’s law
  29. Ant colony optimization: how a pheromone trail finds a short path
  30. Particle swarm optimisation: inertia, personal experience and the swarm’s experience
  31. Neuroevolution: evolving the weights and shape of neural networks, and the NEAT algorithm
  32. Fuzzy sets and membership functions: how to write down “somewhat warm”
  33. Fuzzy logic and probability: why “somewhat warm” does not mean “probably warm”
  34. Fuzzy logic: t-norms, implications and IF–THEN rules
  35. Fuzzy control: Mamdani and Sugeno from a fan to a pole on a cart
  36. Fuzzy clustering: the fuzzy c-means algorithm and points between clusters
  37. Neuro-fuzzy systems (ANFIS): fuzzy rules that learn from data
  38. Markov chains: the transition matrix, the stationary distribution and PageRank
  39. Hidden Markov models: the Viterbi algorithm and the dishonest casino
  40. Bayesian networks: why the grass is wet and what it means for the sprinkler
  41. The Kalman filter: how to estimate where a car is and how fast it goes from imprecise measurements
  42. Types of machine learning: supervised, unsupervised, semi-supervised and more
  43. Prompts, context and RAG: how to give a model the right information
  44. Variational autoencoders (VAE): new images from a continuous latent space
  45. Generative adversarial networks (GAN): the forger versus the detective
  46. Diffusion models: how pure noise becomes an image
  47. Markov decision processes: states, actions, rewards and the Bellman equations
  48. Q-learning and DQN: learning the value of actions, from a table to a neural network
  49. Policy gradient and PPO: learning the policy directly
  50. How an AI agent works: a language model in a loop with tools
  51. Programming with AI agents: the task, tests and review
  52. Evaluating and securing AI systems: how to measure and how to keep watch

Full series syllabus 52 of 83 topics published

What you will take away
  • How to read indices, Greek letters, ∑, argmin, ∀ and ∃ — and what they usually mean in AI.
  • A method for breaking any definition into parts and translating it into words.
  • A cheat sheet of all the symbols you will meet in the series.

Mathematical notation looks like a cipher, but it is just shorthand. The sentence “add up the squares of all the numbers in the list” can be written as ∑i xi2 and it means exactly the same thing — it is just shorter and cannot be read two ways.

There are surprisingly few symbols you will meet in articles about artificial intelligence — about forty. Here we go through them in groups, say how each one is read, and at the end we read a few real definitions from other parts of the series. A cheat sheet of all the symbols is in the last section.

1. Why mathematics uses symbols

Natural language is ambiguous. “Every student read some book” can mean that each student read a different book, or that they all read the same one. In notation, ∀s ∃k and ∃k ∀s are two different sentences and nobody mixes them up. Notation is precise, short and international — you read a formula from a Chinese textbook the same way as one from an English one.

In plain words

You don’t take in a formula all at once like a picture; you read it like a sentence — left to right, symbol by symbol. When you hit an unfamiliar symbol, just look it up in the cheat sheet and “translate” it into words. After a few definitions it comes naturally.

2. Variables, indices and Greek letters

A variable is a letter that stands for a number or another object: x, y, n. It is written in italics. When there are several values, we tell them apart with an index (subscript) — a small number or letter at the bottom right:

  • x1, x2, x3 — the first, second, third value (“x one, x two…”),
  • xi — the “i-th” value (“x sub i”), where i can be any number,
  • Ai,j — the entry in row i and column j of a table (matrix),
  • x(i) — the i-th example in the data; the parentheses distinguish the index from the power x2.

A prime or a hat over a letter turns one variable into a relative: s′ (“s prime”) is the next state after s, ŷ (“y hat”) is an estimate of the true value y, and x̄ (“x bar”) is the mean. A star marks the best: θ* (“theta star”) are the optimal parameters, C* the optimal cost.

There are not many Latin letters, so mathematics borrows Greek ones. In AI some of them have an established meaning — when you see them, you usually know what is going on:

SymbolRead asUsually means
αalphalearning rate, step size of an algorithm
βbetaa parameter (for example momentum)
γgammadiscount factor — how much the future matters
δ, Δdeltaa small change, a difference
εepsilona very small positive number; the probability of random exploration
ηetalearning rate in gradient descent
θthetamodel parameters — the “knobs” that are learned
λlambdaregularization strength
μmuexpected value, mean; the centre of a cluster
πpithe agent’s policy (and also the number 3.14…)
σsigmastandard deviation; the sigmoid

3. Sets in notation

A set is a collection of elements; it is written in curly braces: {1, 2, 3} or {↑, →, ↓, ←}. Well-known sets of numbers are written with capital double-struck letters: ℕ natural numbers (1, 2, 3, …), ℤ integers, ℝ real numbers. ℝn is all lists of n real numbers — vectors.

  • x ∈ S — “x is in S”, it is an element of it; x ∉ S — it is not,
  • A ⊆ B — “A is a subset of B”, everything in A is also in B,
  • A ∪ B — union (what is in at least one), A ∩ B — intersection (what is in both),
  • A × B — Cartesian product: all pairs (a, b),
  • ∅ — the empty set, |S| — the number of elements,
  • {x ∈ ℝ : x > 0} — “the set of all real x such that x > 0”; the colon (or a vertical bar) is read “such that”.

Parentheses, on the other hand, mean an ordered group where the order matters: (3, 1) is not the same as (1, 3). That is how pairs, coordinates and n-tuples are written — for example a search problem as the six-tuple (S, s0, A, T, G, c). Sets and relations get a part of the series of their own.

4. Sum and product: ∑ and ∏

Definition — sum and product

Let m, n ∈ ℤ be integers and let ai ∈ ℝ be a real number for every integer i with m ≤ i ≤ n. The sum and the product of the numbers am, …, an are the numbers

∑i=mn ai := am + am+1 + … + an,   ∏i=mn ai := am · am+1 · … · an   for m ≤ n,

∑i=mn ai := 0,   ∏i=mn ai := 1   for m > n (the empty sum and the empty product).

The dots “…” can be replaced by a precise recursive definition: for n ≥ m, ∑i=mn ai = (∑i=mn−1 ai) + an and ∏i=mn ai = (∏i=mn−1 ai) · an.

The variable under the sign (i) is the index of summation; it takes all integer values from the lower limit m to the upper limit n in turn, each exactly once.

In plain words

The capital sigma ∑ is a loop “for i from 1 to n, add”. The capital pi ∏ is the same, only it multiplies. If you program, you know it as for i in range(1, n + 1): total += a[i].

Take the list x = (3, 1, 4, 1, 5), so x1 = 3, x2 = 1 and so on. Then:

∑i=15 xi = 3 + 1 + 4 + 1 + 5 = 14

∑i=13 xi2 = 32 + 12 + 42 = 9 + 1 + 16 = 26

∏i=13 xi = 3 · 1 · 4 = 12

x̄ = 1/5 ∑i=15 xi = 14/5 = 2.8  — the mean (colours as in the formula below)

The last line is the formula you will meet most often: 1/n ∑ is the mean. When a sum has no limits (∑i), it runs over all i that make sense — typically over all the examples in the data.

x̄ = 1/n ∑i=1n xi

x̄
the mean — the bar over the letter says “one typical number computed from the values of x”
1/n
divides the sum by the number of values; without it the “mean” would grow with every added value and two lists of different lengths could not be compared
∑i=1n
goes through all indices from 1 to n — the limits guarantee that no value is missing and none is counted twice
xi
the value being added right now; the index i moves on with every step of the sum
For x = (3, 1, 4, 1, 5): x̄ = 1/5 · (3 + 1 + 4 + 1 + 5) = 1/5 · 14 = 2.8.
Theorem — calculating with sums

Let n ∈ ℕ, c ∈ ℝ and ai, bi ∈ ℝ for i = 1, …, n. Then

∑i=1n (c · ai + bi) = c · ∑i=1n ai + ∑i=1n bi   and   ∑i=1n c = n · c.

Proof. Write the sum out as n terms, regroup them (addition is associative and commutative) and factor c out of each c · ai. A constant added up n times is n · c. ∎

Example. For x = (3, 1, 4, 1, 5): ∑i=15 (2xi + 1) = 2 · 14 + 5 · 1 = 33. Directly: 7 + 3 + 9 + 3 + 11 = 33.

Careful: a power or any other non-linear function cannot be pulled out of a sum like this — ∑ xi2 is not (∑ xi)2. For our five values: 9 + 1 + 16 + 1 + 25 = 52, whereas 142 = 196.

In plain words

If you double everyone’s salary on the list and add one dollar, the total is twice the original plus as many dollars as there are people. Most of the rearranging of formulas in later parts rests on this rule — for example why we can differentiate the mean error term by term.

5. Functions, arrows and argmin

f(x) is read “f of x” — the value of the function f for the input x. The notation f : X → Y (“f from X to Y”) says where the function takes its inputs from and where its outputs belong: f : ℝ2 → {0, 1} takes a pair of numbers and returns 0 or 1 — that is a classifier of points in the plane.

Definition — function and composition of functions

Let X and Y be sets. A function (mapping) f from X to Y, written f : X → Y, is a set of pairs f ⊆ X × Y (a relation, see the part Sets and relations) such that

∀x ∈ X ∃! y ∈ Y : (x, y) ∈ f,

where ∃! is read “there exists exactly one”. This unique element y is denoted f(x). So a function assigns to every element x ∈ X exactly one element f(x) ∈ Y. The set X is the domain, Y the codomain (often also called the range).

Let X, Y, Z be sets and f : X → Y, g : Y → Z functions. The composition of f and g is the function

g ∘ f : X → Z,   (g ∘ f)(x) := g(f(x)) for every x ∈ X.

Example. f(x) = x + 1, g(x) = x2. Then (g ∘ f)(3) = g(4) = 16, but (f ∘ g)(3) = f(9) = 10 — the order matters.

In plain words

A function is a vending machine: you put an input in and always the same output comes out — never two, never none. Composition is connecting machines one after another. A neural network is nothing but a long chain of functions composed like this, one layer after another.

  • x ↦ x2 — “x maps to x squared”; a description of a function without a name,
  • fθ(x) — a function whose behaviour is set by the parameters θ (“f sub theta of x”),
  • g ∘ f — composition: first f, then g, that is g(f(x)),
  • θ ← θ − η ∇J — the left arrow is assignment in an algorithm: “the new value of θ is…”; := means “is defined as”.

The last line is the most important piece of notation in the whole series — a step of gradient descent. Broken down:

θ ← θ − η ∇J(θ)

θ
the model parameters; on the right the old value, on the left the new one — the same letter, because it is the same variable at different times
←
assignment, not equality: θ = θ − … would only hold for a zero step, whereas ← says “overwrite”
−
the gradient points uphill; we want to make the error smaller, so we go the opposite way
η
learning rate — a small positive number; the gradient is only local information, and with a long step we would jump over the hill
∇J(θ)
the gradient of the error J at the current point — in which direction the error grows fastest and by how much
Example — three steps of gradient descent

We look for argmin J(θ) = (θ − 2)2. The derivative is J′(θ) = 2(θ − 2). We start at θ = 5 with η = 0.25:

step 1: θ ← 5 − 0.25 · 2 · (5 − 2) = 5 − 1.5 = 3.5

step 2: θ ← 3.5 − 0.25 · 2 · (3.5 − 2) = 3.5 − 0.75 = 2.75

step 3: θ ← 2.75 − 0.25 · 2 · (2.75 − 2) = 2.75 − 0.375 = 2.375

(Colours as in the formula above: η, the gradient J′(θ), the old and new value of θ.)

The distance from the minimum 2 is exactly halved with every step (3, 1.5, 0.75, 0.375), because after a step the new distance is (θ − 2η(θ − 2)) − 2 = (1 − 2η)(θ − 2) and 1 − 2 · 0.25 = 0.5. With η = 0.5 we would reach the goal in one step; with η > 1 the distance would grow.

Definition — min, max, argmin, argmax

Let X be a non-empty set and f : X → ℝ a function. The argument of the minimum of f on X is the set

argminx ∈ X f(x) := {x* ∈ X : ∀x ∈ X : f(x*) ≤ f(x)}.

If this set is non-empty and x* is any of its elements, the minimum of f on X is the number

minx ∈ X f(x) := f(x*)

(it does not matter which element we pick — they all give the same value). So the minimum is the smallest value that f takes on X, and argmin is the set of all the places where it takes it. If argmin has a single element x*, one writes for short argminx ∈ X f(x) = x*. On an infinite set the minimum need not exist: f(x) = x on the interval (0, 1) gets arbitrarily close to zero but never reaches it, and argmin is empty.

argmax and max are defined in the same way, only with the inequality f(x*) ≥ f(x).

In plain words

min answers the question “how low can you get?”, argmin the question “where is that?”. For f(x) = (x − 2)2, min f = 0, but argmin f = 2. Training a model is a search for the argmin — we don’t care how small the error is, but which parameters give it.

On a finite set the argmin is found by simply going through it. For f(x) = (x − 2)2 on X = {0, 1, 2, 3, 4} the values are 4, 1, 0, 1, 4, so min = 0 and argmin = 2. On X = {0, 1, 3, 4} (without the 2), min = 1 but argmin = {1, 3} — two places with the same value, which is why the definition talks about a set.

def argmin(f, X):
    nejlepsi, hodnota = [], float("inf")   # nothing yet, “infinitely bad”
    for x in X:
        if f(x) < hodnota:                 # new minimum: forget the previous ones
            nejlepsi, hodnota = [x], f(x)
        elif f(x) == hodnota:              # a tie: add to the set
            nejlepsi.append(x)
    return nejlepsi, hodnota               # argmin and min at once

6. Logical connectives and quantifiers

NotationRead asExample
¬Pnot P¬(x > 3) is the same as x ≤ 3
P ∧ QP and Qx > 0 ∧ x < 1 — x lies between 0 and 1
P ∨ QP or Q (or both)x < 0 ∨ x > 1
P ⇒ Qif P, then Qx > 2 ⇒ x2 > 4
P ⇔ QP if and only if Qx2 = 0 ⇔ x = 0
∀x : P(x)for all x, P holds∀x ∈ ℝ : x2 ≥ 0
∃x : P(x)there exists an x such that P∃x ∈ ℕ : x > 100
Theorem — negating quantifiers

Let X be a set and P(x) a statement about an element x that for every x ∈ X is either true or false. Then

¬(∀x ∈ X : P(x)) ⇔ ∃x ∈ X : ¬P(x),

¬(∃x ∈ X : P(x)) ⇔ ∀x ∈ X : ¬P(x).

So negation swaps ∀ and ∃ and moves on to the statement P. This follows directly from the meaning of the quantifiers: “does not hold for all” means exactly “fails for at least one”.

In plain words

“It is not true that all swans are white” means “there is a swan that is not white”. To refute a “for all” claim, a single counterexample is enough — and that is exactly how mathematics often proves things.

Watch out for the implication ⇒: it only claims that when P holds, Q holds too. It says nothing about the case where P does not hold. From x > 2 ⇒ x2 > 4 it does not follow that x2 > 4 ⇒ x > 2 — just take x = −3.

Definition — connectives by truth table

Denote by {0, 1} the set of truth values (1 = true, 0 = false) and let P, Q ∈ {0, 1}. The logical connectives are the functions

¬ : {0, 1} → {0, 1}   and   ∧, ∨, ⇒, ⇔ : {0, 1} × {0, 1} → {0, 1}

given by the rules

  1. ¬P := 1 − P;
  2. P ∧ Q := min(P, Q) — equals 1 if and only if P = 1 and at the same time Q = 1;
  3. P ∨ Q := max(P, Q) — equals 1 if and only if P = 1 or Q = 1 (or both);
  4. P ⇒ Q := max(1 − P, Q) — equals 0 if and only if P = 1 and Q = 0;
  5. P ⇔ Q := 1 if P = Q, and 0 otherwise.

Since {0, 1} has only two values, each connective is fully determined by a table:

PQ¬PP ∧ QP ∨ QP ⇒ QP ⇔ Q
1101111
1000100
0110110
0010011

The implication is false in a single row: P holds and Q does not. That is why P ⇒ Q means the same as ¬P ∨ Q (compare the columns).

In plain words

“If it rains, I will take an umbrella.” You break the promise only if it rains and you have no umbrella. If it does not rain, the promise holds whether you have an umbrella or not — it said nothing about that situation.

7. Other symbols you will meet

  • a/b or a / b — division, “a over b” (for b ≠ 0); both notations mean the same. The slash is handy where a formula has to stay on one line (in code, in plain text); the fraction is clearer, because without brackets it shows exactly what is divided by what: x − μ/σ is the same as (x − μ) / σ. That is why on this website we typeset division as a fraction everywhere,
  • |x| — absolute value (|−3| = 3); ‖x‖ — the length of a vector (norm),
  • ⌊x⌋, ⌈x⌉ — floor and ceiling, rounding down and up (⌊2.7⌋ = 2, ⌈2.1⌉ = 3),
  • ≈ — approximately equal; ∝ — proportional to (“grows the same way as”); ≫ — much greater than,
  • ∞ — infinity; [0, 1] — an interval including its endpoints, (0, 1) — without them,
  • ∇f (“nabla f” or “del f”) — the gradient, the direction of steepest ascent; ∂f/∂x — partial derivative,
  • O(n2) — “big O of n squared”: how fast an algorithm’s time or memory grows,
  • P(A | B) — the probability of A given that B has happened (“P of A given B”); 𝔼[X] — expected value,
  • w⊤ — transpose: a row becomes a column and vice versa; w⊤x is the dot product.

The norm and the dot product can be written as a sum, which we can already read:

‖x‖ = √∑i=1n xi2

‖x‖
the length of a vector x ∈ ℝn; the double bars distinguish it from the absolute value of a number
xi2
the square of one coordinate — a negative coordinate contributes to the length just like a positive one
∑i=1n
adds up the contributions of all coordinates; this is Pythagoras’ theorem, just for any number of dimensions
√
the square root (the bar over the expression shows how far it reaches) brings the result back to the same units as the coordinates — the length of (3, 4) should be 5, not 25
‖(3, 4)‖ = √32 + 42 = √9 + 16 = √25 = 5.

w⊤x = ∑i=1n wi xi

w⊤x
the dot product — one number from two vectors of the same length; ⊤ turns w into a row so that “row times column” works
wi
the weight of the i-th input — how much and in which direction (the sign) it matters
xi
the i-th input; it is multiplied only by its own weight
∑
adds up the weighted inputs into one number — this is how a neuron “votes”
w = (2, −1, 0.5), x = (1, 3, 4): w⊤x = 2 · 1 + (−1) · 3 + 0.5 · 4 = 2 − 3 + 2 = 1. Also x⊤x = ‖x‖2.
Definition — big O

Let g : ℕ → ℝ be a function with non-negative values (g(n) ≥ 0 for all n ∈ ℕ). The big O of g is the set of functions

O(g) := {f : ℕ → ℝ : f(n) ≥ 0 for all n ∈ ℕ ∧ ∃c ∈ ℝ, c > 0 ∃n0 ∈ ℕ ∀n ∈ ℕ, n ≥ n0 : f(n) ≤ c · g(n)}.

So for a function f : ℕ → ℝ with non-negative values, f ∈ O(g) (often written just f = O(g)) if and only if the following condition holds, which we break down term by term:

∃c > 0 ∃n0 ∈ ℕ ∀n ≥ n0 : f(n) ≤ c · g(n)

∃c > 0
we may multiply g by a constant — big O does not care whether the computer is twice as fast, only how the time grows
∃n0 ∈ ℕ
we may ignore small inputs — on them details decide, not the shape of the growth
∀n ≥ n0
but from that threshold on, for all larger inputs, without exception
f(n) ≤ c · g(n)
the claim itself: f grows no faster than g — g is an upper bound

Example. f(n) = 3n2 + 5n ∈ O(n2), i.e. g(n) = n2: we choose c = 4 and n0 = 5. Then 3n2 + 5n ≤ 4n2 ⇔ 5n ≤ n2 ⇔ n ≥ 5 (for n > 0). For n = 10: 350 ≤ 4 · 100 = 400 (colours as in the breakdown above).

Definition — conditional probability and expected value

Let (Ω, 𝓕, P) be a probability space (see the part What probability is) and let A, B ∈ 𝓕 be events with P(B) > 0. The conditional probability of the event A given B is the number

P(A | B) := P(A ∩ B)/P(B).

Further, let X : Ω → ℝ be a random variable (see the part Random variables and the cumulative distribution function) that takes only finitely many mutually distinct values x1, …, xk, and let P(X = x) denote P({ω ∈ Ω : X(ω) = x}). The expected value of X is the number

𝔼[X] := ∑j=1k xj · P(X = xj),

that is, the sum of all possible values, each weighted by its probability.

Example. A die roll, A = “a six came up”, B = “an even number came up”. P(A ∩ B) = 1/6, P(B) = 3/6, so P(A | B) = 1/6/3/6 = 1/3: once we know an even number came up, three equally likely outcomes remain. The expected value of a roll: 𝔼[X] = (1 + 2 + 3 + 4 + 5 + 6) · 1/6 = 21/6 = 3.5 — a value that can never come up by itself, but is the average of a long series of rolls.

8. Read a whole definition

Now let’s put it all together. This is the definition of training a model from the part about types of machine learning. Each term has a colour, and under the formula, in the same colour, is why it is there:

θ* = argminθ 1/n ∑i=1n L( fθ(xi), yi )

θ*
the best model parameters — the result of training; the star distinguishes them from the θ we try out during the search
argminθ
we want the place of the minimum, not its value — we then use the model with the parameters, not with the error number; the subscript θ says what we may change (not the data)
1/n ∑i=1n
the average over all n examples — the model should be good on average over all the data, not just on one example
L
the loss function — turns the pair “answer, correct answer” into a single number, how much the error costs; without it there would be nothing to minimize
fθ(xi)
what the model with parameters θ answers for the i-th input — the only place where θ appears in the formula, and so the only way to influence the error
yi
the correct answer for the i-th input — the yardstick we compare the model’s answer against
The expression after argmin is called the empirical risk: the average loss on the training data.
The whole sentence in plain words

The best model parameters are the ones with which the model, on average over all the training data, makes the smallest error between what it answers and what is correct.

Example — the empirical risk with numbers

Data: three pairs (xi, yi) = (1, 2), (2, 3), (3, 7). The model fθ(x) = θ · x has a single parameter, the loss is the squared error L(ŷ, y) = (ŷ − y)2. Denote the average loss R(θ) = 1/3 ∑i=13 L(fθ(xi), yi). Colours as in the formula above:

θ = 2: answers 2, 4, 6, errors 0, 1, −1, R = 1/3 (0 + 1 + 1) ≈ 0.667

θ = 2.5: answers 2.5, 5, 7.5, errors 0.5, 2, 0.5, R = 1/3 (0.25 + 4 + 0.25) = 1.5

The exact argmin: setting the derivative R′(θ) = 2/3 ∑i=13 (θ xi − yi) xi equal to zero gives θ* = ∑ xi yi/∑ xi2 = 2 + 6 + 21/1 + 4 + 9 = 29/14 ≈ 2.071 and R(θ*) ≈ 0.643.

So the min is 0.643 (no smaller error is possible with this model), and the argmin is 2.071 — that is the learned model.

And one more, from the part about search — the priority function of the A* algorithm:

f(n) = g(n) + h(n)

f(n)
the priority of state n — A* always expands the state with the smallest f; that is why one number has to sum up the whole path through n
g(n)
the cost we have already paid to reach n — known exactly; without it the algorithm would needlessly prefer states close to the goal that were reached by an expensive path
h(n)
an estimate of how much is still left to the goal (the heuristic) — thanks to it the search heads towards the goal instead of in all directions; if it never overestimates the cost, A* finds the cheapest path
A state with g = 4, h = 3 has f = 7 and comes up before a state with g = 2, h = 6 (f = 8), even though it is further from the start.

It is read “f of n equals g of n plus h of n”: the estimated cost of the whole path through state n is the cost we have already paid to reach n (g), plus an estimate of how much is still left (h). The same approach works for every definition: find the main relation (=, ≤, ⇔), break both sides into parts and translate each one into words.

9. Cheat sheet

SymbolRead asMeaning
xix sub ithe i-th element
ŷ, x̄, θ*y hat, x bar, theta starestimate, mean, optimum
∈, ∉in, not inis, is not an element of a set
⊆, ∪, ∩, ×subset, union, intersection, crossset operations
ℕ, ℤ, ℝ, ℝnN, Z, R, R to the nnatural numbers, integers, real numbers, vectors
a/b, a / ba over bdivision (typeset as a fraction on this website)
∑, ∏sum, productadd up, multiply over an index
f : X → Yf from X to Ya function and its inputs and outputs
argmin, argmaxarg min, arg maxwhere the smallest, largest value is
←, :=gets, is defined asnew value, definition
¬, ∧, ∨not, and, orlogical connectives
⇒, ⇔implies, if and only ifimplication, equivalence
∀, ∃for all, there existsquantifiers
|x|, ‖x‖absolute value, normsize of a number, length of a vector
≈, ∝, ≫approximately, proportional to, much greater thancomparison
∇, ∂nabla, partialgradient, derivative with respect to one variable
O(·)big Oorder of growth of time or memory
P(A | B), 𝔼probability of A given B, expected valueprobability

10. Summary

  • Mathematical notation is shorthand for a sentence: it is read left to right, symbol by symbol.
  • Indices tell values apart; Greek letters have established meanings in AI (θ parameters, η learning rate, γ discount).
  • ∑ is a loop that adds; 1/n ∑ is the mean; division is written as a fraction or with a slash; argmin looks for the place, not the value.
  • ∀ and ∃ turn properties into precise claims; to refute a “for all”, one counterexample is enough.

With this vocabulary you can read every definition in the series. If you come across a symbol that is missing here, write to us — we will add it.

Do you see it differently? Write to support@coden-app.com.

An Agent on your computer, driven from your phone