0% found this document useful (0 votes)
13 views30 pages

Week 1: Learning Objectives: Introduction To Probability

Week 1 covers the fundamentals of probability, including definitions, approaches to calculating probability values, and the concepts of sample spaces and events. Key topics include understanding probability values, basic probability laws, and the distinction between different types of sample spaces. The week concludes with an overview of mutually exclusive events and the axioms of probability.

Uploaded by

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

Week 1: Learning Objectives: Introduction To Probability

Week 1 covers the fundamentals of probability, including definitions, approaches to calculating probability values, and the concepts of sample spaces and events. Key topics include understanding probability values, basic probability laws, and the distinction between different types of sample spaces. The week concludes with an overview of mutually exclusive events and the axioms of probability.

Uploaded by

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

Week 1: Learning Objectives

■ Introduction to Probability
■ At the end of Week 1 you should be
able to:
■ understand the concept of probability
■ differentiate between the various
approaches for calculating probability
values
■ work with sample spaces and events
■ understand the basic probability laws
■ apply these laws for solving simple 1
Introduction to Probability

■ What does a probability value really


represent?
■ chance? likelihood? odds? percentage?
proportion?
■ Interpreting probabilities can be
interesting:
■ “The chance of winning a Jackpot in a Lotto
game is?”
■ How can it be calculated? Where does the
number come from?
■ If the chance of rain for tomorrow is 30%,
does it mean it will not rain because it is 2
So, what is probability?

■ Typically, a value between 0 and 1 that


reflects the likelihood of the occurrence of
a specific event
■ Calculating probability values is harder
some times than others
■ e.g. probability of observing a specific volume
of network traffic in a given network connection
for a given time period vs. probability or rolling
a 3 with a die
■ Probability values can be calculated in a
variety of ways
3
Basic terms & definitions
■ It all comes down to:
■ understanding the event for which you want to
estimate the probability
■ calculating all the possible outcomes of the
process at hand
■ Think of the single die example:
■ experiment: throwing one die
■ event: e.g. throwing an odd number
■ all possible outcomes (sample space): {1, 2, 3, 4,
5, 6}
■ Now let’s define these concepts in a more
formal way
4
Basic terms: Experiment
■ A ‘probabilistic’ experiment is an activity
that we do not know what will happen for
sure but we ‘observe’ what happens
■ a random process
■ Some examples:
■ we toss one coin and observe whether it shows
heads or tails
■ we will observe the temperature at mid-day
tomorrow
■ we will ask someone whether or not they have
bought our product in the last 12 months

5
Outcomes: Sample Spaces
■ The list all the possible outcomes of
an experiment is called the Sample
Space
■ we will use the letter S for sample
spaces
■ any collection of items in probability is called a
set, and so S is also a set
■ If your experiment is rolling a single die:
S = {1, 2, 3, 4, 5, 6}
■ If your experiment is tossing a coin twice:
S = {HH, HT, TH, TT}
■ Note that an outcome is essentially one of
the possible things that can happen in the 6
Think…
■ What we perceive as random and what is
actually random are two separate things
■ Assume we flip a coin 10 times, which
of the following two sequences are we
more likely to observe?
■ H T H H T H T T HT
■ H T H T T T T T T H

7
Types of sample spaces
■ Finite
■ If you can write & count all elements in S. Example:
rolling a single die, S = {1, 2, 3, 4, 5, 6}
■ Countably infinite
■ There is a way to show the progression of the values
in S, but they can go to infinity
■ Example: the number of accesses to a web server
during a week’s time, S = {0, 1, 2, 3, 4, … }
■ Uncountably infinite
■ The possible outcomes are too numerous to write
down in a listing, so we use an interval to
describe them
■ Example: length of time it takes a computer to
complete a task, with a max of 5 sec. S = {all
real numbers x such that 0<x≤5}
8
Events: subsets of sample
spaces
■ An event is a set of outcomes and is a subset of
the sample space S
■ The empty set Ø is called the impossible event
■ The subset S is called the certain event
■ We measure the probability of an event: P(event)
■ probability of the temperature tomorrow mid-day being less than 20
degrees – the event is made up of all outcomes where the
temperature is less than 20 degrees – P(temp<20)
■ probability of observing a sum of 3 when rolling 2 dice – the event is
made up of all outcomes where the sum of the 2 dice is equal to 3 –
P(sum of 2 dice = 3)
■ probability of observing the number 4 when rolling one die – the
event is made up of only one outcome – P(rolling a 4)

9
Sample spaces and events
■ We roll a single die, S = {1, 2, 3, 4, 5, 6} :
■ Event A: that we roll an odd number: A = {1, 3, 5 }
■ Event B: that we roll a number greater than 2: B = {3,
4, 5, 6
}
■ We toss one coin 3 times. What is the sample
space S? Use H, T to show the two possible
outcomes
S = {HHH, HHT, HTH, HTT, THH, THT, TTH, TTT

10
The 4 approaches to
calculating probabilities
■ Subjective
■ The most vague and least scientific way,
based on personal views, hopes, etc.
■ What do you think the chance that your
favorite football team will win the
Premier League is?
■ What is the probability of a new
pandemic in 2023/24?
■ Classical
■ Mathematical approach, using rules and
formulas (more in the coming weeks)
■ Roll the dice!!! 11
The 4 approaches to
calculating probabilities
■ Frequency-based
■ Base calculations on observed data, and
calculate the percentage of times that the
event has occurred in the observed data
(relative frequency)
■ Probabilities are estimates, since they are
based on finite sample size (your estimates
will be only as good as the data you collect)
■ Simulation-based
■ We create the data by setting up a scenario,
playing out the scenario a large number of
times, and counting the percentage of times
a certain outcome occurs
12
Some first formulas
■ For the classical
approach:number of ways A can
P(A) =
numberoccur
of ways the experiment can
proceed
■ This only works if all outcomes are equally
likely
■ For thenumber
frequency-based
of times event A approach:
P(A) =
occurred
number of ways the experiment was
run
Can you translate this in English?
𝒏→∞

13
Think…
a) We roll a die:
■ What is the probability of getting a 2?

■ What is the probability of getting a 2

or a 6?
P(rolling a 2) = 1/6
P(rolling a 2 or a 6) = 1/6 + 1/6 = 2/6

b)How would I be able to calculate the


probability of any student passing a
module that I have been teaching for the
past 6 years?
Using the frequency-based approach, it would be a case of
counting occurrences of students who passed the module,
divided by the total number of students who took the14
15
For the next few slides…
■ You will need to remember some of the
basic set theory covered in Logic &
Discrete Structures:
■ Union of two events (sets): A u B (i.e. A or B)
■ Intersection of two events (sets): A n B (i.e.
A and B)
■ Complement of an event (set) A: A (or Ac)
(i.e. not A)
■ Example: Roll a single die
■ Event A: roll an odd number
■ Event B: roll a number larger than 2
■ Event C: roll an even number 16
Example continued
■ Sample space S = { 1, 2, 3, 4, 5,
6}
■ Turn events into sets
■ A = {1, 3, 5 }, B = {3, 4, 5, 6 }, C
= {2, 4, 6 }
■ A u B = {1, 3, 4, 5, 6 }
■ A u C = {1, 2, 3, 4, 5, 6 } =S
■ A n B = {3, 5 }
■ A n C = Ø
17
■ c
Useful: Venn Diagrams

18
Example
■ You have 2 interviews for 2 jobs. Event A: you get an
offer for job A, Event B: you get an offer for job B.
Consider P(A)=0.2, P(B)=0.6 and P(A∩B) = 0.15.
■ What is the probability that you get offered neither job?
■ What is the probability that you do not get two job offers?

Using the previous slide’s Venn diagram A∩B’=0.05,


A∩B=0.15, B∩A’=0.45, whole sample space 1:
-the probability that you get offered neither job: A’ ∩B’
= 0.35
-the probability that you do not get two job
offers: P(A∩B)’ =1- P(A∩B)=0.85
19
Mutually exclusive events
■ Two events A1 and A2 are
mutually exclusive if and only
if A1 n A2 = Ø
■ Events A1, A2, A3, … are mutually
exclusive if and only if Ai n Aj = Ø for
all i≠j
■ In plain words:
■ Two events are mutually exclusive if
they can’t occur at the same time
■ Three or more events are mutually 20
Mutually exclusive events
S
A1
A2
If you know A1 has
occurred, then you
know that A2 can not
A1 n A2 = occur, and vice versa
Ø
One special case of Complement events BY
DEFINITION have no intersection
mutually exclusive (i.e. no common elements, they
events is events that are the ‘opposite’ of each other)
and therefore they are mutually
are complements of exclusive events
each other - Why?
21
Some examples
■ You roll a die once. Let A be the event
that the die comes 2, B the event that
the die comes an even number and C
the event that the die comes an odd
number
■ A and B are not mut.excl. because A n B
={2}
■ A and C are mut.excl. because A n C =Ø
■ B and C are mut.excl. (B and C are
actually complements of each other)
22
Some probability laws
■ Kolmogorov’s axioms of probability
■ If S the sample space for an experiment,
then
P(S) = 1
■ For every event A, P(A)≥0
■ Let A1, A2, A3 … be a countable collection
of
mutually exclusive events. Then:
P(A1 u A2 u A 3 … ) = P(A1) + P(A2) + P(A3) +

■ These 3 axioms are building blocks on 23
Exercise
■ One study on the location of pages found on the Web,
showed that 35% of pages were hosted in the USA, 15% in
the UK, 25% in the rest of Europe and 25% in the rest of
the world. If we pick one page at random, what is the
probability that it will be from the UK or from the US?

We are given: P(USA)=0.35, P(UK)=0.15,


P(EUR)=0.25, P(REST_OF_WORLD)=0.25
We are asked to find P(UK u US). Because our
events are mutually exclusive, we apply the 3rd
axiom, and get that:
P(UK u US) = P(UK) + P(US) = 0.35 + 0.15 = 0.5

24
Some consequences of the
axioms
■ P(Ø) = 0
■ the probability assigned to the
impossible event is zero
■ P(A) = 1 - P(A)
■ the probability that an event will not
occur, is equal to 1 minus the
probability that the event will occur
■ For any event A, 0 ≤ P(A) ≤ 1
■ These can be proven based on the
axioms 25
The general addition rule
■ For any two events A1 and A2:
■ P(A1 u A2) = P(A1) + P(A2) - P(A1 n A2)
S
A1
A1 and A2 are now NOT
A2
mutually exclusive
events - WHY?
Contrast this rule with
A1 n A2
the 3rd of Kolmogorov’s
axioms
26
Example
■ Suppose you roll a die once, and consider the
events:
■ A: the die comes up an even number

■ B: the die comes up greater than 4

Find the probability that the die comes up an even


number OR greater than 4

A={2, 4, 6}, B={5, 6}


A and B are not mutually exclusive, A n B = {6}
We use the general addition rule to find the
probability of the union of the two events:
P(A u B) = P(A) + P(B) - P(A n B) = 3/6 + 2/6 -1/6
= 4/6

27
A quick note: Independent
events
■ Two events are called independent
if knowledge that one has
occurred does not affect the
probability of the other event
occurring
■ For now (in detail next week), we
will say that if P(A n B) = P(A)P(B)
then A and B are independent (and
vice-versa)
■ This is the multiplication rule
28
Some examples
■ Rolling a single die, S = {1, 2, 3,
4, 5, 6}
■ Event A: die comes up odd
■ Event B: die comes up 1
■ Event C: the die is 1 or 2
■ Are A and B independent?
■ Are A and C independent?

29
Summary of lecture
■ In Week 1 we covered:
■ Basic notion of probability
■ Approaches to calculating probability
values
■ Sample spaces and events
■ Basic probability laws
■ How to use these in solving problems
■ Don’t forget:
■ Work on the exercises for the tutorial
BEFORE you come to your class
30

You might also like