Skip to content

Discrete Probability ​

Ω - Set of all outcomes (Ω = 1)

A - Event A (A∈A)

P:A↦[0,1] - Probability function

The triple (Ω,A,P) is a probability field if:

  • The sample set Ω is a non-empty set.
  • A⊆P(Ω) (where P(Ω) is the power set of Ω) is the set of events (or σ-algebra of events), meaning:
    • (i) Ω∈A
    • (ii) If A1,A2,…∈A, then ⋃n=1∞An∈A (closed under countable unions)
    • (iii) If A∈A, then Ω∖A∈A (closed under complements)
  • The probability P:A→[0,1] is a function such that:
    • (i) P(Ω)=1 (the probability of the entire sample space is 1)
    • (ii) If A1,A2,…∈A are pairwise disjoint (i.e., Ai∩Aj=∅ for all 1≤i<j), then
P(⋃n=1∞An)=∑n=1∞P(An)

This means the probability of the union of countably many pairwise disjoint sets is the sum of their individual probabilities.

Simple probability formula ​

When we have finitely many possible outcomes and we may assume that they are equiprobable, probability is calculated as follows:

p=number of favorable outcomestotal number of possible outcomes

Independence (intersection of two independent events) ​

Events A,B∈A are independent if:

P(A∩B)=P(A)⋅P(B)

The events A1,A2,…,An∈A are independent if for every k≥1 and 1≤i1<i2<…<ik≤n we have:

P(Ai1∩Ai2∩…∩Aik)=P(Ai1)P(Ai2)…P(Aik)

Conditional Probability ​

For A,B∈A with P(B)>0

Given that B occurs, what is the probability that A also occurs?

P(A∣B)=probability of the intersectionprobability of condition=P(A∩B)P(B)

If A and B are independent:

P(A∣B)=P(A∩B)P(B)=P(A)P(B)P(B)=P(A)

Law of Total Probability ​

For an event A∈A and a partition B1,B2,…,Bn of the sample space, we have:

P(A)=P(A∣B1)P(B1)+…+P(A∣Bn)P(Bn)=∑j=1nP(A∣Bj)P(Bj).

Bayes' Theorem ​

For an event A∈A with P(A)>0 and a partition B1,B2,…,Bn:

P(Bk∣A)=P(A∣Bk)P(Bk)P(A∣B1)P(B1)+⋯+P(A∣Bn)P(Bn)=P(A∣Bk)P(Bk)∑j=1nP(A∣Bj)P(Bj).

Inclusion-Exclusion Formula ​

For n events A1,A2,…,An:

P(⋃i=1nAi)=∑k=1n(−1)k+1∑1≤i1<i2<…<ik≤nP(Ai1∩Ai2∩…∩Aik)

Example for two events (n=2): Probability that at least A or B occurs:

P(A∪B)=P(A)+P(B)−P(A∩B)

Example for three events (n=3): Probability that at least A, B or C occurs:

P(A∪B∪C)=P(A)+P(B)+P(C)−P(A∩B)−P(A∩C)−P(B∩C)+P(A∩B∩C)

Example 1 ​

Problem

In a country the number plates are labelled by five digit numbers from 00000 to 99999. We randomly pick one number plate. What is the probability of the event that

a) there's a six among digits on the plate?

b) the digits on the plate are different?

Solution

a) p=1−95105=0.41, as only those plates are bad that do not contain the digit 6.

b) p=10⋅9⋅8⋅7⋅6105=0.3

Example 2 ​

Problem

At a soccer training session 20 players participate, two of them are Simon and Garfunkel. We divide the participants randomly into two groups of 10 persons. What is the probability that Simon and Garfunkel play against each other?

Solution

Let us fix the team of Simon. There are 9 spaces left in it, while there are 19 spots left altogether. So for Garfunkel 10 out of the 19 choices result in being in a different team than Simon.

Example 3 ​

Peter fires at a target with his gun. The first shot has a 60% chance of hitting the target, the second one has 70%, and the last one has 80%. The shots are independent. What is the probability of the following events:

a) Peter not hitting the target?

b) Peter hits the target only at the third shot?

c) Does not hit that target at all, given that the first shot was a miss?

Solution

a) A, B, C: hitting the target for the first, second, third shot. Notice that if certain events are independent, then we get independent events if we replace any of the events with its complement.

P(A―∩B―∩C―)=P(A―)⋅P(B―)⋅P(C―)=0.4⋅0.3⋅0.2=0.024

b)

P(A―∩B―∩C)=P(A―)⋅P(B―)⋅P(C)=0.4⋅0.3⋅0.8=0.096

c)

P(A―∩B―∩C―∣A―)=P(A―∩B―∩C―)P(A―)=0.4⋅0.3⋅0.20.4=0.3⋅0.2=0.06

Example 4 ​

Problem

Odesseus arrives at a junction while wandering on the road. One leads to Athens, one to Sparta and one to Mycenae. The athenians tell the truth every third time when asked, the mycanaeans every second time, while the spartans never lie. Odesseus does not know which way leads to which city so he chooses randomly. Arriving in the city he asks a person the question: How much is 2 × 2. The answer is 4. What is the probability that he is in Athens?

Solution

T : the answer is true; A: Athens; M : Mycenae. S: Sparta

By using Bayes's theorem for the partition A.M.S and the event T we obtain that

P(A∣T)=P(A∩T)P(T)=P(A)⋅P(T∣A)P(T)=13⋅1313⋅13+13⋅12+13⋅1=0.182

Example 5 ​

Problem

There is a disease which affects 2% of the population. There is a blood test which is positive with probability 95% for people who have the disease, and it is positive with probability 1% for healthy people.

a) What is the probability that Peter's test will be positive? (Peter is a randomly chosen person.)

b) Given that the test of Peter is positive, what is the conditional probability that he has the disease?

c) Now suppose that the test was repeated k times independently for a randomly chosen person, and all results were positive. What is the conditional probability that this person has the disease? Calculate this probability for k=2 and k=3

Solution

a) Let A be the event that the test is positive, and B be the event that Peter has the disease. Then B and its complement B― is a partition of the sample space, such that both probabilities are positive. By the law of total probability we obtain

P(A)=P(A∩B)+P(A∩B―)=P(A|B)P(B)+P(A|B―)P(B―)==0.95⋅0.02+0.01⋅0.98=0.028.

Remark: If we repeat the test k times:

P(A)=P(A|B)P(B)+P(A|B―)P(B―)=0.95k⋅0.02+0.01k⋅0.98.

The values: 2.8% for k=1, 1.8% for k=2, and 1.7% for k=3.

b) We apply Bayes' theorem with the above notation. The probability of A is also positive. Hence

P(B|A)=P(A|B)P(B)P(A|B)P(B)+P(A|B―)P(B―)=0.95⋅0.020.95⋅0.02+0.01⋅0.98=66%.

c) Similarly, by using independence of the tests:

P(B|A)=P(A|B)P(B)P(A|B)P(B)+P(A|B―)P(B―)=0.95k⋅0.020.95k⋅0.02+0.01k⋅0.98.

For k=1, we have 66%, for k=2 we have 99.5%, for k=3 we have 99.99%.

Example 6 ​

Problem

(Monty Hall problem) In a television show there are 3 doors, such that there is a present behind one of them, and there is nothing behind the other two. The participant of the game chooses one of the doors. Then, the presenter opens one of the other doors, and shows that there is nothing behind it. Then he asks the participant whether he would like to stay with his original choice, or he would like to chose the other door which has not been opened yet. Is it worth changing?

https://randomservices.org/random/apps/MontyHall.html

Solution

It is worth changing.

First strategy: the player does not change his initial choice. He wins if and only if he has chosen the door with the present in the beginning. which has probability 1/3. Second strategy: the player changes his initial choice. Notice that if he had chosen an empty door in the beginning, then he would win for sure: among the two other doors, the empty was chosen. and he has chosen the other one. In the other case, if he had chosen the door with the present in the beginning, then he will find an empty door after changing.

Let A be the event that the player wins, and B be the event that he had chosen the door with the present in the beginning. Then {B.B―} is a partition of the sample space, with both events having positive probability. We apply the law of total probability:

P(A)=P(A|B)P(B)+P(A|B―)P(B―)=0·13+1·23=23.

23>13, therefore it is worth changing the door.