Unit 8 Probability
Unit 8 Probability
Example 1.4. More generally, if Ω is any finite set and all the elementary events have the
1
same probability |Ω| , then (Ω, p) is called the uniform probability distribution.
Example 1.5 (Shuffling a deck of 52 cards). The sample space is Ω = S52 with the uniform
probability distribution.
Example 1.6 (Random graph). Let Gn denote the probability space where Ω is the set
of graphs with vertex set [n] with the uniform probability distribution (so each graph has
probability 1n ).
2( 2 )
Lemma 1.7 (Union bound). P[A ∪ B] ≤ P[A] + P[B] for any two events A, B.
Proof. Inclusion-exclusion. □
The reason the union bound is very useful is that it makes no assumptions on A and B,
for example, independence.
Proposition 1.8. A random graph almost surely is not bipartite. Precisely, let Bn denote
the event that a random graph G in Gn is bipartite. Then,
lim P[Bn ] → 0.
n→∞
1
2 MATH 180 - GRAPH THEORY LECTURE 22 – DISCRETE PROBABILITY
Proof. For U ⊆ [n], let BU denote the event that all the edges of G go between U and [n] \ U .
If |U | = k, then
n
P[BU ] = 2k(n−k)−( 2 ) .
2
Using k(n − k) ≤ n4 , we have
n(n−2)
P[BU ] ≤ 2− 4 .
If B is the event that G is bipartite, then B = ∪U BU , so using the union bound, we get
X n(n−2) n(n−6)
P[B] ≤ P[BU ] ≤ 2n · 2− 4 = 2− 4 → 0
U
as n → ∞.
□
We say that A, B are independent if P[A ∩ B] = P[A]P[B]. More generally, A1 , . . . , Ak are
mutually independent if for every I ⊆ [k],
Y
P[∩i∈I Ai ] = P[Ai ].
i∈I
Note that this is stronger than requiring that any two events Ai and Aj are independent.
Example 1.9 (Erdős-Renyi random graph). Let G(n, p) denote the probability space where
[n]
Ω = {0, 1}( 2 ) is the set of simple graphs with vertex set [n] (more precisely, the set of edges)
with elementary probabilities
pG = p|E(G)| .
Equivalently, we look at each edge independently and include it with probability p and
exclude it with probability 1 − p.
MATH 180 - GRAPH THEORY
LECTURE 23 – LINEARITY OF EXPECTATION
1. Linearity of expectation
The following property of expectation is surprisingly powerful. Note that again we have
no assumptions on the random variables like independence.
Lemma 1.1 (Linearity of expectation). If X and Y are random variables and a, b ∈ R, then
E[aX + bY ] = aE[X] + bE[Y ].
Example 1.2 (Expected number of heads). Let s = s1 s2 . . . sn be a random sequence of 0s
and 1s of length n, where the si are uniform and independent. Let X denote the number of
1’s in s. Then,
n
n2n−1
1 X 1 X n n
E[X] = n X(s) = n k = n
= .
2 n
2 k=0 k 2 2
s∈{0,1}
Example 1.5 (Psychic guessing cards). The sample space if Ω = S52 × S52 with elementary
1
probabilities p(σ,π) = (52!)2 , where σ is the order of the cards and π is the order of the guesses.
An interesting random variable is the number of correct guesses, i.e., the function
52
1σi =πi .
X
X(σ, π) =
i=1
Example 1.6 (Random graph). Let G denote a random simple graph where each edge is
independently chosen with probability p and not chosen with probability 1 − p. What is the
expected number of edges in G?
1
2 MATH 180 - GRAPH THEORY LECTURE 23 – LINEARITY OF EXPECTATION
Example 1.7. Each of n hunters selects a rabbit at random from a group of n rabbits, aims
a gun at it, and then all the hunters shoot at once. Let X denote the number of rabbits that
survive. What is E[X]?
The probability space (Ω, P) is as follows:
(1) Ω is the set of functions f : [n] → [n]. The function tells us which rabbit each hunter
aims at.
(2) P is the uniform probability distribution assigning to each f the probability n1n .
Let Ei denote P the event that the ith rabbit survives. Then, the number of rabbits that
survive is X = ni=1 1Ei , so by linearity of expectation,
n n
(n − 1)n
X 1 n
E[X] = P[Ei ] = n n
=n 1− ∼ .
i=1
n n e
Therefore, the proportion of rabbits that survive is about 1e .
n!
If there did not exist any tournament with ≥ 2n−1 Hamiltonian paths, then the probability
would be 0. Therefore, there does exist such a tournament. □
The idea in the above proof is called the Probabilistic Method. We show that a combi-
natorial object with certain properties exists by showing that if we choose a random object
from an appropriate probability space of objects, there is a nonzero probability that we get
an object with the desired properties.
MATH 180 - GRAPH THEORY
LECTURE 24 – PROBABILISTIC METHOD
1. Ramsey numbers
Problem 1.1. Six people are waiting in the lobby of a hotel. Prove that there are three
people who all know each other or three of them who do not know each other.
Solution. We rephrase the problem in terms of graph theory. Consider K6 whose vertices
correspond to the 6 people. Color an edge {i, j} red if i and j know each other and blue if
they do not. Then we need to show that there is a monochromatic K3 no matter how the
edges are colored.
Consider the vertex 1. Since it has degree 5, it has 3 neighbors connected to it by edges
with the same color (by the pigeonhole principle). Without loss of generality, assume they
are 2, 3, 4 and the edges are red. If any of the edges {2, 3}, {2, 4}, {3, 4} are red, then we
have a red K3 . If not, 2, 3, 4 form a blue K3 . □
Definition 1.2. The Ramsey number R(k, l) is the minimum n such that any 2-edge-coloring
of Kn contains either a red Kk or a blue Kl .
In the problem, we showed that R(3, 3) ≤ 6. In fact, R(3, 3) = 6 since K5 has a 2-coloring
with no monochromatic triangles: draw K5 as a pentagon, color its sides red and diagonals
blue.
Very few Ramsey numbers are known since the number of colorings grows exponentially.
It is not too hard to show that R(4, 4) = 18 but R(k, k) is not known if k ≥ 5.
k
Theorem 1.3 (Erdős, 1947). R(k, k) > 2 2 −1 .
k
Proof. There are two steps. First, we use the Probabilistic Method to show that if nk 21−(2) <
1, then R(k, k) > n. Then we do asymptotic analysis.
R(k, k) > n is equivalent to saying that Kn has an 2-edge-coloring with no monochromatic
Kk . This is asking for the existence of a coloring which we will prove using the probabilistic
method. We will show that a random 2-coloring has a nonzero probability of containing no
monochromatic Kk .
We take the simplest random 2-coloring. Consider a uniformly random 2-edge-coloring
where each edge is independently colored red or blue with probability 21 . For any k-element
subset S of [n], let AS denote the event that all the edges between vertices in S are monochro-
matic. Then
1
P[AS ] = 2 · k .
2(2)
Let A = ∪S∈([n]) AS denote the even that at least one S gives rise to a monochromatic Kk .
k
Using the union bound,
X n 1
P[A] ≤ P[AS ] = 2 .
S
k 2(k2)
1
2 MATH 180 - GRAPH THEORY LECTURE 24 – PROBABILISTIC METHOD
The following simple observation is called the pigeonhole principle for expectation.
Lemma 0.1 (Pigeonhole principle for expectation). Suppose E[X] > a. Then P[X > a] > 0.
Proof. Suppose not, i.e., suppose that P[X > a] = 0. Then pω = 0 for every ω such that
X(ω) > a, so
X X
E[X] = pω X(ω) + pω X(ω) ≤ a,
ω:X(ω)≤a ω:X(ω)>a
contradiction. □
1. Tournaments
Definition 1.1. A tournament is an orientation of the edges of Kn . A Hamiltonian path in
a tournament T is a directed path that goes through all the vertices exactly once.
We think of each Hamiltonian path as the permutation given by the order in which the
vertices appear along the path.
n!
Theorem 1.2. There is a tournament T with at least 2n−1
Hamiltonian paths.
Proof. Let Ω = {tournaments} and let us choose a random tournament T by choosing
the orientation of each edge independently and uniformly. Let X denote the number of
Hamiltonian paths and let Aπ denote the event that a given permutation π is a Hamiltonian
path in T . By linearity of expectation,
X X 1 n!
E[X] = P[Aπ ] = n−1
= n−1 .
π∈S π∈S
2 2
n n
2. Coloring hypergraphs
Definition 2.1. A k-uniform hypergraph is a pair H = (V, E) where V is a set of vertices
and E ⊆ Vk is a set of (hyper)edges.
Remark 2.2. A 2-uniform hypergraph is the same thing as a graph.
Definition 2.3. A proper c-coloring of H is an assignment of one of c colors to the vertices
such that no edge is monochromatic.
Intuitively, if the hypergraph has a lot of edges, then it is going to be difficult to 2-color.
1
2 MATH 180 - GRAPH THEORY LECTURE 25 – PROBABILISTIC METHOD II
Definition 2.4. Let m(k) denote the fewest number of edges in a hypergraph that is not
2-colorable.
Example 2.5. m(2) = 3 since the smallest graph that is not bipartite is the triangle.
It is known that m(3) = 7 but no other value of m(k) is known.
Theorem 2.6. m(k) ≥ 2k−1 .
Proof. We need to show that any hypergraph with fewer than 2k−1 vertices is 2-colorable,
i.e., we need to show the existence of a 2-coloring. We will do this using the Probabilistic
Method.
Consider a random 2-coloring where each edge is colored red or blue independently with
probability 12 . For each edge e, let Ae denote the event that it is monochromatic (these
are bad events that we wish to avoid). Then P[Ae ] = 22k = 2k−1 1
. Therefore, if A =
{some edge is monochromatic} = ∪e Ae , then using the union bound,
X
P[A] ≤ P[Ae ] < 1.
e
Taking complements, the probability that no edge is monochromatic is nonzero. Therefore,
there exists such a coloring. □