Chapter 7: Discrete vs. Continuous Random Variables

Meike Niederhausen and Nicky Wakim

2023-10-09

Learning Objectives

  1. Map the sample space to the set of real numbers using a discrete and continuous random variable

  2. Distinguish between discrete and continuous random variables from a written description

What is a random variable?

Definition: Random Variable

For a given sample space \(S\), a random variable (r.v.) is a function whose domain is \(S\) and whose range is the set of real numbers \(\mathbb{R}\). A random variable assigns a real number to each outcome in the sample space.

Let’s demonstrate this definition with our coin toss

Example 1

Suppose we toss 3 fair coins.

  1. What is the sample space?

  2. What are the probabilities for each of the elements in the sample space?

  3. What are the probabilities that you get 0, 1, 2, or 3 tails?

Let’s stretch our definition of random variables

Example 2

What are some other random variables we could consider in Example 1?

Some remarks on random variables

  • A random variable’s value is completely determined by the outcome \(\omega\), where \(\omega \in S\)

    • What is random is the outcome \(\omega\)
  • A random variable is a function from the sample space (with outcomes \(\omega\)) to the set of real numbers

    • We typically write \(X\) instead of \(X(\omega)\), where \(X\) is our random variable
  • For example, if we roll three dice, there are \(6^3 = 216\) possible outcomes (which is \(\omega\))

    • We can define a random variable as the sum of the of the three dice

    • If our outcome is the set of numbers the dice landed on ( \(\omega=(a,b,c)\) ), then \[ X(\omega) = X = a + b + c \]

Let’s look at a continuous R.V.

Example 3

Let \(X =\) how many hours you slept last night.

  1. What is the sample space \(S\)?

  2. What is the range of possible values for \(X\)?

  3. What is \(X(\omega)\)?

Discrete vs. Continuous r.v.’s

  • For a discrete r.v., the set of possible values is either finite or can be put into a countably infinite list

    • You could theoretically list the specific possible outcomes that the variable can take

    • If you sum the rolls of three dice, you must get a whole number. For example, you can’t get any number between 3 and 4.

   

  • Continuous r.v.’s take on values from continuous intervals, or unions of continuous intervals

    • Variable takes on a range of values, but there are infinitely possible values within the range

    • If you keep track of the time you sleep, you can sleep for 8 hours or 7.9 hours or 7.99 hours or 7.999 hours …