Quantum Mechanics and Atomistic Simulation

Part 4 · Probability and statistical physics

4.1 Probability and random variables

Source: Postorino, week 4 slides, pp. 13–15, quoting De Vincenzi’s notes, ch. 5; Sciubba’s notes

Objectives

  1. Vocabulary. Classical, frequentist and axiomatic probability; random variable; probability distribution; probability density; cumulative distribution; expected value; variance; standard deviation.
  2. Theorem. Kolmogorov’s three axioms, and normalisation or .
  3. Recipe. Mean and variance of a distribution: , .
  4. Picture. Probabilities are areas under the density; the cumulative is the running area, from 0 to 1.

The slides’ boxes are excerpts from De Vincenzi’s notes, ch. 5, posted on Moodle: the equation numbers below are his. De Vincenzi’s notation: for the expected value, for the variance, for the complement of .

Definitions of probability

A probability is a quantitative measure of how possible an event is: by convention a number between 0 (the impossible event) and 1 (the certain event). A perfectly symmetric coin gives heads and tails with probability 0.5 each. The concept is intuitive, but defining it is not; the slides give three definitions.

Definition 4.1.1Classical probability (Laplace, 1812)slides w4, p. 13

The probability of an event is the ratio of the number of favourable cases to the number of possible cases, provided the latter are equally possible.

  • It fits ideal or nearly ideal situations: a perfectly cubic die, a card from a well-shuffled deck, a lottery draw. Where it applies, combinatorics does the counting.
  • It is circular: “equally possible” means “equally probable”, so it uses probability to define probability.
  • It fails when the set of possible cases is infinite.
Definition 4.1.2Frequentist probability (von Mises, 1920)slides w4, p. 13

Take a repeatable experiment and a “favourable” outcome. The frequency is , the number of favourable outcomes over the number of trials . The probability is the limit to which the frequency tends as the number of trials goes to infinity:

  • It is used in insurance and quality control.
  • It sets the right relation between frequency, measured a posteriori, and probability. In the classical view probability is fixed a priori.
  • It needs trials repeatable without limit under identical conditions; real experiments meet both only approximately.
  • It says nothing about events that can’t be repeated: that a given star explodes in the next 30 days, that it rains in Rome tomorrow.
Definition 4.1.3Axiomatic probability (Kolmogorov, 1933)slides w4, p. 13

Postulate a space containing all the elementary events that can occur. The probability is a real function on the events of obeying three axioms:

  1. Positivity: .
  2. Certainty (unitarity): the certain event, the whole sample space, has .
  3. Union: if and are mutually exclusive (incompatible), , with .

Every rule of probability follows from these three. But the theory gives no operational way of assigning probabilities: the values must come from outside, from symmetry (the classical way), from frequencies, or from judgement.

Corollary 4.1.4The complementbeyond the lectures

; in particular .

Proofbeyond the lectures

and are mutually exclusive and together make , so by axioms 3 and 2, . Take , .

Loading the demo…

Figure 4.1.1 The sum of two dice. The bars are the classical probabilities ; the are frequencies from simulated rolls. Roll 10, 100 or 1000 at a time: the frequencies settle onto the probabilities, the frequentist definition (5.1) at work. Click a range of values to add up its probability.
Extra reading: subjective probability and rules for combining events

De Vincenzi, pp. 3–8, and Sciubba, pp. 1–7. Not examined.

  • Subjective definition (de Finetti, 1937). Probability is the degree of belief a coherent individual assigns to an event, given their information. Operationally, it is the price they consider fair to pay to receive 1 if the event happens; coherent means they would equally accept the reverse bet. It depends on information: someone who glimpses a side face of a die after it lands rates a “6” at 0 or 1/4, not 1/6.
  • Union of overlapping events. with the union and the intersection. Proof: is a union of disjoint events, and .
  • Conditional probability. Knowing happened shrinks the sample space to . Die: . Two dead bulbs among 7, tested one by one: .
  • Independence. , so : for independent events probabilities multiply. Three roulette wins in a row: .
  • Bayes’ theorem. A normal coin and a two-headed coin; one is picked at random and shows heads: . A test that catches 99.7 % of infections with 7.4 % false positives, in a population 0.5 % infected: a positive result means infection with probability only 6.3 %, because the infected are so rare.
  • Law of large numbers (Sciubba, pp. 5–6). As coin tosses accumulate, the fraction of heads fluctuates less and settles near 0.5. Bernoulli’s theorem: for any , . The frequency doesn’t converge to in the strict sense; it becomes ever more probable that it is close.

Discrete random variables

A random variable (variabile aleatoria, or casuale, stocastica) is one that can’t be given a definite value, only a range of values with probabilities. Its probability distribution says with what probability it takes each value.

Example 4.1.5The sum of two diceslides w4, p. 14

= the sum of two dice takes the values 2 to 12, from equally likely ordered pairs.

  • and arise one way each: . (De Vincenzi prints the first as “”, a slip.)
  • arises from 6 pairs, (1,6), (2,5), (3,4), (4,3), (5,2), (6,1): .
  • The histogram is a triangle: with .
Definition 4.1.6Probability distribution of a discrete variableslides w4, p. 14

For a discrete random variable that can take the values (possibly ), its probability distribution is the set of probabilities of the : If is a complete set of mutually exclusive events, so that can take no other values, the normalisation condition holds:

Normalisation is axioms 2 and 3 together: “ takes some value” is the certain event, and it is the union of the mutually exclusive events “” beyond the lectures.

Continuous random variables

A continuous variable takes uncountably many values . So, unlike the discrete case, the probability that it takes exactly one particular value is zero. What makes sense is the probability that it falls in an interval, ; for an infinitesimal interval this is infinitesimal too:

Definition 4.1.7Probability density functionEssentialslides w4, p. 14

is the probability density function (pdf). It has two properties:

  • it is positive or zero over the whole domain: for every ;
  • it is normalised: .

Probabilities are areas under it:

is a probability per unit , not a probability, so it can exceed 1 beyond the lectures.

Definition 4.1.8Cumulative distribution functionslides w4, p. 15

The probability that the variable takes any value below a given :

De Vincenzi’s (5.9) writes with upper limit , mixing the two letters; the slide’s figure writes it cleanly as . The figure: on the left a pdf, skewed with a long tail to the right, with a thin strip of width of area ; on the right its cumulative, rising from 0 to 1 (certainty).

Proposition 4.1.9Properties of the cumulativebeyond the lectures

never decreases; , ; ; and : the pdf is the slope of the cumulative.

Proofbeyond the lectures

, so the running integral can only grow. The limits are the empty interval and normalisation. The difference of two running integrals is the integral between them. The last is the fundamental theorem of calculus.

Loading the demo…

Figure 4.1.2 A probability density and its cumulative . Drag the ends and : the shaded area is , which equals , the rise of the cumulative between them. The and are marked. Try the distributions: the exponential is skewed like the slide’s, the Gaussian symmetric.

Expected value and variance

A distribution is fully determined by its form, but a few parameters summarise it: where its centre is (the mean), how spread out it is (the variance), how symmetric it is, and its shape. The tool for all of them is the expected value.

Definition 4.1.10Expected valueslides w4, p. 15

For any function , It is the probability-weighted average of .

Proposition 4.1.11Properties of the expected valueDe Vincenzi, p. 10
  • Linearity: , since sums and integrals are linear.
  • The expected value of a constant is the constant: by normalisation. So .
Definition 4.1.12Meanslides w4, p. 15

The mean (valore medio) is the case :

Theorem 4.1.13Varianceslides w4, p. 15

The expected value of the squared deviation is the variance: The variance is the expected value of the square minus the square of the expected value. Its square root is the standard deviation, in the same units as .

Proof

, by linearity, and .

Proposition 4.1.14Variance is not linearDe Vincenzi, p. 11

For constants and :

Proofbeyond the lectures

De Vincenzi leaves it as an exercise. The mean of is , so its deviation is ; squared, , with expected value . Shifting by moves the whole distribution without spreading it.

The mean says roughly where the probability is concentrated, and how wide that region is. Both are rough guides, and for some distributions they don’t even exist (the Cauchy, below).

Example 4.1.15One diebeyond the lectures

; . So and .

Extra reading: distributions, moments, several variables, Chebyshev

De Vincenzi, pp. 12–36, and Sciubba, pp. 8–31. Not examined.

Discrete distributions

  • Bernoulli: one trial, , ; , .
  • Binomial: successes in independent trials, . The factor is one order; the binomial coefficient counts the orders. , , .
  • Poisson: independent events at a constant rate, counted in an interval, . Mean and variance are both . It is the binomial’s limit for , with fixed. Cosmic rays at m⁻²s⁻¹ on a cm² detector for 6 s: , .

Continuous distributions

  • Uniform on : , , . A digital display’s last digit gives an uncertainty of of that digit.
  • Gaussian: . With , , . Within , , : 68.3 %, 95.4 %, 99.7 %.
  • Exponential: , mean , variance , : the waiting time to the next event of a Poisson process, and memoryless.
  • Student’s : the sample mean of a normal variable with estimated variance; wider than a Gaussian, tending to one as the degrees of freedom grow.
  • Cauchy (Breit–Wigner, Lorentzian): . No mean and no variance: the integrals diverge. It is the resonance lineshape of Proposition 1.4.7.
  • with degrees of freedom: the sum of squares of standard normals; mean , variance .

Moments. Raw , central . Skewness , kurtosis ; mode (peak) and median (half the probability on each side).

Several variables. Marginals ; covariance and correlation . , so the mean of independent measurements has variance . Propagation of uncertainty: . Change of variables: .

Chebyshev’s inequality (Sciubba, pp. 15–16): for any distribution, ; at least 75 % within , 88.9 % within , whatever the distribution.

Exercises

Exercise 4.1.1beyond the lectures

A pdf is on and 0 elsewhere. Find , , , and .

Solution

, so . on . . . , so .

Exercise 4.1.2beyond the lectures

Prove from (5.13).

Solution

.

Exercise 4.1.3beyond the lectures

Why is the probability of a continuous variable taking exactly zero, even though ?

Solution

as . Only intervals have non-zero probability: the density is probability per unit length.

Exercise 4.1.4beyond the lectures

Find the mean and variance of the sum of two dice.

Solution

By symmetry . , so : twice one die’s variance, as for independent variables.

Exercise 4.1.5beyond the lectures

For the exponential density , , find , the mean, and the probability of waiting longer than .

Solution

. . .