## 1.1 Definitions

Definition 1.1 (Sample space) A sample space, often denoted by $$S$$, is the set of all possible outcomes of a random trial or experiment.
Definition 1.2 (Random) An event is random if its outcome is uncertain, and is (at least partially) due to chance.
Definition 1.3 (Variable) A variable changes its value from situation to situation, or from realisation to realisation. That is, the value varies.

Example 1.1 (Variables; sample space) The country in which people were born is a variable; it varies from person to person.

The sample space is rather large, but we could use this more restricted sample space: $S = \{ \text{Australia}, \text{UK}, \text{China}, \text{Canada}, \text{Elsewhere}\}.$

Definition 1.4 (Random variable) A random variable (often written as ) is a ‘rule’ associating a number with each outcome in a sample space $$S$$.

Mathematically: a rv is a function whose domain is the sample space $$S$$, and whose range is a set of real numbers.
Example 1.2 (Random variables) We could (arbitrarily) define a rv, say $$C$$, such that $C = \left\{ \begin{array}{lr} 1 & \text{for Australia}\\ 2 & \text{for UK}\\ 3 & \text{for China}\\ 4 & \text{for Canada}\\ 5 & \text{for elsewhere} \end{array} \right.$

A rv is often denoted by a capital letter (for example, $$X$$), and lower case letters used (for example, $$x$$) for the value that the rv takes.

So $$\Pr(X=x)$$ means “the probability that the rv $$X$$ takes a particular value $$x$$.”

Sometimes, we just write $$x$$ for both when there is no ambiguity.

Example 1.3 (Random variables) Suppose we are examing delicate light bulbs, and keep trying them until we find one that fails.

The rv $$X$$ can be defined as ‘the number of bulbs we try until we find one that fails.’

The sample space is $$S = \{1, 2, 3, \dots\}$$. Notice that there’s no upper limit in theory.

If we write $$\Pr(X > 4)$$, this means ‘the probability that more than four trials are needed to find a bulb that fails.’
Example 1.4 (Random variables) The heights of adult Australian females in centimetres is a random variable, say $$H$$.