You are on page 1of 10

LECTURE 5: RANDOM VARIABLE Definition 3.1 A random variable is a function that associates a.

real
number with each element in the sample space.
 TOPICS:
3. Random variables and their probability distributions
 It is an item used to define or denote the outcomes in the sample
a. Random Variable and their probability distributions space known as the sample points.
 It assigns a numerical value to each outcome in the sample space.
b. Cumulative Distribution Functions
 It is an item whose numerical value is of a random nature, and
c. Expected Values of Random Variables therefore cannot be known with certainty.
 LEARNING OUTCOMES:
 Understand the concepts of a random variable and a Example 1:
probability distribution. If we toss a coin three times, we can use the random variable x to
 Compute and interpret the expected value, variance, define the sample points of this experiment as the number of heads
and standard deviation for a discrete random variable. that occur.

Sample Points x Probability or f(x)

HHH 3 1/8
INTRODUCTION:
HHT 2 1/8
Statistics is concerned with making inferences about
populations and population characteristics. Experiments are conducted HTH 2 1/8
with results that are subject to chance. The testing' of a number of
HTT 1 1/8
electronic components is an example of a statistical experiment, a term
that is used to describe any process by which several chance THH 2 1/8
observations arc generated. It is often important to allocate a numerical
description to the outcome. THT 1 1/8
TTH 1 1/8

TTT 0 1/8

In tabular form, the probability distribution function (p.d.f.) of the


random variable x is given as follows:
x f(x) Sample Space y f(y)

0 1/8 RR 2 1/4

1 3/8 RB 1 1/2

2 3/8 BR 1

3 1/8 BB 0 1/4

-----------------

f(x) = 1
Types of random variable

In formula form: 1. Discrete - this type of random variable can only assume a finite or
countably infinite
3! number of possible values

f(x) =  3  (1/8) = -------------- * (1/8) x = 0, 1, 2, 3

x x! (3 - x)! Ex. no. of heads in a coin experiment, no. of defectives produced,
demand or sales of a product in units per day, quiz average of students
in Math 403 rounded off to the nearest unit, no. of customer arrivals in
a bank per hour, no. of customer complaints received per day by
Example 2: Two balls are drawn in succession without replacement customer service, weight of a can of corned beef to the nearest gram,
from an urn containing 4 red balls and 3 black balls. The possible etc.
outcomes and the values y of the random variable: Y, where y is the
number of red balls, are:
2. Continuous - this type of random variable can take on any value Note:
within a given range
Ex. temperature, volume, weight, diameter, time, quiz average of a There are cases where the random variable is categorical in
student, etc. nature. Variables, often called dummy variables, are used. A good
illustration is the case in which the random variable is binary in nature,
as shown in the following example.
Ways by which a continuous variable can be converted into a discrete
variable
a. Consider the simple condition in which components are
1. Specifying the level of accuracy of measurement arriving from the production line and they are stipulated to be
Ex. Continuous variable: diameter of a ball bearing in inches defective or not defective. Define the random variable X by 1,
if the component is defective; 0 if the component is not
Discrete variable: diameter of a ball bearing to the nearest tenth defective.
of an inch

2. Introducing categories to describe the diff. levels of values of the Definition 3.2 If a sample space contains a finite number of
random variable possibilities or an unending sequence with as many elements as there
Ex. Continuous variable: Final grades (raw scores) of students in are whole numbers, it is called a discrete sample space.
Math 403

Discrete variable: Final grades (course card grades)


Definition 3.3 If a sample space contains an infinite number of
Grade Range Final Grade possibilities equal to the number of points on a line segment, it is
below 60 0.0 called a continuous sample space.

60 - 65 1.0

66 - 71 1.5

72 - 77 2.0

78 - 83 2.5

84 - 89 3.0

90 - 95 3.5

96 - 100 4.0
PROBABILITY DISTRIBUTION Discrete Probability Distribution

 a table or a function which helps us determine or compute the Characteristics of a discrete probability distribution
probability associated to each value of the random variable 1. f(x)  0  x (for all x)
2. f(x) = 1
3. P(X = x) = f(x)  refers to the value of the function when the
Types of Probability Distribution random variable X is
equal to a specific value x
1. Discrete probability distribution - one that involves a discrete
random variable
Ex. Ex. In the experiment of tossing a coin three times:

e- x

f(x) = ----------  Poisson Distribution Outcomes:

x!
H H H
where x = the no. of bank arrivals per minute
H H T

H T H
2. Continuous probability distribution - one that involves a
continuous random H T T
variable
T H H
Ex.
T H T
1
T T H
f(t) = ---- e-t/  Exponential Distribution
T T T

where t = inter-arrival time of customers entering a bank


x
(head) 0 1 2 3 ΣP

P(X=x) 1/8 3/8 3/8 1/8 8/8


Cumulative Distribution Function
 a table or a function that determines the probability that the
P(X = 2) = f (2) = 3/8 random variable X takes on values that are less than or equal to a
specific value x
x

 denoted by: F(x) = P(X  x) =  f(x) where: L = lower limit of


possible x values
Definition 3.4 The set of ordered pairs (x, f(x)) is a probability
X=L
function, probability mass function, or probability distribution of the
discrete random variable X if, for each possible outcome x,

1. f(x) > 0, Example:


2. Σf(x) = 1
3. P(X = x) = f(x) x f(x) F(x)

0 1/8 1/8
Example: A shipment of 8 similar microcomputers to a retail outlet
contains 3 that are defective. If a school makes a random purchase of 2 1 3/8 4/8
of these computers, find the probability distribution for the number of 2 3/8 7/8
defectives.
3 1/8 1
Thus the probability distribution of X is:

f(2) = 3/8
x (defective) 0 1 2 ΣP
2
P(X=x) 10/28 15/28 3/28 28/28
F(2) = P(X  2) =  f(x) = f(0) + f(1) + f(2) = 1/8 + 3/8 + 3/8 =
7/8

X=0
Definition 3.5 The cumulative distribution function F(x) of a Example 2:
discrete random variable X with probability distribution f(x) is:

x (head) 0 1 2 3 ΣP
F (x) = P(X  x) = for -∞ < x < ∞
P(X=x) = f(x) 1/8 3/8 3/8 1/8 8/8

F(X) 1/8 1/2 7/8 1

Example 1:
F (x) =
Sample Space y f(y) F(y)

RR 2 1/4 1

RB 1 3/4

BR 1 1/2 1 for x ≥3

BB 0 1/4 1/4

F (y) =
Methods of Graphing Discrete Probability Distributions
Continuous Probability Distribution
1. Bar Chart
2. Probability Histogram
The probability distribution of a continuous random variable is
Note: Area of histogram = Width x Height = Probability
referred to as the continuous density function.

Note: Unlike in the discrete case, f(x) dose not specify the probability
that the random variable X takes on a specific value x, i.e., P(X = x) 
f(x). Probabilities in continuous distributions are evaluated for a given
range.

This time, the probability (that the random variable x takes on values
within a given range x1 to x2) is represented by the area under the
curve.
Characteristics of a continuous probability distribution

1. f(x)  0 1
2. P(X = c) = 0 since ----- = 0

Consequence: P(a  x  b) = P(a  x  b) = P(a  x  b) = P(a  x  b)

b

3. P(a  x  b) =  f(x) dx
Derivation of the Continuous Curve a
1. Construct histograms (as in the discrete case)
2. As x  0, the curve f(x) is obtained by connecting the points U
with a smooth curve.
4.  f(x) dx = 1 where: L = lower limit of possible range of x
values
L U = upper limit of possible range of x
values

Note: The total area under the curve represents the probability of the
entire sample space.

5. P(X = x)  f(x), i.e., P(X = 2)  f(2)

Definition 3.6 The function f(x) is a probability density function for the
continuous random variable X, defined over the set of real numbers R,
Most Common Curves
1. Normal Curve - symmetric if
2. Skewed to the right - positively skewed
1. f (x) ≥ o for all x € R
3. Skewed to the left - negatively skewed
2.
3.
Example: Assessment Tasks:

Suppose that the error in the reaction temperature, in °C, for a


controlled laboratory experiment is a continuous random variable X 1. A construction company has to complete a project no later than
having the probability density function: four months from now or there will be cost overruns. The people
involved in the project believe that there are four possible values of
x, defined as the number of months to complete the project. These
are 3, 3.5, 4, and 4.5 months. Furthermore, it is believed that these
four possibilities are in the ratio of 1:2:4:3. Find:
f (x) = a. f(x)
b. F(x)
c. What is the probability that the project will be completed late?
d. If the project is completed on time, what is the probability that
it will be completed in less than four months?

(a) Verify condition 2 of Definition 3.6.


2. Given: x  0 1 2 3 4 5 6
(b) Find P(Q < X < 1). -------------------------------------------------------
Cumulative Density Function f(x)  .1 .15 .05 .25 .35 .06 .04
To derive the cumulative density function, just change x to t in the
original probability formula. F(x) is obtained by integrating the
function and then substituting t by x.
Req’d.: Use F(x) to compute for the following:
x
a. P(x  5) b. P(x  3) c. P(x  4) d. P(x = 5) e. P(x  6)
F(x) = P(X  x) = f(t) dt f. P(2  x  6)

L
3. From a box containing 5 red chips and 8 blue chips, three chips are
P(x  A) = F(A); P(x  A) = 1 - F(A); P(A  x  B) = F(B) - F(A) drawn in succession. Find the probability distribution for the
number of blue chips selected if:
Definition 3.7 The cumulative distribution function F(x) of a a. sampling is done with replacement
continuous random with density function f(x) is b. sampling is done without replacement

4. A delegation of 5 was selected at random from a list of scholars of


F (x) = P (X≤a) = whom 5 are sophomores, 10 are juniors and 5 are seniors.
a. Give the probability distribution function of the variable,
number of senior students in the delegation.
b. Find the probability that less than 3 seniors will be sent as
delegates.

5. A box of a dozen eggs contains 7 good eggs and 5 bad eggs. Mr.
Thomas Cook is preparing breakfast for his family - one wife and
two kids. He plans to cook an egg for each one of them plus some
bacon. He randomly selects 4 eggs from the box and sets these
aside in a bowl.
a. Determine the probability distribution function of the number
of good eggs contained in the bowl.
b. What is the probability that the bowl contains at most one bad
egg?
c. What is the probability that Mr. Cook will have to get eggs
from the box again?

6. An operations research analyst has found that the cumulative


distribution of a random variable is given by: F(x) = x2/16 x=
1, 2, 3, 4 Req’d.: Find f(x)

You might also like