Knowledge and Distributed Coordination Yoram Moses Technion NUS - - PowerPoint PPT Presentation

knowledge and distributed coordination
SMART_READER_LITE
LIVE PREVIEW

Knowledge and Distributed Coordination Yoram Moses Technion NUS - - PowerPoint PPT Presentation

Knowledge and Distributed Coordination Yoram Moses Technion NUS Research Week ( :- ) Knowledge of Preconditions January 7th, 2019 1 / 45 Outline Indistinguishability and knowledge Modeling knowledge The Knowledge of Preconditions principle


slide-1
SLIDE 1

Knowledge and Distributed Coordination

Yoram Moses

Technion

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 1 / 45

slide-2
SLIDE 2

Outline

Indistinguishability and knowledge Modeling knowledge The Knowledge of Preconditions principle Knowledge and coordination Applications

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 2 / 45

slide-3
SLIDE 3

Indistinguishability in Computing the Maximum (CtM)

75 100 80 90 1 2 3 4

Each node i has an initial value vi Agent 1 must print the maximal value After receiving “v2 = 100” Agent 1 has the maximum. Can she act?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 3 / 45

slide-4
SLIDE 4

Indistinguishability in Computing the Maximum (CtM)

75 100 80 90 1 2 3 4

v2=100

Each node i has an initial value vi Agent 1 must print the maximal value After receiving “v2 = 100” Agent 1 has the maximum. Can she act?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 3 / 45

slide-5
SLIDE 5

Indistinguishability in Computing the Maximum (CtM)

75 100 80 90 1 2 3 4

v2=100

Each node i has an initial value vi Agent 1 must print the maximal value After receiving “v2 = 100” Agent 1 has the maximum. Can she act?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 3 / 45

slide-6
SLIDE 6

Indistinguishability in Computing the Maximum (CtM)

75 100 80 90 1 2 3 4

v2=100 75 100 90

1 2 3 4

v2=100

200

No!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 4 / 45

slide-7
SLIDE 7

Collecting Values

75 100 80 90 1 2 3 4

90

Collecting all values is not necessary Collecting all values is not sufficient if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-8
SLIDE 8

Collecting Values

75 100 80 90 1 2 3 4

90

Collecting all values is not necessary Collecting all values is not sufficient if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-9
SLIDE 9

Collecting Values

75 100 80 90 1 2 3 4

v2=100

100

Collecting all values is not necessary Collecting all values is not sufficient if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-10
SLIDE 10

Collecting Values

75 100 80 90 1 2 3 4

100,80,90

Collecting all values is not necessary Collecting all values is not sufficient if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-11
SLIDE 11

Collecting Values

75 100 80 90 1 2 3 4

100,80,90

Collecting all values is not necessary Collecting all values is not sufficient... if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-12
SLIDE 12

Collecting Values

75 100 90

1 2 3 4

100,80,90

80

200

5

75 100 80 90 1 2 3 4

100,80,90

Collecting all values is not necessary Collecting all values is not sufficient... if more participants are possible

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 5 / 45

slide-13
SLIDE 13

What is CtM about?

Not collecting values!

Indistinguishability

A process takes the same actions at indistinguishable points Its actions depend on its local state.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 6 / 45

slide-14
SLIDE 14

What is CtM about?

Not collecting values!

Indistinguishability

A process takes the same actions at indistinguishable points Its actions depend on its local state.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 6 / 45

slide-15
SLIDE 15

What is CtM about?

Not collecting values!

Indistinguishability

A process takes the same actions at indistinguishable points Its actions depend on its local state.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 6 / 45

slide-16
SLIDE 16

What is CtM about?

Not collecting values!

Indistinguishability

A process takes the same actions at indistinguishable points Its actions depend on its local state.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 6 / 45

slide-17
SLIDE 17

In Pictures

r r0

1

r00 r000 r4

Agent 1 can have the same state in different runs of the protocol

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 7 / 45

slide-18
SLIDE 18

In Pictures

r r0

1

r00 r000 r4

Max 6= c

Printing c is precluded by indistinguishability

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 7 / 45

slide-19
SLIDE 19

In Pictures

r r0

1 1 1

r00 r000 r4

Max = c Max = c Max = c Max = c

Printing c is allowed iff Max = c at all indistinguishable points

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 7 / 45

slide-20
SLIDE 20

In Pictures

r r0

1 1 1

r00 r000 r4

K1(Max = c) Max = c Max = c Max = c

Printing c is allowed iff Max = c at all indistinguishable points

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 7 / 45

slide-21
SLIDE 21

In Pictures

r r0

1 1 1

r00 r000 r4

K1(Max = c) Max = c Max = c Max = c

Printing c is allowed iff agent 1 knows that Max = c

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 7 / 45

slide-22
SLIDE 22

Knowledge in CtM

Knowing that Max = c is necessary and sufficient for printing c

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 8 / 45

slide-23
SLIDE 23

Knowledge in CtM

Knowing that Max = c can depend on: Messages received The protocol The possible initial values Network topology Timing guarantees re: communication, synchrony, activation Possibility of failures, . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 9 / 45

slide-24
SLIDE 24

Problem Specifications and Necessary Conditions Cash from the ATM: Dispense($100) ⇛ good credit

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 10 / 45

slide-25
SLIDE 25

Problem Specifications and Necessary Conditions Agreement Protocols: decidei(v)

nobody decides v ′ = v

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 11 / 45

slide-26
SLIDE 26

Problem Specifications and Necessary Conditions Autonomous Cars: Enter_intersection

no cross-traffic

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 12 / 45

slide-27
SLIDE 27

Problem Specifications and Necessary Conditions Computing the Max: print(c) ⇛ Max = c and we have seen print(c) ⇛ K1(Max = c)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 13 / 45

slide-28
SLIDE 28

Problem Specifications and Necessary Conditions Computing the Max: print(c) ⇛ Max = c and we have seen print(c) ⇛ K1(Max = c)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 13 / 45

slide-29
SLIDE 29

Problem Specifications and Necessary Conditions Computing the Max: print(c) ⇛ Max = c and we have seen print(c) ⇛ K1(Max = c)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 13 / 45

slide-30
SLIDE 30

The Knowledge of Preconditions Principle (KoP) If performing α ⇛ ϕ Then i performs α ⇛ Kiϕ An essential connection between knowledge and action

Let’s Prove it

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 45

slide-31
SLIDE 31

The Knowledge of Preconditions Principle (KoP) If performing α ⇛ ϕ Then i performs α ⇛ Kiϕ An essential connection between knowledge and action

Let’s Prove it

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 45

slide-32
SLIDE 32

The Knowledge of Preconditions Principle (KoP) If performing α ⇛ ϕ Then i performs α ⇛ Kiϕ An essential connection between knowledge and action

Let’s Prove it

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 45

slide-33
SLIDE 33

The Knowledge of Preconditions Principle (KoP) If performing α ⇛ ϕ Then i performs α ⇛ Kiϕ An essential connection between knowledge and action

Let’s Prove it

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 45

slide-34
SLIDE 34

The Knowledge of Preconditions Principle (KoP) If performing α ⇛ ϕ Then i performs α ⇛ Kiϕ An essential connection between knowledge and action

Let’s Prove it

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 45

slide-35
SLIDE 35

A Theory of Knowledge in Distributed Systems

A three decades old theory of knowledge is based on Halpern and M. [1984] Parikh and Ramanujam [1985] Chandy and Misra [1986] Fagin et al. [1995], Reasoning about Knowledge and earlier Kripke 1950’s, Hintikka [1962], Aumann [1976]

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 15 / 45

slide-36
SLIDE 36

Basic notion: Indistinguishability r

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 16 / 45

slide-37
SLIDE 37

Basic notion: Indistinguishability r r0

i

i has the same state at both points

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 16 / 45

slide-38
SLIDE 38

Basic notion: Indistinguishability r r0

1

Max 6= 100

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 16 / 45

slide-39
SLIDE 39

Basic notion: Indistinguishability

print1(100)

r r0

1

X

Max 6= 100

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 16 / 45

slide-40
SLIDE 40

Defining Knowledge in Pictures r r0 r00 r000 r4

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 17 / 45

slide-41
SLIDE 41

Defining Knowledge in Pictures r r0

i i i

r00 r000 r4

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 17 / 45

slide-42
SLIDE 42

Defining Knowledge in Pictures r r0

i i i

r00 r000

  • r4
  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 17 / 45

slide-43
SLIDE 43

Defining Knowledge in Pictures r r0

i i i

r00 r000

  • Ki

r4

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 17 / 45

slide-44
SLIDE 44

Defining Knowledge more formally

[Fagin et al. 1995]

A run is a sequence r : N → G

  • f global states.

A system is a set R of runs. Typically, R = {runs of a protocol P in a model M}.

Assumption

Each global state r(t) determines a local state ri(t) for every agent i. A point (r, t) refers to time t in run r.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 18 / 45

slide-45
SLIDE 45

Defining Knowledge more formally

[Fagin et al. 1995]

A run is a sequence r : N → G

  • f global states.

A system is a set R of runs. Typically, R = {runs of a protocol P in a model M}.

Assumption

Each global state r(t) determines a local state ri(t) for every agent i. A point (r, t) refers to time t in run r.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 18 / 45

slide-46
SLIDE 46

Defining Knowledge more formally

[Fagin et al. 1995]

A run is a sequence r : N → G

  • f global states.

A system is a set R of runs. Typically, R = {runs of a protocol P in a model M}.

Assumption

Each global state r(t) determines a local state ri(t) for every agent i. A point (r, t) refers to time t in run r.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 18 / 45

slide-47
SLIDE 47

A Propositional Logic of Knowledge

Facts are considered "true" or "false" at a point. (R, r, t) | = ϕ denotes that ϕ is true at (r, t) wrt R.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 19 / 45

slide-48
SLIDE 48

A Propositional Logic of Knowledge

Starting from a set Φ of primitive propositions, define LK

n = LK n (Φ) by

ϕ := p ∈ Φ | ¬ϕ | ϕ ∧ ϕ | K1ϕ | · · · | Knϕ Given an interpretation π : Φ × Pts(R) → {True, False} (R, r, t) | = p, for p ∈ Φ, iff π(p, r, t) = True. (R, r, t) | = ¬ϕ iff (R, r, t) | = ϕ (R, r, t) | = ϕ ∧ ψ iff both (R, r, t) | = ϕ and (R, r, t) | = ψ.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 20 / 45

slide-49
SLIDE 49

Knowledge = Truth in All Possible Worlds

(R, r, t) | = Kiϕ iff for all points (r ′, t′) of R such that ri(t) = r ′

i(t′) we have (R, r′, t′) |

= ϕ. Comments: The definition ignores the complexity of computing knowledge Local information = current local state Kiϕ holds if ϕ is guaranteed to hold in R given i’s local state The definition is model independent

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 21 / 45

slide-50
SLIDE 50

Knowledge = Truth in All Possible Worlds

(R, r, t) | = Kiϕ iff for all points (r ′, t′) of R such that ri(t) = r ′

i(t′) we have (R, r′, t′) |

= ϕ. Comments: The definition ignores the complexity of computing knowledge Local information = current local state Kiϕ holds if ϕ is guaranteed to hold in R given i’s local state The definition is model independent

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 21 / 45

slide-51
SLIDE 51

Knowledge = Truth in All Possible Worlds

(R, r, t) | = Kiϕ iff for all points (r ′, t′) of R such that ri(t) = r ′

i(t′) we have (R, r′, t′) |

= ϕ. Comments: The definition ignores the complexity of computing knowledge Local information = current local state Kiϕ holds if ϕ is guaranteed to hold in R given i’s local state The definition is model independent

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 21 / 45

slide-52
SLIDE 52

Specifications and Knowledge

Problems in Distributed Computing are presented via specifications A bank’s system of ATMs Autonomous cars A distributed database A Google data center Specifications impose epistemic constraints on actions!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 22 / 45

slide-53
SLIDE 53

Specifications and Knowledge

Problems in Distributed Computing are presented via specifications A bank’s system of ATMs Autonomous cars A distributed database A Google data center Specifications impose epistemic constraints on actions!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 22 / 45

slide-54
SLIDE 54

Knowledge of Preconditions

(R, r, t) | = doesi(α) iff i performs α at time t in r.

Theorem (KoP)

Under minor assumptions on α and ϕ in R: If ϕ is a necessary condition for doesi(α) in R, then Kiϕ is a necessary condition for doesi(α) in R.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 23 / 45

slide-55
SLIDE 55

Deterministic Actions r

doesi(α)

, doesi(α)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 24 / 45

slide-56
SLIDE 56

Deterministic Actions r r0

i

doesi(α)

, doesi(α)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 24 / 45

slide-57
SLIDE 57

Deterministic Actions r r0

i

doesi(α)

, doesi(α)

doesi(α)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 24 / 45

slide-58
SLIDE 58

Deterministic Actions

Definition

Action α is deterministic for i in R if whenever ri(t) = r ′

i(t′):

(R, r, t) | = doesi(α) iff (R, r ′, t′) | = doesi(α). i’s local state determines whether it performs α at points of R.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 25 / 45

slide-59
SLIDE 59

Deterministic Actions

Definition

Action α is deterministic for i in R if whenever ri(t) = r ′

i(t′):

(R, r, t) | = doesi(α) iff (R, r ′, t′) | = doesi(α). i’s local state determines whether it performs α at points of R.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 25 / 45

slide-60
SLIDE 60

The KoP Theorem for Deterministic Actions

Theorem (KoP, [M. 2015]) Let α be a deterministic action for i in R. If ϕ is a necessary condition for doesi(α) in R, then Kiϕ is a necessary condition for doesi(α) in R.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 26 / 45

slide-61
SLIDE 61

Proof of KoP r

doesi(α)

, doesi(α)

(R, r, t) | = doesi(α)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-62
SLIDE 62

Proof of KoP r r0

i

doesi(α)

, doesi(α)

(r, t) ≈i (r ′, t′)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-63
SLIDE 63

Proof of KoP r r0

i

doesi(α)

, doesi(α)

doesi(α) α is deterministic

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-64
SLIDE 64

Proof of KoP r r0

i

doesi(α)

, doesi(α)

doesi(α)

  • ϕ is a necessary condition

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-65
SLIDE 65

Proof of KoP r r0

i

doesi(α)

, doesi(α)

  • ϕ holds at all indistinguishable points

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-66
SLIDE 66

Proof of KoP r r0

i

doesi(α)

, doesi(α)

Ki

  • so Kiϕ holds

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-67
SLIDE 67

Proof of KoP r

doesi(α)

, doesi(α)

Ki

doesi(α) ⇛ Kiϕ QED

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 27 / 45

slide-68
SLIDE 68

KoP Applies Very Broadly

The KoP is a universal theorem for distributed systems KoP applies to ATMs, autonomous cars, and even more generally:

◮ Legal systems:

Judge Punishes X ⇛ X committed the crime Judge Punishes X ⇛ KJ(X committed the crime)

◮ Nature:

Jellyfish stings X ⇛ X = a rock Jellyfish stings X ⇛ KJ(X = a rock)

◮ Betting:

Don bets on Phar Lap ⇛ PL will win Don bets on Phar Lap ⇛ KD(PL will win)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 28 / 45

slide-69
SLIDE 69

KoP Applies Very Broadly

The KoP is a universal theorem for distributed systems KoP applies to ATMs, autonomous cars, and even more generally:

◮ Legal systems:

Judge Punishes X ⇛ X committed the crime Judge Punishes X ⇛ KJ(X committed the crime)

◮ Nature:

Jellyfish stings X ⇛ X = a rock Jellyfish stings X ⇛ KJ(X = a rock)

◮ Betting:

Don bets on Phar Lap ⇛ PL will win Don bets on Phar Lap ⇛ KD(PL will win)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 28 / 45

slide-70
SLIDE 70

KoP Applies Very Broadly

The KoP is a universal theorem for distributed systems KoP applies to ATMs, autonomous cars, and even more generally:

◮ Legal systems:

Judge Punishes X ⇛ X committed the crime Judge Punishes X ⇛ KJ(X committed the crime)

◮ Nature:

Jellyfish stings X ⇛ X = a rock Jellyfish stings X ⇛ KJ(X = a rock)

◮ Betting:

Don bets on Phar Lap ⇛ PL will win Don bets on Phar Lap ⇛ KD(PL will win)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 28 / 45

slide-71
SLIDE 71

KoP Applies Very Broadly

The KoP is a universal theorem for distributed systems KoP applies to ATMs, autonomous cars, and even more generally:

◮ Legal systems:

Judge Punishes X ⇛ X committed the crime Judge Punishes X ⇛ KJ(X committed the crime)

◮ Nature:

Jellyfish stings X ⇛ X = a rock Jellyfish stings X ⇛ KJ(X = a rock)

◮ Betting:

Don bets on Phar Lap ⇛ PL will win Don bets on Phar Lap ⇛ KD(PL will win)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 28 / 45

slide-72
SLIDE 72

KoP Applies Very Broadly

The KoP is a universal theorem for distributed systems KoP applies to ATMs, autonomous cars, and even more generally:

◮ Legal systems:

Judge Punishes X ⇛ X committed the crime Judge Punishes X ⇛ KJ(X committed the crime)

◮ Nature:

Jellyfish stings X ⇛ X = a rock Jellyfish stings X ⇛ KJ(X = a rock)

◮ Betting:

Don bets on Phar Lap ⇛ PL will win Don bets on Phar Lap ⇛ KD(PL will win)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 28 / 45

slide-73
SLIDE 73

An Application: Binary Consensus

Model: Each process i = 1, . . . , n starts with a value vi ∈ {0, 1}. Communication network is a complete graph Synchronous message passing At most t < n crash failures We assume a full-information protocol

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 29 / 45

slide-74
SLIDE 74

An Application: Binary Consensus

Specification: A consensus protocol must guarantee Decision: Every correct process decides on a value in {0, 1}. Agreement: All correct processes decide on the same value. Validity: A decision value must be an initial value.

Validity means decidei(v) ⇛ ∃v

and so

decidei(0) ⇛ Ki∃0

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 30 / 45

slide-75
SLIDE 75

An Application: Binary Consensus

Specification: A consensus protocol must guarantee Decision: Every correct process decides on a value in {0, 1}. Agreement: All correct processes decide on the same value. Validity: A decision value must be an initial value.

Validity means decidei(v) ⇛ ∃v

and so

decidei(0) ⇛ Ki∃0

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 30 / 45

slide-76
SLIDE 76

An Application: Binary Consensus

Specification: A consensus protocol must guarantee Decision: Every correct process decides on a value in {0, 1}. Agreement: All correct processes decide on the same value. Validity: A decision value must be an initial value.

Validity means decidei(v) ⇛ ∃v

and so

decidei(0) ⇛ Ki∃0

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 30 / 45

slide-77
SLIDE 77

Knowing ∃0

1 2 3 4 6 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

Kj∃0 Kj∃0

5

Kh∃0

Kj∃0 holds iff there is a message chain from an initial value of 0 to j.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-78
SLIDE 78

Knowing ∃0

¬Ki∃0 Kj∃0

How can one proc know ∃0 when another does not?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-79
SLIDE 79

Knowing ∃0

¬Ki∃0 Kj∃0

How can one proc know ∃0 when another does not?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-80
SLIDE 80

Knowing ∃0

¬Ki∃0 Kj∃0 ¬Kj∃0

How can one proc know ∃0 when another does not?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-81
SLIDE 81

Knowing ∃0

¬Ki∃0 Kj∃0 ¬Kj∃0 Kj∃0

How can one proc know ∃0 when another does not?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-82
SLIDE 82

Knowing ∃0

¬Ki∃0 Kj∃0 ¬Kj∃0

x x

Kj∃0

How can one proc know ∃0 when another does not?

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-83
SLIDE 83

Knowing ∃0

1 2 3 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

¬Ki∃0 Kj∃0 ¬Kj∃0

x

Kj∃0

m NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-84
SLIDE 84

Knowing ∃0

1 2 3 . . . . . .

x

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

¬Ki∃0 Kj∃0

m NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-85
SLIDE 85

Knowing ∃0

1 2 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

¬Ki∃0 Kj∃0

x x x x x x x x x x x x x x x

m 3

Claim: If Kj∃0 & ¬Ki∃0 at time m, then ≥ m crashes have occurred

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-86
SLIDE 86

Knowing ∃0

1 2 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

¬Ki∃0 Kj∃0

x x x x x x x x x x x x x x x

m 3

Corollary: At time t + 1, either everyone knows ∃0 or nobody does

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 31 / 45

slide-87
SLIDE 87

A Simple Consensus Protocol

Protocol P0 (for undecided process i): if time = t + 1 & ¬Ki∃0 then decidei(0) elseif time = t + 1 & ¬Ki∃0 then decidei(1) Communication is according to the fip. All decisions at time t + 1

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 32 / 45

slide-88
SLIDE 88

A Simple Consensus Protocol

Protocol P0 (for undecided process i): if time = t + 1 & ¬Ki∃0 then decidei(0) elseif time = t + 1 & ¬Ki∃0 then decidei(1) Communication is according to the fip. All decisions at time t + 1

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 32 / 45

slide-89
SLIDE 89

A Better Protocol

Protocol Q0 (for undecided process i): if Ki∃0 then decidei(0) elseif time = t + 1 & ¬Ki∃0 then decidei(1) All decisions by time t + 1

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 33 / 45

slide-90
SLIDE 90

A Better Protocol

Protocol Q0 (for undecided process i): if Ki∃0 then decidei(0) elseif time = t + 1 & ¬Ki∃0 then decidei(1) All decisions by time t + 1

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 33 / 45

slide-91
SLIDE 91

Performance of P0 and Q0

Adversaries

Time of last decision 1 2 t+1

P0

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 34 / 45

slide-92
SLIDE 92

Performance of P0 and Q0

Adversaries

Time of last decision 1 2 t+1

P0 Q0

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 34 / 45

slide-93
SLIDE 93

Performance of P0 and Q0

Adversaries

Time of last decision 1 2 t+1

P0 Q0

1

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 34 / 45

slide-94
SLIDE 94

Deciding Efficiently on 1

Design Decision:

Kj∃0 ⇔ decidej(0). When can decidei(1) be performed? Recall: yyAgreement: decidei(1) ⇛ Nobody decides 0 By KoP, decidei(1) ⇛ “no currently active process knows ∃0” By KoP, decidei(1) ⇛ Ki

nobody_knows∃0

  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 35 / 45

slide-95
SLIDE 95

Deciding Efficiently on 1

Design Decision:

Kj∃0 ⇔ decidej(0). When can decidei(1) be performed? Recall: yyAgreement: decidei(1) ⇛ Nobody decides 0 By KoP, decidei(1) ⇛ “no currently active process knows ∃0” By KoP, decidei(1) ⇛ Ki

nobody_knows∃0

  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 35 / 45

slide-96
SLIDE 96

Deciding Efficiently on 1

Design Decision:

Kj∃0 ⇔ decidej(0). When can decidei(1) be performed? Recall: yyAgreement: decidei(1) ⇛ Nobody decides 0 By KoP, decidei(1) ⇛ “no currently active process knows ∃0” By KoP, decidei(1) ⇛ Ki

nobody_knows∃0

  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 35 / 45

slide-97
SLIDE 97

Deciding Efficiently on 1

Design Decision:

Kj∃0 ⇔ decidej(0). When can decidei(1) be performed? Recall: yyAgreement: decidei(1) ⇛ Nobody decides 0 By KoP, decidei(1) ⇛ “no currently active process knows ∃0” By KoP, decidei(1) ⇛ Ki

nobody_knows∃0

  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 35 / 45

slide-98
SLIDE 98

Unbeatable Consensus

[Castañeda, Gonczarowski & M. ’14]

Protocol OPT0 (for undecided process i): if Ki∃0 then decidei(0) elseif Ki

nobody_knows∃0

  • then decidei(1)

My name is Sherlock Holmes. It is my business to know what other people don’t know.

The Adventure of the Blue Carbuncle, 1892

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 36 / 45

slide-99
SLIDE 99

Unbeatable Consensus

[Castañeda, Gonczarowski & M. ’14]

Protocol OPT0 (for undecided process i): if Ki∃0 then decidei(0) elseif Ki

nobody_knows∃0

  • then decidei(1)

My name is Sherlock Holmes. It is my business to know what other people don’t know.

The Adventure of the Blue Carbuncle, 1892

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 36 / 45

slide-100
SLIDE 100

Kj∃0?

1 2 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

¬Ki∃0

x x x x x x x x x x x x x x x

m 3

? ? ? ? ?

?

W.r.t. (i, m), nodes are seen, crashed, or hidden

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 37 / 45

slide-101
SLIDE 101

Kj∃0?

1 2 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

x x x x x x x x x x x x x x x

m 3

? ? ? ? ?

?

¬Ki∃0

A hidden path wrt (i, m)

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 37 / 45

slide-102
SLIDE 102

Kj∃0?

1 2 . . . . . .

1 1 1 1 1 1 1 1 1 1

j i

1 2 3

n

.

x x x x x x x x x x x x x x x

m 3

? ? ? ? ?

?

¬Ki∃0

Theorem: ∃ a hidden path iff ¬Ki

nobody_knows∃0

  • NUS Research Week

(:-) Knowledge of Preconditions January 7th, 2019 37 / 45

slide-103
SLIDE 103

Implementing OPT0

[Castañeda, Gonczarowski & M. ’14]

Standard OPT0 (for undecided process i): if seen 0 then decidei(0) elseif no hidden path then decidei(1)

Theorem (CGM)

OPT0 strictly dominates Q0 OPT0 is unbeatable: No consensus protocol dominates it. OPT0 is implementable using O(tlogn) bits of communication per process

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 38 / 45

slide-104
SLIDE 104

Implementing OPT0

[Castañeda, Gonczarowski & M. ’14]

Standard OPT0 (for undecided process i): if seen 0 then decidei(0) elseif no hidden path then decidei(1)

Theorem (CGM)

OPT0 strictly dominates Q0 OPT0 is unbeatable: No consensus protocol dominates it. OPT0 is implementable using O(tlogn) bits of communication per process

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 38 / 45

slide-105
SLIDE 105

Ordering Actions

Definition (Ordered Actions)

Actions α1, . . . , αk (for agents 1, . . . , k) are ordered in R if doesj(αj) ⇛ Didj−1(αj−1) in R I.e., tj−1 ≤ tj if ti denotes when αi occurs.

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 39 / 45

slide-106
SLIDE 106

Nested Knowledge and Ordered Actions

Theorem (Nested Knowledge of Preconditions)

Let α1, . . . , αk be ordered in R. If does1(α1) ⇛

  • cc′d(e)

in R then doesj(αj) ⇛ K jKj−1 · · · K1 occ′d(e) in R

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 40 / 45

slide-107
SLIDE 107

Nested Knowledge and Ordered Actions

Theorem (Nested Knowledge of Preconditions)

Let α1, . . . , αk be ordered in R. If does1(α1) ⇛

  • cc′d(e)

in R then doesj(αj) ⇛ K jKj−1 · · · K1 occ′d(e) in R

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 40 / 45

slide-108
SLIDE 108

Relating Knowledge and Communication

In “How Processes Learn” in 1985 Chandy and Misra showed

Theorem (Knowledge Gain)

Let R be asynchronous and t1 > t0. If (R, r, t0) | = ¬K1ϕ and (R, r, t1) | = K2K1ϕ

1 2 3 4 ¬K1 K2K1

t0 t1 NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 41 / 45

slide-109
SLIDE 109

Relating Knowledge and Communication

In “How Processes Learn” in 1985 Chandy and Misra showed

Theorem (Knowledge Gain)

Let R be asynchronous and t1 > t0. If (R, r, t0) | = ¬K1ϕ and (R, r, t1) | = K2K1ϕ then there must be a (Lamport) message chain in r from process 1 to process 2 between times t0 and t1.

1 2 3 4 ¬K1 K2K1

t0 t1 NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 41 / 45

slide-110
SLIDE 110

Relating Knowledge and Communication

In “How Processes Learn” in 1985 Chandy and Misra showed

Theorem (Knowledge Gain)

Let R be asynchronous and t1 > t0. If (R, r, t0) | = ¬K1ϕ and (R, r, t1) | = KmKm−1 · · · K1ϕ then there must be a (Lamport) message chain in r from process 1 through process 2, 3, . . . , m between times t0 and t1.

1 2 3 4 ¬K1

t0 t1 K3K1K2K1 NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 41 / 45

slide-111
SLIDE 111

Relating Knowledge and Communication

In “How Processes Learn” in 1985 Chandy and Misra showed

Theorem (Knowledge Gain)

Let R be asynchronous and t1 > t0. If (R, r, t0) | = ¬K1ϕ and (R, r, t1) | = KmKm−1 · · · K1ϕ then there must be a (Lamport) message chain in r from process 1 through process 2, 3, . . . , m between times t0 and t1.

Corollary

Message chains are necessary for ordering actions under asynchrony

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 41 / 45

slide-112
SLIDE 112

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-113
SLIDE 113

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-114
SLIDE 114

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-115
SLIDE 115

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-116
SLIDE 116

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-117
SLIDE 117

Temporal Ordering Example: The Frozen Account

Alice, Bob, Charlie and Susan are nodes in a network. Charlie Bob Alice Susan Alice needs to cash Charlie’s cheque Charlie’s account is frozen ⇒ they must coordinate. . . Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 11 / 21

slide-118
SLIDE 118

The Clocks and Bounds Model

We assume a directed network graph and Global clocks An upper boundij on transmission times per channel i ↦ j

1 ≤ boundij < ∞

▸ Delivery within the bound is guaranteed

Lower bounds of 1 on message transmission.

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 25 / 38

slide-119
SLIDE 119

The Clocks and Bounds Model

We assume a directed network graph and Global clocks An upper boundij on transmission times per channel i ↦ j

1 ≤ boundij < ∞

▸ Delivery within the bound is guaranteed

Lower bounds of 1 on message transmission.

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 25 / 38

slide-120
SLIDE 120

The Clocks and Bounds Model

We assume a directed network graph and Global clocks An upper boundij on transmission times per channel i ↦ j

1 ≤ boundij < ∞

▸ Delivery within the bound is guaranteed

Lower bounds of 1 on message transmission. Charlie Bob Alice Susan 10 11 12 ∞ 9 4

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 25 / 38

slide-121
SLIDE 121

Causal Cones — Digital Time/Space

Upper bounds determine a cone of necessarily affected nodes.

affected by θ t θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-122
SLIDE 122

Causal Cones — Digital Time/Space

Lower bounds determine a co-cone of necessarily unaffected nodes.

t unaffected by θ θ =⟨i,t⟩

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-123
SLIDE 123

Causal Cones — Digital Time/Space

Bounds create 3 regions:

Possibly affected by θ Affected by θ t Unaffected by θ θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-124
SLIDE 124

Causal Cones — Digital Time/Space

Impact of a message delivery

Possibly affected by θ Affected by θ t Unaffected by θ θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-125
SLIDE 125

Causal Cones — Digital Time/Space

A delivery extends inner and outer regions

Affected Maybe? Maybe? t Unaffected θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-126
SLIDE 126

Causal Cones — Digital Time/Space

All past uncertainty at t′ > t is resolved

Affected Maybe? Maybe? t t′ Unaffected θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-127
SLIDE 127

Causal Cones — Digital Time/Space

Ex-post, all uncertainty is resolved

Affected t′ → ∞ Unaffected t θ

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 26 / 38

slide-128
SLIDE 128

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-129
SLIDE 129

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-130
SLIDE 130

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-131
SLIDE 131

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-132
SLIDE 132

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-133
SLIDE 133

Event Ordering for Alice, Bob & Charlie

With clocks, ordering seems simple. . . But Charlie’s deposit is spontaneous Information flow is then required for

▸ notifying Alice and Bob of the deposit and ▸ managing coordination

Lamport message chains can be used Do clocks help?

t t′ Alice Susan Charlie Bob

Charlie deposits

  • n Sunday

Bob reactivates

  • n Monday

Alice cashes in

  • n Tuesday

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 27 / 38

slide-134
SLIDE 134

Ordering Based on Time Bounds

Time bounds:

Alice Charlie Bob t Charlie deposits a sufficient sum

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 28 / 38

slide-135
SLIDE 135

Ordering Based on Time Bounds

Time bounds:

boundCharlie,Bob = 10 Alice Charlie Bob t t + 2 Charlie deposits a sufficient sum Bob reactivates Charlie’s account

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 28 / 38

slide-136
SLIDE 136

Ordering Based on Time Bounds

Time bounds:

boundCharlie,Bob = 10 Alice Charlie Bob t t + 2 t + 10 Charlie deposits a sufficient sum Bob reactivates Charlie’s account

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 28 / 38

slide-137
SLIDE 137

Ordering Based on Time Bounds

Time bounds:

boundCharlie,Bob = 10 Alice Charlie Bob t t + 2 t + 10 Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 28 / 38

slide-138
SLIDE 138

Susan Steps In

Time bounds:

Alice Susan Charlie Bob t Charlie deposits a sufficient sum

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 29 / 38

slide-139
SLIDE 139

Susan Steps In

Time bounds:

boundCharlie,Bob = 10 Alice Susan Charlie Bob t t + 3 Charlie deposits a sufficient sum Bob reactivates Charlie’s account

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 29 / 38

slide-140
SLIDE 140

Susan Steps In

Time bounds:

boundCharlie,Bob = 10 Alice Susan Charlie Bob t t + 3 t + 10 Charlie deposits a sufficient sum Bob reactivates Charlie’s account

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 29 / 38

slide-141
SLIDE 141

Susan Steps In

Time bounds:

boundCharlie,Bob = 10 boundSusan,Bob = 4 Alice Susan Charlie Bob t t + 3 t + 8 Charlie deposits a sufficient sum Bob reactivates Charlie’s account

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 29 / 38

slide-142
SLIDE 142

Susan Steps In

Time bounds:

boundCharlie,Bob = 10 boundSusan,Bob = 4 Alice Susan Charlie Bob t t + 3 t + 8 Charlie deposits a sufficient sum Bob reactivates Charlie’s account Alice cashes the cheque

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 29 / 38

slide-143
SLIDE 143

The Bound Guarantee Relation ⇢

x u v z 10 2 6 6 3 x u v z 9 2 11 6 5 3

Let Dij = shortest bound-weighted path between i and j

Definition (Bound Guarantees)

⟨i,t⟩⇢⟨j,t′⟩ iff t′ ≥ t + Dij There is enough time from t to t′ to guarantee delivery from i to j

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 30 / 38

slide-144
SLIDE 144

The Bound Guarantee Relation ⇢

x u v z 10 2 6 6 3 x u v z 9 2 11 6 5 3

Let Dij = shortest bound-weighted path between i and j

Definition (Bound Guarantees)

⟨i,t⟩⇢⟨j,t′⟩ iff t′ ≥ t + Dij There is enough time from t to t′ to guarantee delivery from i to j

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 30 / 38

slide-145
SLIDE 145

The Bound Guarantee Relation ⇢

x u v z 10 2 6 6 3 x u v z 9 2 11 6 5 3

Let Dij = shortest bound-weighted path between i and j

Definition (Bound Guarantees)

⟨i,t⟩⇢⟨j,t′⟩ iff t′ ≥ t + Dij There is enough time from t to t′ to guarantee delivery from i to j

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 30 / 38

slide-146
SLIDE 146

Revisiting the Frozen Account

Message chains vs. Bound guarantees

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-147
SLIDE 147

Revisiting the Frozen Account

Charlie notifies and coordinates both responses t t′ Alice Charlie Bob

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-148
SLIDE 148

Revisiting the Frozen Account

Charlie notifies both, but Susan coordinates t t′ Alice Susan Charlie Bob

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-149
SLIDE 149

Revisiting the Frozen Account

Charlie notifies Alice, who notifies and coordinates with Bob t t′ Alice Charlie Bob

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-150
SLIDE 150

Revisiting the Frozen Account

Charlie notifies Bob, who notifies and coordinates with Alice t t′ Alice Charlie Bob

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-151
SLIDE 151

Revisiting the Frozen Account

The four patterns are instances of ⟨Charlie,t⟩ ⟨Alice,t′⟩ θ ⟨Bob,t′⟩

t t′ Alice Charlie Bob t t′ Alice Susan Charlie Bob t t′ Alice Charlie Bob t t′ Alice Charlie Bob

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 31 / 38

slide-152
SLIDE 152

Knowledge Gain with Clocks

Theorem (Ben Zvi and M.)

Let R be a system with clocks and bounds and let e be a spontaneous event occurring at ⟨i0,t⟩ in r ∈ R. If (R,r,t′) ⊧ K2K1occ′d(e) then the following picture must hold in r: ⟨i0,t⟩ ⟨2,t′⟩ e θ ⟨1,t′⟩

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 32 / 38

slide-153
SLIDE 153

Theorem (Centipede Theorem)

Let R be a system with clocks and bounds, and let e be a spontaneous event occurring at ⟨i0,t⟩ in r ∈ R. If (R,r,t′) ⊧ KmKm−1⋯K1occ′d(e) then there is a centipede for ⟨i0,1,2,...,m⟩ in r[t..t′]:

⟨i0,t⟩ e ⟨1,t′⟩ ⟨2,t′⟩ ⟨m,t′⟩ ⟨m − 1,t′⟩ θ1 θ2 θm−1

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 33 / 38

slide-154
SLIDE 154

⟨i0,t⟩ e ⟨1,t′⟩ ⟨2,t′⟩ ⟨m,t′⟩ ⟨m − 1,t′⟩ θ1 θ2 θm−1

Centipedes are the analogue of message chains in this model Centipedes are necessary for ordering action in this case

Yoram Moses (:-) Knowledge and Coordination 22.7.2016 35 / 38

slide-155
SLIDE 155

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-156
SLIDE 156

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-157
SLIDE 157

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-158
SLIDE 158

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-159
SLIDE 159

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-160
SLIDE 160

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-161
SLIDE 161

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-162
SLIDE 162

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-163
SLIDE 163

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-164
SLIDE 164

Simultaneous Actions

Definition

Actions α1 and α2 are (necessarily) simultaneous in R if both does1(α1) ⇛ does2(α2) and does2(α2) ⇛ does1(α1).

Corollaries

Let α1 and α2 be simultaneous in R. Then does1(α1) ⇛ K1does2(α2) by KoP does2(α2) ⇛ K1does2(α2), so does2(α2) ⇛ K2K1does2(α2) by KoP does1(α1) ⇛ K2K1does2(α2), so does1(α1) ⇛ K1K2K1does2(α2) by KoP . . .

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 42 / 45

slide-165
SLIDE 165

Simultaneity Requires Common Knowledge

The agents in G have common knowledge of ϕ, denoted by CGϕ, if Ki1Ki2 · · · Kimϕ holds for all sequences i1, i2, . . . , im of agents in G, for all m > 0.

Theorem (Common Knowledge of Preconditions)

Suppose that A = {αi}i∈G are simultaneous actions in R. If ϕ is a necessary condition for doesi(αi) for some i ∈ G, then CGϕ is a necessary condition for doesj(αj), for all j ∈ G.

  • cf. [Halpern and M. ’90]
slide-166
SLIDE 166

Simultaneity Requires Common Knowledge

The agents in G have common knowledge of ϕ, denoted by CGϕ, if Ki1Ki2 · · · Kimϕ holds for all sequences i1, i2, . . . , im of agents in G, for all m > 0.

Theorem (Common Knowledge of Preconditions)

Suppose that A = {αi}i∈G are simultaneous actions in R. If ϕ is a necessary condition for doesi(αi) for some i ∈ G, then CGϕ is a necessary condition for doesj(αj), for all j ∈ G.

  • cf. [Halpern and M. ’90]
slide-167
SLIDE 167

Knowledge and Coordination

Individual Action ⇔ Knowledge of Preconditions (KoP) Ordered Action ⇔ Nested Knowledge of Preconditions Simultaneous Action ⇔ Common Knowledge of Preconditions

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 44 / 45

slide-168
SLIDE 168

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-169
SLIDE 169

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-170
SLIDE 170

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-171
SLIDE 171

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-172
SLIDE 172

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-173
SLIDE 173

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-174
SLIDE 174

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-175
SLIDE 175

Summary

The KoP relates knowledge and action Knowledge is defined in a model-independent fashion Applies very broadly: Social science, Life sciences, VLSI design. . . Useful for designing efficient distributed protocols Effective for analyzing coordination Next step: Probabilistic variants of the KoP.

Thank You!

NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 45 / 45

slide-176
SLIDE 176

References

Chandy, Mani and Jay Misra. How Processes Learn. Distributed Computing, 1986. Fagin, Ronald, Joseph Y. Halpern, YM, and Moshe Y. Vardi. Reasoning About Knowledge. MIT press, 2003. Ben-Zvi, Ido, and YM. Beyond Lamport’s Happened-before: On Time Bounds and the Ordering of Events in Distributed Systems. Journal of the ACM (2014). Castañeda, Armando, Yannai A. Gonczarowski, and YM. Unbeatable Consensus. Proceedings of DISC 2014. Moses, Yoram. Relating Knowledge and Coordinated Action: The Knowledge of Preconditions Principle. Proceedings of TARK 2015, arXiv preprint arXiv:1606.07525 (2016). Goren, Guy, and YM. Silence. Proceedings of PODC 2018 NUS Research Week (:-) Knowledge of Preconditions January 7th, 2019 14 / 14