Unit-2 Basic Probability-Complete Notes
Unit-2 Basic Probability-Complete Notes
Topics:
A result of an experiment is called an outcome. The sample space of an experiment is the set
of all possible outcomes. Three ways to represent a sample space are: to list the possible
outcomes, to create a tree diagram, or to create a Venn diagram. The uppercase letter S is used
to denote the sample space. For example, if you flip one fair coin, S = {H, T} where H = heads
and T = tails are the outcomes.
12. Complementary Events: Complementary events occur when there are just two
outcomes, and one event is exactly opposite to another event. For an event with
probability P(A), its compliment is P(𝐴̅).
P(A)+ P(𝐴̅)=1
In an examination, the event of success and the event of failure are
complementary events. P(Success)+P(Failure)=1.
13. Dependent Events: If the occurrence of one event influences or affects the
probability of another event then the two events are said to be dependent.
14. Impossible Event: The event that cannot happen is called an impossible event. For
example, in tossing a coin it is impossible to get both head and tail at an equal time.
Example 1: A football team plays 120 matches and wins 80 matches. What is the
probability of the team winning the next match?
Example 2:
Tom's teacher wrote each English alphabet on a different piece of paper and jumbled all those
in a box. He asked Tom to randomly pick a piece of paper. What is the probability of having
a vowel written on that piece of paper?
Example 3:
Sam takes two coins and flips them both at once. What is the probability of getting heads
on both the coins?
Example 4:
Mary had a jar containing 8 red balls, 5 blue balls, and 7 green balls. She called one of her
friends and asked them to pick a ball from the jar. What is the probability that the ball which
is picked is either a red or a blue ball?
Example 5:
What is the chance that a leap year selected at random will contain 53 Sundays?
Solution:
In a leap year (which consists of 366 days) there are 52 complete weeks and 2 days over.
The following are the Possible combinations for these two 'over' days:
Sunday and Monday, (ii) Monday and Tuesday, (iii) Tuesday and Wednesday (iv)
Wednesday and Thursday, (v) Thursday and Friday, (vi) Friday and Saturday and (vii)
In order that a leap year selected at random should contain 53 Sundays, one of the two
'over’ days must be Sunday. Since out of the above 7 possibilities, 2 such as (i) and (vii),
𝟐
Required Probability = .
𝟕
II. Independent Events:
The multiplication theorem on probability for dependent events can be extended for
the independent events.
If the events A and B are independent, then, P(B | A) = P(B). The multiplication theorem
reduces to
1. A bag contains 20 balls, 3 are colored red, 6 are colored green, 4 are colored blue, 2 are
colored white and 5 are colored yellow. One ball is selected at random. Find the probabilities
of the following events.
Addition Theorem
Statement of the addition theorem on probability:
If A and B are any two events of a random experiment and P is a probability function then the
probability of happening of at least one of the events is defined as
P(A∪B)=P(A)+P(B)−P(A∩B).
Note:(1) Two events A and B are independent events if the equation.
i.e. P(A∩B)=P(A)×P(B).
(2). If two events A and B are mutually exclusive, then A∩B is a null set. Then
i.e. P(A∪B)=P(A)+P(B).
(3). If A and B are two mutually exhaustive, then the probability of their union is 1.
i.e. P(AUB)=1.
Example 1: A card is drawn at random from a pack of 52 cards. Find the probability that the
drawn card is either club or a queen.
As, one of the queen is club, so, the events are not mutually exclusive.
=13/52+4/52−1/52
=16/52
=4/13
Example 2: If George and James, two students, have a probability of solving a problem
that is 1/2 and 1/3, respectively, then what is the likelihood that the problem will be
solved?
Solution:
Let’s say that A and B represent the odds that George and James will be able to solve the
problem, respectively.
If at least one of them is able to find a solution to the problem, then it can be considered
solved.
P(A∪B)=P(A)+P(B)−P(A∩B)
P(AUB) = 1/2 +.1/3 – 1/2 * 1/3 = 1/2 +1/3-1/6 = (3+2-1)/6 = 4/6 = 2/3
Example 3: Two dice are tossed once. Find the probability of getting an even number on first
dice or a total of 8.
Solution: An even number can be got on a die in 3 ways because any one of 2, 4, 6, can
come. The other die can have any number. This can happen in 6 ways.
{(2,6),(3,5),(4,4),(5,3),(6,2)}
∴ P (a total of 8) =
∴ Total Probability =
Example 4: What is the probability of drawing either a king or a queen in a
single draw from a well shuffled pack of 52 cards?
Example 5: A number is chosen from the first 100 natural numbers. Find the probability that it
is a number of 4 or 6.
Solution: Given that one number is selected from the first 100 natural numbers, n(S) = 100,
⇒ n(A) = 25;
⇒ n(B) = 16;
⇒ n(A ⋂ B) = 8;
Example 6: Two dice are rolled together. Find the probability of getting a
doublet or sum of faces as 4.
Solution: When two dice are rolled together, there will be 6×6 = 36 outcomes.
Let A be the event of getting a doublet and B be the event of getting face sum 4.
Then A = {(1,1),(2,2),(3,3),(4,4),(5,5),(6,6)}
B = {(1,3),(2,2),(3,1)}
Therefore, A Ո B = {(2,2)}
P (A U B) = P (A) + P (B ) − P (A ∩ B)
Solution: Let A and B denote the events that the first and the second balls are drawn are red
balls.
Now, only 19 red balls and 10 blue balls are left in the bag.
The probability of drawing a red ball in the second draw too is an example of conditional
probability where the drawing of the second ball depends on the drawing of the first ball.
P(B|A) = 19/29
By multiplication rule of probability,
P(A∩B) = P(A) × P(B|A)
Example 2: 15 black and 10 white balls are contained in a box. After each other, two balls
are taken out of the box, and they are not changed in between games. What is the
probability that the two drawn balls will both be white?
Solution: Let P and Q represent the first and second draws, respectively, in which a white
ball is drawn from the box without replacement.
P(Q│P)=9/24
Now that we have used the multiplication rule, we can say that
P(Q|P)=9/24×9/24=3/20
Example 3: What is the probability of getting a 5 and then a 2 with the normal 6-sided dice?
Solution:
Total events = 6
so if the events A and B are independent, then, P(B | A) = P(B), and thus, the above
theorem reduces to P(A ∩ B) = P(A) P(B)
Therefore, the probability of getting a 5 and then a 2 with the normal 6-sided die is 1/36.
Example 4: Two cards are selected without replacing the first card from the deck. Find
the probability of selecting a king and then selecting a queen.
Solution:
Total events = 52
Since the first card is not replaced, the events are dependent.
Probability of getting a queen = P(Q|K) = 4/51 (one card drawn first has not been replaced)
Therefore, the probability of selecting a king and then selecting a queen is 1/166.
Bayes Theorem
Bayes’ Theorem is used to determine the conditional probability of an event. It was named after an
English statistician, Thomas Bayes who discovered this formula in 1763.
➢ It is used to find the probability of an event, based on prior knowledge of conditions that might
be related to that event.
➢ For example, if we want to find the probability that a white marble drawn at random came
from the first bag, given that a white marble has already been drawn, and there are three bags
each containing some white and black marbles, then we can use Bayes’ Theorem.
➢ Def-1: Conditional probability: The probability of an event (A), given that another (B) has
already occurred.
➢ Def-2: Conditional probability is known as the possibility of an event or outcome happening,
based on the existence of a previous event or outcome. It is calculated by multiplying the
probability of the preceding event by the renewed probability of the succeeding, or conditional,
event.
➢
➢ Bayes theorem, in simple words, determines the conditional probability of event A given that
event B has already occurred based on the following:
• Probability of B given A
• Probability of A
• Probability of B
If A and B are two events, then the formula for the Bayes theorem is given by:
Where:
Note:
(1). The theorem has become a useful element in the implementation of machine learning.
(2). The events A and B are independent events (i.e., the probability of the outcome of an
event (A) does not depend on the probability of the outcome of the event (B)).
Example 1: A Bag-I contains 4 white and 6 black balls while another Bag-II contains 4
white and 3 black balls. One ball is drawn at random from one of the bags, and it is found to
be black. Find the probability that it was drawn from Bag I.
Solution:
Example 2: A man is known to speak the truth 2 out of 3 times. He throws a dice and reports
that the number obtained is a four. Find the probability that the number obtained is actually a
four.
Solution:
Example 3: In a bolt factory machines A, B and C manufacture respectively 25%, 35% and
40% of the total. Of their output 5,4, 2 percent are defective bolts. A bolt is drawn at random
from the product and is found to be defective. What are the probabilities that it was
manufactured by machines A, B and C?
One urn is chosen at random and two balls drawn. They happen to be white and red. What is
the probability that they come from urns I, II or III ?
Example 5: Suppose 15 men out of 300 men and 25 women out of 1000 are good
researchers. A researcher is chosen at random. Find the probability that a male person
is selected. Assume that there are equal numbers of men and women.
Solution:
Let E1 and E2 be the events of choosing a man and a woman respectively. Then,
P(A|E1) × P(E1)
P(E1/A) =
P(A|E1) × P(E1) + P(A|E2) × P(E2)
= 2/3
Practice Problems:
1. A bag contains 5 red and 5 black balls. A ball is drawn at random, its colour is noted, and again
the ball is returned to the bag. Also, 2 additional balls of the colour drawn are put in the bag.
After that, the ball is drawn at random from the bag. What is the probability that the second ball
drawn from the bag is red?
2. Of the students in the college, 60% of the students reside in the hostel and 40% of the students
are day scholars. Previous year results report that 30% of all students who stay in the hostel
scored A Grade and 20% of day scholars scored A grade. At the end of the year, one student is
chosen at random and found that he/she has an A grade. What is the probability that the student
is a hosteler?
3. From the pack of 52 cards, one card is lost. From the remaining cards of a pack, two cards are
drawn and both are found to be diamond cards. What is the probability that the lost card is a
diamond?
Random Variables(RV)
Defn-1: A random variable is a variable whose value is unknown or a function that assigns
values to each of an experiment's outcomes. A random variable can be either discrete (having
specific values) or continuous (any value in a continuous range).
Example-1: If E consists of three tosses of a coin, we may consider random variable X which
denotes the number of heads(H) (0, 1, 2 or 3).
Example-2: Suppose 2 dice are rolled and the random variable, X, is used to represent
the sum of the numbers. Then, the smallest value of X will be equal to 2 (1 + 1), while
the highest value would be 12 (6 + 6). Thus, X could take on any value between 2 to
12 (inclusive).
As data can be of two types, discrete and continuous hence, there can be two types of
random variables. A discrete random variable can take on an exact value while the
value of a continuous random variable will fall between some particular interval.
Discrete Random Variable:
A random variable that can take on a finite number of distinct values is known as
a Discrete Random variable.
In other words, a real-valued function defined on a discrete sample space is called a
discrete random variable.
In the case of discrete random variables, we usually talk of values at a point. Generally,
it represents counted data.
For example, marks scored by students in a class for a particular subject can be represented
using a discrete random variable.
Basic Concept: Integer or rational numbers are discrete, while real numbers are
continuous.
Example-1
Suppose a fair coin is tossed twice and the sample space is recorded as
S = [HH, HT, TH, TT].
The probability of getting heads needs to be determined.
It can be seen that the random variable, X, represents the number of heads in the coin tosses.
This shows that X can take the values 0 (no heads), 1 (1 head), and 2 (2 heads).
The probabilities of each outcome can be calculated by dividing the number of favorable
outcomes by the total number of outcomes.
This gives us the following probabilities.
P(X = 0) = 1 / 4 = 0.25
P(X = 1) = 2 / 4 = 0.5
P(X = 2) = 1 / 4 = 0.25
The probability density function of a continuous random variable can be defined as a function
that gives the probability that the value of the random variable will fall between a range of
values.
Example-1:
Suppose the probability density function of a continuous random variable, X, is given by 4x3,
where x ∈ [0, 1].
The probability that X takes on a value between 1/2 and 1 needs to be determined. This can
be done by integrating 4x3 between 1/2 and 1.
Thus, the required probability is 15/16.
The mean and variance of a continuous random variable can be determined with the help of
the probability density function, f(x).
Example:2
Some Properties of Expectation
Moment Generating Function
Example 2: Let X be a discrete random variable with a probability mass function
𝑃𝑋 (𝑥) represented as:
Note: 𝑅𝑋 = {0,1}.
Example 3: Let X be a random variable with moment generating function
Characteristic Function
1. There are random variables for which the moment generating function does not
exist on any real interval with positive length.
2. Therefore, the moment generating function does not exist for this random variable
on any real interval with positive length. If a random variable does not have a
well-defined MGF, we can use the characteristic function (c.f.) defined as
Example 1:
Use the characteristic function found in the previous exercise to derive the variance of X.
Solution:
Cummulant Generating Function
𝑑𝑛 𝐾(𝑡)
𝑘𝑛 = 𝑎𝑡 𝑡 = 0.
𝑑𝑡 𝑛
The relationship between the moments and cumulants are represented as:
@End of Unit – 2@
Prepared by:
Dr. Amlan Kanti Halder
Assistant Prof. of Mathematics
School of Technology
Woxsen University, Hyderabad, Telangana, India
**************************************************************************