0% found this document useful (0 votes)
5 views23 pages

Probability and Statistics - Lecture 4

The document provides an overview of random variables, focusing on discrete random variables and their properties. It defines random variables, explains their types, and discusses discrete probability distribution functions with examples. Additionally, it includes calculations for probabilities and expected values related to discrete random variables.

Uploaded by

Mohamed Alaa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views23 pages

Probability and Statistics - Lecture 4

The document provides an overview of random variables, focusing on discrete random variables and their properties. It defines random variables, explains their types, and discusses discrete probability distribution functions with examples. Additionally, it includes calculations for probabilities and expected values related to discrete random variables.

Uploaded by

Mohamed Alaa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

Random Variable

Week No. Topic


1 Probability - Sample Space – events – Venn diagram -
Relations between the events
2 Independent events – dependent events – Conditional
Probability
3 Bayes Rules
4 Random variable (discrete random variables)

• Discrete Random Variable


• Discrete Probability Distribution Function
• The Cumulative Distribution Function
• Mean and Variance of A discrete Random
Variable
Random Variable (Random Variable Definition)
• Definition 1 A random variable is a function that can take on any value from the
sample space and has a range of some set of real numbers, known as the experiment's
random variable.
• Types of Random Variables
• Random variables can be classified as-
#Discrete Random Variables and
#Continuous Random Variables
• Discrete Random Variables
These are the random variable which can take on only finite number of values in a
finite observation interval. So, we can say that to discrete random variable has distinct
values that can be counted.
What is the definition of Random variable?

A random variable is a function or rule that assigns a


number to each outcome of an experiment. Basically, it
is just a symbol that represents the outcome of an
experiment

Example (1): In the experiment of tossing a fair coin twice, the outcomes are 𝐻𝐻, 𝐻𝑇, 𝑇𝐻, 𝑇𝑇 , we are
interested in the number of Heads in each outcome.

𝐻𝐻
2 1Τ4
𝐻𝑇
1 1Τ2
𝑇𝐻
1Τ4
𝑇𝑇 0

𝑆 𝑋 𝑃(𝑋)
Note that: We will use capital letters from the end of the alphabet to represent a random variable.

✓ Usually, 𝑋.
✓ The corresponding lower-case letter will represent a particular value of the random variable.
✓ 𝑃(𝑋 = 𝑥) is the probability that the random variable 𝑋 is equal to the value 𝑥.

Types of Random Variables

Discrete Random Variable Continuous Random variable


Discrete Probability Distribution Function
The set of ordered pairs (𝑥, 𝑓(𝑥)) is a probability 1. 𝑓(𝑥) ≥ 0,
function, probability mass function, or probability 2. σ𝑛𝑖=1 𝑓(𝑥) = 1,
distribution function of the discrete random variable 3. 𝑃(𝑋 = 𝑥) = 𝑓(𝑥).
𝑋 if, for each possible outcome 𝑥:

Example (1): A family consisted of 3 children assume the random variable 𝑋 gives the number of boys. Find the
values of random variable and the corresponding probability density function.

Sample Space: 𝑆 = {𝐵𝐵𝐵, 𝐵𝐵𝐺, 𝐵𝐺𝐵, 𝐵𝐺𝐺, 𝐺𝐵𝐵, 𝐺𝐵𝐺, 𝐺𝐺𝐵, 𝐺𝐺𝐺}. Each outcome is equally likely, if the random
variable is number of boys. 1
𝑃 𝑋=0 = Outcomes Random Variable
The Random Variable 𝑋 = 𝑥, 𝑥 = 0,1,2,3. 8 BBB 3
The event that the family has 3 boys 𝐴3 = {𝐵𝐵𝐵}, 3 BBG
𝑃 𝑋=1 =
8 BGB 2
The event that the family has 2 boys 𝐴2 = {𝐵𝐵𝐺, 𝐵𝐺𝐵, 𝐺𝐵𝐵}, GBB
3
The event that the family has 1 boy 𝐴1 = {𝐵𝐺𝐺, 𝐺𝐵𝐺, 𝐺𝐺𝐵}, 𝑃 𝑋 = 2 = BGG
8 GBG 1
The event that the family has no boys 𝐴0 = {𝐺𝐺𝐺}. 1 GGB
𝑃 𝑋=3 = GGG 0
8
Example (2): Tossing a fair coin three times. The random variable X gives the number of heads recorded. Find the
values of X.

The sample space is 𝑆 = {𝐻𝐻𝐻, 𝐻𝐻𝑇, 𝐻𝑇𝐻, 𝐻𝑇𝑇, 𝑇𝐻𝐻, 𝑇𝐻𝑇, 𝑇𝑇𝐻, 𝑇𝑇𝑇}. The possible values of 𝑋 are 0,1,2,3. Each
outcome is equally likely for example the event 𝑋 = 1 , when written as a set of outcomes, is equal to
{𝐻𝑇𝑇, 𝑇𝐻𝑇, 𝑇𝑇𝐻}, and has probability 3/8.

x 0 1 2 3
P(X=x) 1/8 3/8 3/8 1/8
Example (3):
Example (4):
Example (5):
Example (6):
Example (7):
Example (8): Turbo Generators PLC manufactures seven large turbines for a customer. Three of these turbines do
not meet the customer’s specification. Quality control inspectors choose two turbines at random. Let the discrete
random variable 𝑋 be defined to be the number of turbines inspected which meet the customer’s specification.

a) Find the possible values of 𝑋.


b) Find the probabilities that 𝑋 takes the values 0, 1 or 2. Sample Space Value of X
c) Find and graph the probability density function and the Turbine faulty, Turbine faulty 0
cumulative distribution function. Turbine faulty, Turbine good
1
Turbine good, Turbine faulty
Turbine good, Turbine good 2
(a) The possible values of 𝑋 are clearly 0, 1 or 2

(b) The probabilities that 𝑋 takes the values 0, 1 or 2.


We can easily calculate the probability that 𝑋 takes the values 0, 1 or 2 as follows:
3 2 1
𝑃 𝑋=0 = ∗ = ,
7 6 7
4 3 3 4 4
𝑃 𝑋=1 = ∗ + ∗ = ,
7 6 7 6 7
4 3 2
𝑃 𝑋=2 = ∗ = .
7 6 7
3 2 1 1
𝑃 𝑋=0 = ∗ = , 𝐹 0 = ,
7 6 7 7
4 3 3 4 4 5
𝑃 𝑋=1 = ∗ + ∗ = , 𝐹 1 = ,
7 6 7 6 7 7
4 3 2 7
𝑃 𝑋=2 = ∗ = . 𝑎𝑛𝑑 𝐹 2 = = 1.
7 6 7 7

f(x) F(x)
Example (9): A discrete random variable 𝑋 has the following probability distribution:

X 1 2 3 4 5 6 7
𝑃(𝑋) 𝐶 2𝐶 2𝐶 3𝐶 𝐶2 2𝐶 2 2
7𝐶 + 𝐶

Find the value of C. Also find the mean of distribution

σ𝑛𝑖=1 𝑃 𝑋𝑖 = 1=𝑐 + 2𝑐 + 2𝑐 + 3𝑐 + 𝑐 2 + 2𝑐 2 + 7𝑐 2 + 𝑐
10𝑐 2 + 9𝑐 − 1 = 10𝑐 − 1 𝑐 + 1 = 0
𝑐 = 0.1 𝑐 = −1 𝑟𝑒𝑗𝑒𝑐𝑡𝑒𝑑

𝐸 𝑋 = 𝜇 = ෍ 𝑋𝑖 𝑃 𝑋𝑖
𝑖=1

= 1 ∗ 0.1 + 2 ∗ 0.2 + 3 ∗ 0.2 + 4 ∗ 0.3 + 5 ∗ 0.01 + 6 ∗ 0.02 + 7 ∗ 0.17 = 3.66 .

You might also like