Probability

Bijay Lal Pradhan

Probability

  • A quantitative measure of uncertainty

  • A measure of the strength of belief in the occurrence of an uncertain event

  • A measure of the degree of chance or likelihood of occurrence of an uncertain event

  • Measured by a number between 0 and 1 (or between 0% and 100%)

Types of Probability


Objective Probability: Mathematical Probability

  • based on equally-likely events

  • not based on personal beliefs

  • is the same for all observers (objective)

  • examples: toss a coin, roll a die, pick a card

Types of Probability


Objective Probability: Statistical Probability

  • based on long-run relative frequency of events

  • Not based on personal beliefs

  • is the equivalent for all observers

  • examples: success rate of operation, pass in examination

Types of Probability


Subjective Probability

  • based on personal beliefs, experiences, prejudices, intuition - personal judgment

  • different for respective observers (subjective)

  • examples: elections prediction, new product success, snowfall chance

Rolling a die

Occurrence of two event at the same time is not possible

Event Odd number (A) and Prime number (B) in rolling a dice ??

Event Odd number (C) and even number (D) in rolling a dice ??

Drawing a card

Drawing a number from 1 to 30

A Number is drawn and the Event is defined as

Multiple of 3 [M3]= {3,6,9,12,15,18,21,24,27,30}

Multiple of 5 [M5]= {5,10,15,20,25,30}

Multiple of 7 [M7]= {7,14,21,28}

Are M3 and M5 Mutually Exclusive?

Are M3 and M7 Mutually Exclusive?

Are M5 and M7 Mutually Exclusive?

Types of Probability


Mathematical Probability \[ P(Event) = \frac{Number\ of\ favorable\ outcomes}{Number\ of\ all\ possible\ outcomes} \]

Probability of an event is defined as the ratio of the number of favorable outcomes to the number of all possible outcomes, if all the exhaustive events are mutually exclusive and equally likely.

Mathematical Probability


For example, if you have an urn with 3 red, 2 blue, and 1 green ball, and you want to find the probability of drawing a red ball, the probability of drawing a red ball is given by:

\[ P(Red) = \frac{3}{3+2+1} = \frac{3}{6} = 0.5 \] The probability of drawing a red ball is 0.5, or 50%.

Combinations

Combinations are a selection of items without regard to the order of selection.

  • The number of combinations of \(n\) items taken \(r\) at a time is given by:

\[ ^nC_r = \frac{n!}{r!(n-r)!} \]

where \(n\) is the total number of items, \(r\) is the number of items to choose, and \(!\) denotes factorial.

Example Combination

Suppose you have a set of 5 distinct numbers, and you want to choose 3 of them.

The number of combinations can be calculated as:

\[ ^5C_3 = \frac{5!}{3!(5-3)!} = 10 \] Where 5\(!\) mean 5x4x3x2x1

and also 5\(!\) = 5x4\(!\)

R code

To calculate combinations in R, you can use the combn() function.

# define the set of numbers
numbers <- 1:5

# calculate the combinations
comb <- combn(numbers, 3)

# display the combinations
comb
     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10]
[1,]    1    1    1    1    1    1    2    2    2     3
[2,]    2    2    2    3    3    4    3    3    4     4
[3,]    3    4    5    4    5    5    4    5    5     5

Here total number of combinations is 10.

Some Problems

  1. In tossing two coins, what is the probability of getting (a) both heads (b) both tails (c) one head and one tail?
  2. In tossing a coin three times, find the probability of getting (a) All heads (b) All tails (no head) (c) Two heads and one tail (d) At least one head (e) At most one head.
  3. When a fair die is thrown, calculate the probability of getting (i) 6 (ii) not 6 (iii) less than 5 (iv) more than 4 (v) even number (vi) odd number.

Problems

  1. When two uniform dice are thrown together, what is the probability of getting (a) sum 8 (b) sum more than 9 (c) sum less than 6 (d) sum between 5 and 9 (e) more than 12 (f) sum either 5 or 10 (g) sum neither 4 nor 8 (h) equal number on both dice.
  2. A card is drawn from a well shuffled pack of playing cards. Find the probability of drawing (i) an ace (ii) a red card (iii) a face card (iv) a king or red card (v) an ace of spade
  3. A ball is selected from a bag containing 8 red balls and 12 green balls. What is the probability that it is (a) red (b) green?

Problems

  1. Twenty tickets are numbered from 1 to 20. A ticket is selected randomly. What is the probability that it is of (a) even number (b) odd number (c) prime number (d) square number (e) multiple of 5 (f) multiple of 3 (g) multiple of 3 and 5 (h) multiple of 3 or 5?

  2. In a class of MPhil, there are 20 boys and 30 girls. Two students have to be selected as class representative. What is the probability that (a) both are boys (b) both are girls (c) one boy and one girl?

  3.  Two persons are to be selected out of 4 accountants, 5 statisticians and 6 mathematicians for the board of committee. What is the probability of selecting (a) both accountants (b) one accountant and one statistician (c) one accountant (d) no accountant (e) at least one accountant (f) at most one accountant?

Types of Probability


Statistical Probability

If an experiment is conducted repeatedly under essentially homogeneous and identical conditions, then the statistical probability of an event happening can be defined as the limiting value of the ratio of the number of times that the event occurs to the total number of trials, as the number of trials approaches infinity.

\[ P(A) = \lim_{n\to\infty} \frac{Number\ of\ times\ event\ A\ occurs}{Total\ number\ of\ trials\ (n)} \]

Some Problems

A consumer agency surveyed all 2500 families living in a small town to collect data on the number of television sets owned by them. The following table lists the frequency distribution of the data collected by this agency.

Nos of TV set Owned 0 1 2 3 4
Nos of families 120 970 730 410 270

Find the probability that the number of sets owned by a randomly selected family from this town is (a) exactly one, (b) more than 2, (c) less or equal to 2, (d) 1 or more.

Conditional Probability

Conditional probability is a concept in probability theory that deals with the likelihood of an event occurring given that another event has already occurred.

Formally, if we have two events, (A) and (B), the conditional probability of (A) given (B) is denoted as (P(A|B)), and it is defined as the probability of event (A) occurring, given that event (B) has already occurred.

\[ P(A|B) = \frac{P(A \cap B)}{P(B)} \]

Where: - \(P(A \cap B)\) represents the probability of both events (A) and (B) occurring simultaneously (i.e., the intersection of (A) and (B)). - (P(B)) represents the probability of event (B) occurring.

Conditional Probability

In words, the conditional probability (P(A|B)) can be interpreted as the proportion of times event (A) occurs among the occurrences of event (B), given that event (B) has occurred.

Example

The following table shows the survey results regarding the employment status and gender in a sample of 209 management graduates of Tribhuvan University.

Gender Currently Employed Not Employed
Male 83 28
Female 64 34

What is the probability that a graduate chosen is

a.  currently employed?

b.  a female and currently employed?

c.  a female or currently employed?

d.  Suppose the graduate chosen is a female, what then is the probability that she is currently employed?

Rules for Conditional Probability

  1. Product Rule: The probability of the intersection of two events (A) and (B) can be calculated using the product rule: \[ P(A \cap B) = P(A|B) \cdot P(B) = P(B|A) \cdot P(A) \]

Law of Total Proability

  1. Law of Total Probability: For a partition \(B_1, B_2, \ldots, B_n\) of the sample space (S), the law of total probability states that: \[ P(A) = \sum_{i=1}^{n} P(A|B_i) \cdot P(B_i) \] where \(P(A)\) is the probability of event \(A\), and \(P(B_i)\) are the probabilities of the partition elements \((B_i)\), and \(P(A|B_i)\) is the conditional probability of \((A)\) given \((B_i)\).

Baye’s Theorem

  1. Bayes’ Theorem: Bayes’ theorem provides a way to revise or update the probability of an event based on new evidence. It is stated as follows: \[ P(A|B) = \frac{{P(B|A) \cdot P(A)}}{{P(B)}} \] where (P(A|B)) is the posterior probability of (A) given (B), (P(B|A)) is the likelihood of (B) given (A), (P(A)) is the prior probability of (A), and (P(B)) is the marginal probability of (B).

Baye’s Theorem


Let’s take one example that 70% employee are highly competent. P(H)=0.7 When a project a project is given to highly competent employee, then its probability of complete it in time is 0.9 = P(C/H) = 0.9

When administered to a person who is not highly competent (NĦ), the respective probability of complete in time is 0.2 = P(C/Ħ) = 0.2

Example

\[ P(H)=0.7 \]

\[P(\bar{H})=0.3\]

\[P(C/H)=0.9\]

\[P(C/\bar{H})=0.2\]

\[ P(H|A) = \frac{{P(H) \cdot P(A|H)}}{{P(C \cap H) + P(C \cap \bar{H})}} \]

\[ \frac{{P(H) \cdot P(C|H)}}{{P(H) \cdot P(C|H) + P(\bar{H}) \cdot P(C|\bar{H})}} \]

\[ = \frac{{0.7 \times 0.9}}{{0.7 \times 0.9 + 0.3 \times 0.2}} = 0.913 \]

Tree Diagram

Bayes Theorem Extended

  • An economist believes that during periods of high economic growth , the Nepales Rupees (NRs) appreciates with probability 0.70; in periods of moderate economic growth, the NRs appreciates with probability 0.40; and during periods of low economic growth, the NRs  appreciates with probability 0.20.

  • During any period of time, the probability of high, moderate and low economic growth, mod are respectively 0.30, 0.5 and 0.2. 

  • Suppose the NRs has been appreciating during the present period.  What is the probability we are experiencing a period of high economic growth?

Solution

Partition:

H - High growth P(H) = 0.30

M - Moderate growth P(M) = 0.50

L - Low growth P(L) = 0.20

\(P(A/H)=0.7\)

\(P(A/M)=0.4\)

\(P(A/L)=0.2\)

\[ P(H|C) = \frac{{P(H) \cdot P(A|H)}}{{P(H) \cdot P(A|H) + P(M) \cdot P(C|M)+ P(L) \cdot P(C|L)}} \]

\[ = \frac{{0.7 \times 0.3}}{{0.7 \times 0.3 + 0.4 \times 0.5+0.2 \times 0.2}} = 0.913 \] \[ = \frac{{0.21}}{{0.21 + 0.20+0.04}} = 0.467 \]

Joint and Marginal probability

Marginal Probabilities and Joint Probabilities
High Medium Low Total
NRs Appreciates 0.21 0.2 0.04 0.45
NRs Depreciates 0.09 0.3 0.16 0.55
Total 0.30 0.5 0.2 1.00

Marginal Probabilities are the row totals and the column totals

Questions for Practice

  1. Two sets of candidates are competing for the position on the Board of Directors of a company. The probabilities that the first and second sets will win are 0.6 and 0.4 respectively. If the first set wins, the probability of introducing a new product is 0.9 and the corresponding probability if the second set win is 0.4. What is the probability that new product will be introduced.

Questions for Practice

  1. It is known from experience that in a certain industry 60% of all labor management disputes are over wages, 15% are over working conditions, and 25% are over fringe issues. Also 45% of the disputes over wages are resolved without strikes, 70% of the disputes over working conditions are resolved without strikes, and 40% of the disputes over fringe issues are resolved without strikes. What is the probability that if a labor-management disputes in this industry is resolved without a strike, it was over wages?

Questions for Practice

  1. The chances of X, Y, Z becoming manager of a certain company are 4:2:3. The probabilities that bonus scheme will be introduced if X, Y, Z becomes manager are 0.3, 0.5 and 0.8 respectively. If the bonus scheme has been introduced, what is the probability that X is appointed as the manager?

  2. One bag contains 5 white and 4 black balls. Another bag contains 7 white and 9 black balls. A ball is transferred from the first bag to the second bag and then a ball is drawn from the second bag. Find the probability that the ball is white.

Expected value and variance

The variable which is associated with results or outcomes along with its probability is called random variable (RV). It is also known as chance variable or stochastic variable and denoted by any capital letter like X, Y and Z. The expected value and variance of random variable can be calculated as:

  1. Expected value of random variable [E(X)] = ∑(X P)

  2. Variance of random variable [Var. (X)] = ∑X2P – (∑XP)2

Example

Which project will you select and why?
Project Sales in “000” Probability Cost in “000” Probability
1 12 0.2 6 0.3
2 15 0.3 12 0.2
3 20 0.6 8 0.4
4 28 0.4 15 0.1
5 30 0.5 20 0.7

Solution

Project Sales in 1000 Prob. Cost in 1000 Prob. Expected Sales Expected Cost Expected Profit

1

2

3

4

5

12

15

20

28

30

0.2

0.3

0.6

0.4

0.5

6

12

8

15

20

0.3

0.2

0.4

0.1

0.7

2.4

4.5

12

11.2

15

1.8

2.4

3.2

1.5

14

0.6

2.1

8.8

9.7

1

The maximum expected profit is 9.7, which is obtained from project 4. Hence we select project 4.

Question

A manufacturing company estimates the annual net profit on favorable condition is Rs. 30,00,000 from the production of a new product. If the condition is moderate, the annual profit will be Rs. 10,00,000 only but when the condition is unfavorable then it will generate a loss of Rs. 10,00,000 in a year. The firm assigns 0.15 probabilities for favorable condition and 0.25 probabilities for moderate condition.  What is the expected value of annual profit for the company?