41
Introduction to Random Graphs [email protected]

Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

  • Upload
    others

  • View
    1

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Introduction to Random Graphs

[email protected]

Page 2: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

• World Wide Web• Internet• Social networks• Journal citations• ……

2

Statistical properties VS Exact answer to questions

Page 3: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

The 𝐺𝐺(𝑛𝑛,𝑝𝑝) model

Properties of almost all graphs

Phase transition3

Page 4: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

𝑮𝑮(𝑛𝑛,𝑝𝑝) Model

• 𝑮𝑮(𝑛𝑛, 𝑝𝑝) Model [Erd�̈�𝑜s and R�́�𝑒nyi1960]: V = 𝑛𝑛 is the number of vertices, and for

and different 𝑢𝑢, 𝑣𝑣 ∈ 𝑉𝑉, Pr 𝑢𝑢, 𝑣𝑣 ∈ 𝐸𝐸 = 𝑝𝑝.

4

• Example. If 𝑝𝑝 = 𝑑𝑑𝑛𝑛.

Then 𝑬𝑬 deg 𝑣𝑣 = 𝑑𝑑𝑛𝑛𝑛𝑛 − 1 ≈ 𝑑𝑑

𝑛𝑛 ≈ 𝑛𝑛 − 1

Page 5: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Example: 𝑮𝑮(𝑛𝑛, 1/2)

Pr 𝐾𝐾 = 𝑘𝑘 = 𝑛𝑛 − 1𝑘𝑘

12

𝑘𝑘 12

𝑛𝑛−𝑘𝑘

≈ 𝑛𝑛𝑘𝑘

12

𝑘𝑘 12

𝑛𝑛−𝑘𝑘= 1

2𝑛𝑛𝑛𝑛𝑘𝑘

5

𝐾𝐾 = deg(𝑣𝑣)

𝐸𝐸(𝐾𝐾) = 𝑛𝑛/2𝑉𝑉𝑉𝑉𝑉𝑉(𝐾𝐾) =𝑛𝑛/4

Independence!

Binomial Distribution

Page 6: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Recall: Central Limit TheoremNormal distribution (Gauss Distribution): 𝑋𝑋 ∼ 𝑁𝑁 𝜇𝜇,𝜎𝜎2 , with density function:

𝑓𝑓 𝑥𝑥 =12𝜋𝜋𝜎𝜎

𝑒𝑒−𝑥𝑥−𝜇𝜇 2

2𝜎𝜎2 , −∞ < 𝑥𝑥 < +∞

6

As long as {𝑋𝑋𝑖𝑖} is independent identically distributed with 𝐸𝐸 𝑋𝑋𝑖𝑖 = 𝜇𝜇, 𝐷𝐷 𝑋𝑋𝑖𝑖 = 𝜎𝜎2, then ∑𝑖𝑖=1𝑛𝑛 𝑋𝑋𝑖𝑖 can be approximated by normal distribution (𝑛𝑛𝜇𝜇,𝑛𝑛𝜎𝜎2)when 𝑛𝑛 is large enough.

Page 7: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

• 𝑮𝑮(𝑛𝑛, 1/2)

7

𝜇𝜇 = 𝑛𝑛𝜇𝜇𝑛 = 𝐸𝐸 𝐾𝐾 =𝑛𝑛2

,

𝜎𝜎2 = 𝑛𝑛(𝜎𝜎′)2 = 𝑉𝑉𝑉𝑉𝑉𝑉(𝐾𝐾) = 𝑛𝑛/4

(CLT) Near the mean, the binomial distribution is well approximated by the normal distribution.

1𝜎𝜎 2𝜋𝜋

𝑒𝑒−𝑘𝑘−𝑛𝑛𝜇𝜇 2

2𝜎𝜎2 =1𝜋𝜋𝑛𝑛/2

𝑒𝑒−𝑘𝑘−𝑛𝑛/2 2

𝑛𝑛/2

It works well when 𝑘𝑘 = Θ 𝑛𝑛 .

Page 8: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

8

• 𝑮𝑮(𝑛𝑛, 1/2): for any 𝜖𝜖 > 0, the degree of each vertex almost surely is within 1 ± 𝜖𝜖 𝑛𝑛

2.

Proof. As we can approximate the distribution by

1𝜋𝜋𝑛𝑛/2

𝑒𝑒−𝑘𝑘−𝑛𝑛/2 2

𝑛𝑛/2

𝜇𝜇 =𝑛𝑛2

,𝜎𝜎 =𝑛𝑛

2

𝜇𝜇 ± 𝑐𝑐𝜎𝜎 = 𝑛𝑛2

± 𝑐𝑐 𝑛𝑛2≈

1 ± 𝜖𝜖 𝑛𝑛2

Page 9: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

9

• 𝑮𝑮(𝑛𝑛, 𝑝𝑝): for any 𝜖𝜖 > 0, if 𝑝𝑝 is Ω ln 𝑛𝑛𝑛𝑛𝜖𝜖2

, then the degree of each vertex almost surely is within 1 ± 𝜖𝜖 𝑛𝑛𝑝𝑝.

Proof. Omitted

Page 10: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

𝑮𝑮(𝑛𝑛, 𝑝𝑝) Model: independent set and clique

Lemma. For all integers 𝑛𝑛, 𝑘𝑘 with 𝑛𝑛 ≥ 𝑘𝑘 ≥ 2;the probability that G ∈ 𝑮𝑮 𝑛𝑛, 𝑝𝑝 has a set of 𝑘𝑘independent vertices is at most

Pr 𝛼𝛼 𝐺𝐺 ≥ 𝑘𝑘 ≤ 𝑛𝑛𝑘𝑘 1 − 𝑝𝑝

𝑘𝑘2

the probability that G ∈ 𝑮𝑮 𝑛𝑛, 𝑝𝑝 has a set of 𝑘𝑘clique is at most

Pr 𝜔𝜔 𝐺𝐺 ≥ 𝑘𝑘 ≤ 𝑛𝑛𝑘𝑘 𝑝𝑝

𝑘𝑘2

10

Page 11: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Lemma. The expected number of 𝑘𝑘 −cycles in G ∈ 𝑮𝑮 𝑛𝑛, 𝑝𝑝 is 𝐸𝐸 𝑥𝑥 = 𝑛𝑛 𝑘𝑘

2𝑘𝑘𝑝𝑝𝑘𝑘.

11

Proof. The expectation of certain 𝑛𝑛 vertices 𝑣𝑣0, 𝑣𝑣1,⋯ , 𝑣𝑣𝑘𝑘−1, 𝑣𝑣0 form a length 𝑘𝑘 cycle is: 𝑝𝑝𝑘𝑘

The possible ways to choose 𝑘𝑘 vertices to form a cycle 𝐶𝐶 is 𝑛𝑛 𝑘𝑘

2𝑘𝑘.

The expectation of the number of all cycles:

𝑋𝑋 = �𝐶𝐶

𝑋𝑋𝐶𝐶 =𝑛𝑛 𝑘𝑘

2𝑘𝑘𝑝𝑝𝑘𝑘

Page 12: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

The 𝐺𝐺(𝑛𝑛,𝑝𝑝) model

Properties of almost all graphs

Phase transition12

Page 13: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Properties of almost all graphs

• For a graph property 𝑃𝑃 , when 𝑛𝑛 → ∞, If the limit of the probability of 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝)having the property tends to – 1: we say than the property holds for almost

all (almost every / almost surely) 𝐺𝐺 ∈ 𝑮𝑮 𝑛𝑛, 𝑝𝑝 .– 0: we say than the property holds for almost

no 𝐺𝐺 ∈ 𝑮𝑮 𝑛𝑛, 𝑝𝑝 .

13

Page 14: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Proposition. For every constant 𝑝𝑝 ∈ (0,1)and every graph 𝐻𝐻, almost every 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝)contains an induced copy of H.

14

𝐺𝐺

𝐻𝐻

Page 15: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Proposition. For every constant 𝑝𝑝 ∈ (0,1)and every graph 𝐻𝐻, almost every 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝)contains an induced copy of H.

15

Proof. 𝑉𝑉 𝐺𝐺 = 𝑣𝑣0, 𝑣𝑣1, … , 𝑣𝑣𝑛𝑛−1 ,𝑘𝑘 = |𝐻𝐻|

Fix some 𝑈𝑈 ∈ 𝑉𝑉(𝐺𝐺)𝑘𝑘 ,then Pr 𝑈𝑈 ≅ 𝐻𝐻 = 𝑉𝑉 > 0

𝑉𝑉 depends on 𝑝𝑝, 𝑘𝑘 not on 𝑛𝑛.There are 𝑛𝑛/𝑘𝑘 disjoint such 𝑈𝑈. The probability that none of the 𝐺𝐺[𝑈𝑈] is isomorphic to 𝐻𝐻 is: = 1 − 𝑉𝑉 𝑛𝑛/𝑘𝑘

↓0

𝑛𝑛 → ∞Pr[¬(𝐻𝐻 ⊆ 𝐺𝐺 induced)]: ≤ 1 − 𝑉𝑉 𝑛𝑛/𝑘𝑘

Page 16: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Proposition. For every constant 𝑝𝑝 ∈ (0,1)and 𝑖𝑖, 𝑗𝑗 ∈ 𝑁𝑁, almost every graph 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝)has the property 𝑃𝑃𝑖𝑖,𝑗𝑗.

16

𝐺𝐺

𝑈𝑈 ≤ 𝑖𝑖𝑊𝑊 ≤ 𝑗𝑗

𝑣𝑣

Page 17: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Proposition. For every constant 𝑝𝑝 ∈ (0,1)and 𝑖𝑖, 𝑗𝑗 ∈ 𝑁𝑁, almost every graph 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝)has the property 𝑃𝑃𝑖𝑖,𝑗𝑗.

17

Proof. Fix 𝑈𝑈,𝑊𝑊 and 𝑣𝑣 ∈ 𝐺𝐺 − 𝑈𝑈 ∪𝑊𝑊 , 𝑞𝑞 = 1 − 𝑝𝑝,

The probability that 𝑃𝑃𝑖𝑖,𝑗𝑗 holds for 𝑣𝑣: 𝑝𝑝 𝑈𝑈 𝑞𝑞|𝑊𝑊| ≥ 𝑝𝑝𝑖𝑖𝑞𝑞𝑗𝑗

The probability there’s no such 𝑣𝑣 for chosen 𝑈𝑈,𝑊𝑊:

= 1 − 𝑝𝑝 𝑈𝑈 𝑞𝑞 𝑊𝑊 𝑛𝑛− 𝑈𝑈 −|𝑊𝑊|≤ 1 − 𝑝𝑝𝑖𝑖𝑞𝑞𝑗𝑗 𝑛𝑛−𝑖𝑖−𝑗𝑗

The upper bound for the number of different choice of 𝑈𝑈,𝑊𝑊: 𝑛𝑛𝑖𝑖+𝑗𝑗

The probability there exists some 𝑈𝑈,𝑊𝑊 without suitable 𝑣𝑣:

≤ 𝑛𝑛𝑖𝑖+𝑗𝑗 1 − 𝑝𝑝𝑖𝑖𝑞𝑞𝑗𝑗 𝑛𝑛−𝑖𝑖−𝑗𝑗 𝑛𝑛→∞0

Page 18: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Colouring• Vertex coloring: to 𝐺𝐺 = (𝑉𝑉,𝐸𝐸), a vertex

coloring is a map 𝑐𝑐:𝑉𝑉 → 𝑆𝑆 such that 𝑐𝑐 𝑣𝑣 ≠𝑐𝑐(𝑤𝑤) whenever 𝑣𝑣 and 𝑤𝑤 are adjacent.

• Chromatic number 𝝌𝝌(𝑮𝑮): the smallest size of 𝑆𝑆.

18

𝜒𝜒 𝐺𝐺 = 3

Page 19: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Colouring

19

• Some famous results:– Whether 𝜒𝜒 𝐺𝐺 = 𝑘𝑘 is NP-complete.– Every Planar graph is 4-colourable.– [Grt�̈�𝑜zsch 1959]Every Planar graph not

containing a triangle is 3-colourable.

• Vertex coloring: to 𝐺𝐺 = (𝑉𝑉,𝐸𝐸), a vertex coloring is a map 𝑐𝑐:𝑉𝑉 → 𝑆𝑆 such that 𝑐𝑐 𝑣𝑣 ≠𝑐𝑐(𝑤𝑤) whenever 𝑣𝑣 and 𝑤𝑤 are adjacent.

• Chromatic number 𝝌𝝌(𝑮𝑮): the smallest size of 𝑆𝑆.

Page 20: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Proposition. For every constant 𝑝𝑝 ∈ (0,1) and every 𝜖𝜖 > 0, almost every graph 𝐺𝐺 ∈ 𝑮𝑮(𝑛𝑛, 𝑝𝑝) has chromatic number 𝜒𝜒 𝐺𝐺 > log(1/𝑞𝑞)

2+𝜖𝜖⋅ 𝑛𝑛𝑙𝑙𝑙𝑙𝑙𝑙𝑛𝑛

20

Proof.Pr 𝛼𝛼 𝐺𝐺 ≥ 𝑘𝑘 ≤

𝑛𝑛𝑘𝑘𝑞𝑞

𝑘𝑘2 ≤ 𝑛𝑛𝑘𝑘𝑞𝑞

𝑘𝑘2

= 𝑞𝑞𝑘𝑘log 𝑛𝑛log 𝑞𝑞+

12𝑘𝑘(𝑘𝑘−1) = 𝑞𝑞

𝑘𝑘2 − 2log 𝑛𝑛

log(1/𝑞𝑞)+𝑘𝑘−1

Take 𝑘𝑘 = 2 + 𝜖𝜖 log 𝑛𝑛log(1/𝑞𝑞)

then (*) tends to ∞ with 𝑛𝑛.

The size of the maximum independent set in 𝐺𝐺:𝛼𝛼(𝐺𝐺)

∴ Pr 𝛼𝛼 𝐺𝐺 ≥ 𝑘𝑘𝑛𝑛→∞

0 ⇒

∴ 𝜒𝜒 𝐺𝐺 >𝑛𝑛𝑘𝑘

=log 1/𝑞𝑞

2 + 𝜖𝜖⋅𝑛𝑛

log𝑛𝑛

(*)

No 𝑘𝑘 vertices can have the same colour.

Page 21: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

The 𝐺𝐺(𝑛𝑛,𝑝𝑝) model

Properties of almost all graphs

Phase transition21

Page 22: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Phase transitionThe interesting thing about the 𝑮𝑮(𝑛𝑛, 𝑝𝑝)model is that even though edges are chosen independently, certain global properties of the graph emerge from the independent choice.

22

Page 23: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Definition. If there exists a function 𝑝𝑝(𝑛𝑛)such that

– when lim𝑛𝑛→∞

𝑝𝑝1(𝑛𝑛)𝑝𝑝(𝑛𝑛)

= 0, 𝑮𝑮 𝑛𝑛,𝑝𝑝1 𝑛𝑛 almost surely does not have the property.

– when lim𝑛𝑛→∞

𝑝𝑝2(𝑛𝑛)𝑝𝑝(𝑛𝑛)

= ∞, 𝑮𝑮 𝑛𝑛, 𝑝𝑝2 𝑛𝑛 almost surely has the property.

Then we say phase transition occurs and 𝑝𝑝(𝑛𝑛) is the threshold.

23

Phase transition

Every increasing property has a threshold.

Page 24: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

24

Phase transition

Page 25: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

First moment methodMarkov’s Inequality: Let 𝑥𝑥 be a random variable that assumes only nonnegative values. Then for all 𝑉𝑉 > 0

Pr 𝑥𝑥 ≥ 𝑉𝑉 ≤𝑬𝑬[𝑥𝑥]𝑉𝑉

25

First moment method : for non-negative, integer valued variable 𝑥𝑥

Pr 𝑥𝑥 > 0 = Pr 𝑥𝑥 ≥ 1 ≤ 𝑬𝑬(𝑥𝑥)∴ Pr 𝑥𝑥 = 0 = 1 − Pr 𝑥𝑥 > 0 ≥ 1 − 𝑬𝑬(𝑥𝑥)

Page 26: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

• If the expectation goes to 0: the property almost surely does not happen.

• If the expectation does not goes to 0:e.g. Expectation = 1

𝑛𝑛× 𝑛𝑛2 + 𝑛𝑛−1

𝑛𝑛× 0 = 𝑛𝑛

i.e., a vanishingly small fraction of the sample contribute a lot to the expectation.

26

First moment method : for non-negative , integer valued variable 𝑥𝑥

Pr 𝑥𝑥 > 0 = Pr 𝑥𝑥 ≥ 1 ≤ 𝑬𝑬(𝑥𝑥)∴ Pr 𝑥𝑥 = 0 = 1 − Pr 𝑥𝑥 > 0 ≥ 1 − 𝑬𝑬(𝑥𝑥)

Page 27: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Chebyshev’s Inequality

• For any 𝑉𝑉 > 0,

Pr 𝑋𝑋 − 𝐸𝐸 𝑋𝑋 ≥ 𝑉𝑉 ≤𝑉𝑉𝑉𝑉𝑉𝑉[𝑋𝑋]𝑉𝑉2

27

Page 28: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Second moment methodTheorem. Let 𝑥𝑥(𝑛𝑛) be a random variable with 𝑬𝑬 𝑥𝑥 > 0. If

𝑉𝑉𝑉𝑉𝑉𝑉 𝑥𝑥 = 𝑜𝑜 𝑬𝑬2 𝑥𝑥Then 𝑥𝑥 is almost surely greater than zero.

28

Proof. If 𝑬𝑬 𝑥𝑥 > 0, then for 𝑥𝑥 ≤ 0, Pr 𝑥𝑥 ≤ 0 ≤ Pr 𝑥𝑥 − 𝑬𝑬 𝑥𝑥 ≥ 𝑬𝑬(𝑥𝑥)

≤𝑉𝑉𝑉𝑉𝑉𝑉 𝑥𝑥𝐸𝐸2 𝑥𝑥

→ 0

Page 29: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

29

Example : Threshold for graph diameter two (two degrees of separation)

Page 30: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Example : Threshold for graph diameter two (two degrees of separation)

• Diameter: the maximum length of the shortest path between a pair of nodes.

• Theorem: The property that 𝑮𝑮(𝑛𝑛, 𝑝𝑝) has diameter two has a sharp threshold at 𝑝𝑝 =

2 ln 𝑛𝑛𝑛𝑛

.

30

Page 31: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Example : Threshold for graph diameter two (two degrees of separation)

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

31

Proof. For any two different vertices 𝑖𝑖 < 𝑗𝑗, 𝐼𝐼𝑖𝑖𝑗𝑗 = �1 i, j ∉𝐸𝐸, no other vertex is adjacent to both 𝑖𝑖 𝑉𝑉𝑛𝑛𝑑𝑑 𝑗𝑗

0 𝑜𝑜𝑜𝑜𝑜𝑒𝑒𝑉𝑉𝑤𝑤𝑖𝑖𝑜𝑜𝑒𝑒

𝑥𝑥 = �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗 If 𝑬𝑬 𝑥𝑥𝑛𝑛→∞

0, then for large 𝑛𝑛, almost surely the diameter is at most two.

Page 32: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Example : Threshold for graph diameter two (two degrees of separation)

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

32

Proof. For any two different vertices 𝑖𝑖 < 𝑗𝑗, 𝐼𝐼𝑖𝑖𝑗𝑗 = �1 i, j ∉𝐸𝐸, no other vertex is adjacent to both 𝑖𝑖 𝑉𝑉𝑛𝑛𝑑𝑑 𝑗𝑗

0 𝑜𝑜𝑜𝑜𝑜𝑒𝑒𝑉𝑉𝑤𝑤𝑖𝑖𝑜𝑜𝑒𝑒

𝑬𝑬 𝑥𝑥 =𝑛𝑛2

1 − 𝑝𝑝 1 − 𝑝𝑝2 𝑛𝑛−2

Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝐸𝐸(𝑥𝑥) ≅ 𝑛𝑛2

21 − 𝑐𝑐 ln 𝑛𝑛

𝑛𝑛1 − 𝑐𝑐2 ln 𝑛𝑛

𝑛𝑛

𝑛𝑛

𝑥𝑥 = �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗

≅𝑛𝑛2

2𝑒𝑒−𝑐𝑐2 ln 𝑛𝑛 =

12𝑛𝑛2−𝑐𝑐2

Page 33: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

Example : Threshold for graph diameter two (two degrees of separation)

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

33

Proof. For any two different vertices 𝑖𝑖 < 𝑗𝑗, 𝐼𝐼𝑖𝑖𝑗𝑗 = �1 i, j ∉𝐸𝐸, no other vertex is adjacent to both 𝑖𝑖 𝑉𝑉𝑛𝑛𝑑𝑑 𝑗𝑗

0 𝑜𝑜𝑜𝑜𝑜𝑒𝑒𝑉𝑉𝑤𝑤𝑖𝑖𝑜𝑜𝑒𝑒

𝑬𝑬 𝑥𝑥 =𝑛𝑛2

1 − 𝑝𝑝 1 − 𝑝𝑝2 𝑛𝑛−2

Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 > 2, lim𝑛𝑛→∞

𝑬𝑬 𝑥𝑥 = 0

𝑥𝑥 = �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗

For large 𝑛𝑛, almost surely the diameter is at most two.

Page 34: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

34

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 > 2, lim𝑛𝑛→∞

𝑬𝑬 𝑥𝑥 = 0

Page 35: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

35

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2,

𝑬𝑬 𝑥𝑥2 = 𝑬𝑬 �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗2 If 𝑉𝑉𝑉𝑉𝑉𝑉 𝑥𝑥 = 𝑜𝑜 𝑬𝑬2 𝑥𝑥 , then for large 𝑛𝑛,

almost surely the diameter will be larger than two.

Page 36: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

36

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 = 𝑬𝑬 �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗2

= 𝑬𝑬 �𝑖𝑖<𝑗𝑗

𝐼𝐼𝑖𝑖𝑗𝑗�𝑘𝑘<𝑙𝑙

𝐼𝐼𝑘𝑘𝑙𝑙 = 𝑬𝑬 �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙

𝐼𝐼𝑖𝑖𝑗𝑗 𝐼𝐼𝑘𝑘𝑙𝑙 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙

𝑉𝑉 = | 𝑖𝑖, 𝑗𝑗, 𝑘𝑘, 𝑙𝑙 |

𝑬𝑬 𝑥𝑥2 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 + �𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘𝑎𝑎=3

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 + �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2

Page 37: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

37

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 + �𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘𝑎𝑎=3

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 + �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 ≤ 1 − 𝑝𝑝2 2 𝑛𝑛−4 ≤ 1 − 𝑐𝑐2ln𝑛𝑛𝑛𝑛

2𝑛𝑛

1 + 𝑜𝑜 1 ≤ 𝑛𝑛−2𝑐𝑐2(1 + 𝑜𝑜(1))

�𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 ≤ 𝑛𝑛4−2𝑐𝑐2(1 + 𝑜𝑜(1))𝑖𝑖 𝑗𝑗 𝑘𝑘 𝑙𝑙

𝑢𝑢

Page 38: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

38

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 + �𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘𝑎𝑎=3

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 + �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2

𝑖𝑖 𝑗𝑗 𝑘𝑘

𝑢𝑢

Page 39: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

39

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 + �𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘𝑎𝑎=3

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 + �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2

Pr 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 = 1 ≤ 1 − 𝑝𝑝 + 𝑝𝑝 1 − 𝑝𝑝 2 = 1 − 2𝑝𝑝2 + 𝑝𝑝3 ≈ 1 − 2𝑝𝑝2

�𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 ≤ 𝑛𝑛3−2𝑐𝑐2

𝑖𝑖 𝑗𝑗 𝑘𝑘

𝑢𝑢

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 ≤ 1 − 2𝑝𝑝2 𝑛𝑛−3 = 1 −2𝑐𝑐2 ln𝑛𝑛

𝑛𝑛

𝑛𝑛−3

≅ 𝑒𝑒−2𝑐𝑐2 ln 𝑛𝑛 = 𝑛𝑛−2𝑐𝑐2

Page 40: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

40

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 = �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=4

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑘𝑘𝑙𝑙 + �𝑖𝑖<𝑗𝑗𝑖𝑖<𝑘𝑘𝑎𝑎=3

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗𝐼𝐼𝑖𝑖𝑘𝑘 + �𝑖𝑖<𝑗𝑗𝑘𝑘<𝑙𝑙𝑎𝑎=2

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2

𝐸𝐸(𝐼𝐼𝑖𝑖𝑗𝑗2 ) = 𝐸𝐸(𝐼𝐼𝑖𝑖𝑗𝑗)

�𝑖𝑖𝑗𝑗

𝑬𝑬 𝐼𝐼𝑖𝑖𝑗𝑗2 = 𝐸𝐸 𝑥𝑥 ≅12𝑛𝑛2−𝑐𝑐2

𝑖𝑖 𝑗𝑗

𝑢𝑢

Page 41: Introduction to Random Graphs - SJTUlonghuan/teaching/CS499/19.pdf · Properties of almost all graphs • For a graph property 𝑃𝑃, when 𝑛𝑛→∞, If the limit of the probability

41

Theorem. The property that 𝑮𝑮(𝑛𝑛,𝑝𝑝) has diameter

two has a sharp threshold at 𝑝𝑝 = 2 ln 𝑛𝑛𝑛𝑛

• Take 𝑝𝑝 = 𝑐𝑐 ln 𝑛𝑛𝑛𝑛

, 𝑐𝑐 < 2

𝑬𝑬 𝑥𝑥2 ≤ 𝑬𝑬2(𝑥𝑥)(1 + 𝑜𝑜 1 )

A graph almost surely has at least one badpair of vertices and thus diameter greaterthan two.