You are on page 1of 24

Random Variable

Prepared by:

Prof. JULIE E. AVILA Head, Senior High School


Mr. RONEL R. ALDAY Instructor, SLSU – Laboratory School

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Recall: Experiment
A probability experiment is a chance process that leads to well - defined
outcomes or results.

Examples:
• Tossing a coin
• Rolling a die
• Randomly picking five cards from an ordinary deck of 52 cards
• Randomly picking a student from a class of 20 students.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Recall: Sample Space
A sample space is the set of all possible outcomes of a probability experiment.

Example:
1. Tossing a coin
{Head, Tail}

2. Rolling a die
{1, 2, 3, 4, 5, 6}

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
More examples of Sample Space
3. Rolling two dice simultaneously
(1, 1) (1, 2) (1, 3) (1, 4) (1, 5) (1, 6)

(2, 1) (2, 2) (2, 3) (2, 4) (2, 5) (2, 6)

(3, 1) (3, 2) (3, 3) (3, 4) (3, 5) (3, 6)

(4, 1) (4, 2) (4, 3) (4, 4) (4, 5) (4, 6)

(5, 1) (5, 2) (5, 3) (5, 4) (5, 5) (5, 6)

(6, 1) (6, 2) (6, 3) (6, 4) (6, 5) (6, 6)

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
More examples of Sample Space
4. Tossing two coins simultaneously.
{𝐻𝐻, 𝐻𝑇, 𝑇𝐻, 𝑇𝑇}

Where:
𝐻 = 𝐻𝑒𝑎𝑑
𝑇 = 𝑇𝑎𝑖𝑙

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Definition: Random Variable
A random variable is a function that associates a real number with each element
in the sample space. It is a variable whose values are determined by chance.

Example:
EXPERIMENT EXAMPLE OF RANDOM VARIABLE

1. Tossing four coins at the same time. Number of heads obtained

2. Rolling two dice at the same time. Sum of outcomes

3. Randomly picking three cards from an ordinary Number of hearts obtained


deck of 52 cards.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Discrete vs. Continuous
• A random variable is a discrete random variable if its set of possible outcomes
is countable.
Example:
➢Number of defective chairs produced in a factory
• A random variable is a continuous random variable if it takes on values on a
continuous scale.
➢Height
➢Temperature
NOTE: This lesson will focus on discrete random variable.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Example 1
Suppose that four coins are tossed. Let 𝑋 be the random variable representing
the number of heads that occur. Find the values of the random variable 𝑋.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
List all the elements of the sample space of an experiment. Since the
experiment is tossing four coins, we have:
𝐻𝐻𝐻𝐻 𝐻𝑇𝐻𝐻 𝑇𝐻𝐻𝐻 𝑇𝑇𝐻𝐻

𝐻𝐻𝐻𝑇 𝐻𝑇𝐻𝑇 𝑇𝐻𝐻𝑇 𝑇𝑇𝐻𝑇

𝐻𝐻𝑇𝐻 𝐻𝑇𝑇𝐻 𝑇𝐻𝑇𝐻 𝑇𝑇𝑇𝐻

𝐻𝐻𝑇𝑇 𝐻𝑇𝑇𝑇 𝑇𝐻𝑇𝑇 𝑇𝑇𝑇𝑇

Where: 𝐻 = 𝐻𝑒𝑎𝑑 & 𝑇 = 𝑇𝑎𝑖𝑙

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
Associate each element of the sample space to number of heads (the random
variable 𝑋)
Possible outcomes Value of the Random
Variable 𝑋
𝐻𝐻𝐻𝐻 4
𝐻𝐻𝐻𝑇 3
𝐻𝐻𝑇𝐻 3
𝐻𝐻𝑇𝑇 2
𝐻𝑇𝐻𝐻 3
𝐻𝑇𝐻𝑇 2
𝐻𝑇𝑇𝐻 2
𝐻𝑇𝑇𝑇 1

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
… continued
Possible outcomes Value of the Random
Variable 𝑋
𝑇𝐻𝐻𝐻 3
𝑇𝐻𝐻𝑇 2
𝑇𝐻𝑇𝐻 2
𝑇𝐻𝑇𝑇 1
𝑇𝑇𝐻𝐻 2
𝑇𝑇𝐻𝑇 1
𝑇𝑇𝑇𝐻 1
𝑇𝑇𝑇𝑇 0

The possible values of 𝑋 are 0, 1, 2, 3 and 4.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Example 2
A family has three children. Let 𝑋 represent the number of boys. Determine the
values of the random variable 𝑋.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
The elements of the sample space are listed at the first column and the value of
the random variable 𝑋 (number of boys) is at the second column.
Elements of the Sample Value of the Random Variable
Space 𝑋
𝐵𝐵𝐵 3
𝐵𝐵𝐺 2
𝐵𝐺𝐵 2
𝐵𝐺𝐺 1
𝐺𝐵𝐵 2
𝐺𝐵𝐺 1
𝐺𝐺𝐵 1
𝐺𝐺𝐺 0

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
The possible values of 𝑋 are 0, 1, 2, and 3.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Example 3
A box contains five equally sized balls numbered as 1, 2, 3, 4 and 5. Suppose
that someone is to randomly draw two balls in succession (without
replacement) from the box. Let 𝑋 be the sum of the two numbers drawn.
Determine the values of the random variable 𝑋.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
Since we are to draw two balls in succession without replacement, whatever
ball is taken from first draw CANNOT be taken again in the second draw. Thus,
the elements of the sample space are:
1,2 1,3 1,4 1,5

2,1 2,3 2,4 2,5

3,1 3,2 3,4 3,5

4,1 4,2 4,3 4,5

5,1 5,2 5,3 5,4

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
Thus, we have the value of the random variable 𝑋 (sum of two numbers) for each element of
the sample space:
Elements of the Sample Space Value of the Random Variable
𝑋
1,2 3
2,1 3
3,1 4
4,1 5
5,1 6
1,3 4
2,3 5
3,2 5
4,2 6
5,2 7
SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL
slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
… continued
Elements of the Sample Space Value of the Random Variable
𝑋
1,4 5
2,4 6
3,4 7
4,3 7
5,3 8
1,5 6
2,5 7
3,5 8
4,5 9
5,4 9

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
The possible values of 𝑋 are 3, 4, 5, 6, 7, 8 and 9.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Example 4
A box contains five equally sized balls numbered as 1, 2, 3, 4 and 5. Suppose
that someone is to randomly draw two balls in succession (with replacement)
from the box. Let 𝑋 be the absolute difference of the two numbers drawn.
Determine the values of the random variable 𝑋.

NOTE: The absolute difference of two numbers 𝑎 & 𝑏 is |𝑎 − 𝑏|. For instance,
the absolute difference of 3 & 5 is 3 − 5 = −2 = 2.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
Since we are to draw two balls in succession with replacement, whatever ball is
taken from first draw MAY still be taken again in the second draw. Thus, the
elements of the sample space are:
1,1 1,2 1,3 1,4 1,5

2,1 2,2 2,3 2,4 2,5

3,1 3,2 3,3 3,4 3,5

4,1 4,2 4,3 4,4 4,5

5,1 5,2 5,3 5,4 5,5

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
Thus, we have the value of the random variable 𝑋 (absolute difference of two numbers) for
each element of the sample space:
Elements of the Sample Space Value of the Random Variable
𝑋
1,1 0
2,1 1
3,1 2
4,1 3
5,1 4
1,2 1
2,2 0
3,2 1
4,2 2
5,2 3
SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL
slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
… continued.
Elements of the Sample Space Value of the Random Variable
𝑋
1,3 2
2,3 1
3,3 0
4,3 1
5,3 2
1,4 3
2,4 2
3,4 1
4,4 0
5,4 1

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043
Solution
… continued.

Elements of the Sample Space Value of the Random Variable


𝑋
1,5 4
2,5 3
3,5 2
4,5 1
5,5 0

The possible values of 𝑋 are 0, 1, 2, 3 and 4.

SOUTHERN LUZON STATE UNIVERSITY ⃒ LABORATORY SCHOOL


slsu_labschool@slsu.edu.ph (042) 540-7576 / 0949-873-5043

You might also like