‹ Class 12 · Ch 13
Probability · Principle 12 of 12

A number for every outcome

A random variable is a real valued function on the sample space.

Stuck? Ask Guru

NCERT: 13.5 Bayes' Theorem

Think

Outcomes into numbers

Toss a coin twice: S = {HH, HT, TH, TT}. Often we care about a number, such as how many heads came up.

X = the number of heads. What is X(HT)?

What this lesson covers

The idea

A random variable is a real valued function whose domain is the sample space of a random experiment; e.g. for two coin tosses, X = number of heads takes values 2, 1, 1, 0, and several random variables can be defined on the same sample space.

Outcomes into numbers

Toss a coin twice: S = {HH, HT, TH, TT}. Often we care about a number, such as how many heads came up.

X = the number of heads. What is X(HT)?

  • 1
  • 2
  • 0

Give each outcome its number

Tap a tile to change its value.

Random variable

A random variable is a real valued function whose domain is the sample space of a random experiment: it gives every outcome a real number.

Two tosses, X = number of heads: X(HH) = 2, X(HT) = 1, X(TH) = 1, X(TT) = 0.

More than one random variable can be defined on the same S: Y = heads − tails gives Y(HH) = 2, Y(HT) = Y(TH) = 0, Y(TT) = −2.

Notes

Random variable: a real valued function on S, one number for each outcome. Many can be defined on the same S.

Check yourself

A random variable is …

Three coins are tossed; X = number of heads. How many outcomes have X = 2?

Answer: 3

HHT, HTH and THH: 3 outcomes.

Three coins; Y = number of heads − number of tails. Find Y(HTT).

Answer: -1

1 − 2 = −1.

  • an outcome chosen at random. An outcome is an element of S; the random variable turns it into a number.
  • a real valued function on the sample space — correct. Yes!
  • the probability of an event of the sample space. A probability is a number from 0 to 1; a random variable can take any real values.