Concurrent Kleene Algebra: Free Model and Completeness Tobias Kapp - - PowerPoint PPT Presentation

concurrent kleene algebra free model and completeness
SMART_READER_LITE
LIVE PREVIEW

Concurrent Kleene Algebra: Free Model and Completeness Tobias Kapp - - PowerPoint PPT Presentation

Concurrent Kleene Algebra: Free Model and Completeness Tobias Kapp e Paul Brunet Alexandra Silva Fabio Zanasi University College London Leiden, 28 May 2018 Introduction Lets write a program that outputs n > 0 space-separated


slide-1
SLIDE 1

Concurrent Kleene Algebra: Free Model and Completeness

Tobias Kapp´ e Paul Brunet Alexandra Silva Fabio Zanasi

University College London

Leiden, 28 May 2018

slide-2
SLIDE 2

Introduction

Let’s write a program that outputs n > 0 space-separated ’s.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20
slide-3
SLIDE 3

Introduction

Let’s write a program that outputs n > 0 space-separated ’s. i := 1 while i < n do print print i := i + 1 end print

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20
slide-4
SLIDE 4

Introduction

Let’s write a program that outputs n > 0 space-separated ’s. i := 1 while i < n do print print i := i + 1 end print i := 1 print while i < n do print print i := i + 1 end

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20
slide-5
SLIDE 5

Introduction

Let’s write a program that outputs n > 0 space-separated ’s. i := 1 while i < n do print print i := i + 1 end print i := 1 print while i < n do print print i := i + 1 end Are these programs equivalent?

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20
slide-6
SLIDE 6

Introduction

Programs are expressions

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 3 20
slide-7
SLIDE 7

Introduction

Programs are expressions, thus we should be able to reason equationally.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 3 20
slide-8
SLIDE 8

Introduction

Programs are expressions, thus we should be able to reason equationally. Kleene Algebra (KA) provides an algebraic framework to do this.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 3 20
slide-9
SLIDE 9

Introduction

program expression atomic action a, b, . . . ∈ Σ

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-10
SLIDE 10

Introduction

program expression atomic action a, b, . . . ∈ Σ abort execution

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-11
SLIDE 11

Introduction

program expression atomic action a, b, . . . ∈ Σ abort execution no-operation 1

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-12
SLIDE 12

Introduction

program expression atomic action a, b, . . . ∈ Σ abort execution no-operation 1 nondeterministic choice e + f

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-13
SLIDE 13

Introduction

program expression atomic action a, b, . . . ∈ Σ abort execution no-operation 1 nondeterministic choice e + f sequential composition e · f

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-14
SLIDE 14

Introduction

program expression atomic action a, b, . . . ∈ Σ abort execution no-operation 1 nondeterministic choice e + f sequential composition e · f repetition e∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20
slide-15
SLIDE 15

Introduction

i := 1 while i < n do print print i := i + 1 end print i := 1 print while i < n do print print i := i + 1 end

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20
slide-16
SLIDE 16

Introduction

i := 1 while i < n do print print i := i + 1 end print i := 1 print while i < n do print print i := i + 1 end

( · )∗ ·

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20
slide-17
SLIDE 17

Introduction

i := 1 while i < n do print print i := i + 1 end print i := 1 print while i < n do print print i := i + 1 end

( · )∗ · · ( · )∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20
slide-18
SLIDE 18

Introduction

Axioms of KA: e + 0 ≡ e e + e ≡ e e + f ≡ f + e e + (f + g) ≡ (e + f) + g e · 0 ≡ 0 ≡ 0 · e e · 1 ≡ e ≡ 1 · e e · (f · g) ≡ (e · f) · g e · (f + g) ≡ e · f + e · g

(e + f) · g ≡ e · g + f · g

1 + e · e∗ ≡ e∗ e · f + g ≦ f =

⇒ e∗ · g ≦ f

1 + e∗ · e ≡ e∗ e · f + g ≦ e =

⇒ g · f ∗ ≦ e

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 6 20
slide-19
SLIDE 19

Introduction

Axioms of KA: e + 0 ≡ e e + e ≡ e e + f ≡ f + e e + (f + g) ≡ (e + f) + g e · 0 ≡ 0 ≡ 0 · e e · 1 ≡ e ≡ 1 · e e · (f · g) ≡ (e · f) · g e · (f + g) ≡ e · f + e · g

(e + f) · g ≡ e · g + f · g

1 + e · e∗ ≡ e∗ e · f + g ≦ f =

⇒ e∗ · g ≦ f

1 + e∗ · e ≡ e∗ e · f + g ≦ e =

⇒ g · f ∗ ≦ e

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 6 20
slide-20
SLIDE 20

Introduction

· ( · )∗ ≡ ( · )∗ ·

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 7 20
slide-21
SLIDE 21

Introduction

Theorem (Kozen 1990)

The axioms for KA are sound & complete for equivalence: e ≡ f ⇐

⇒ L(e) = L(f)

L(e) is the regular language interpretation of e.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 8 20
slide-22
SLIDE 22

Introduction

Theorem (Kozen 1990)

The axioms for KA are sound & complete for equivalence: e ≡ f ⇐

⇒ L(e) = L(f)

L(e) is the regular language interpretation of e.

Upshot: to check KA equivalence is to check regular language equivalence through Kleene’s theorem, this means checking DFA equivalence sophisticated (near-linear) algorithms exist to do this

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 8 20
slide-23
SLIDE 23

Adding concurrency

Which new axioms do we need for parallel composition?

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-24
SLIDE 24

Adding concurrency

Which new axioms do we need for parallel composition? e f ≡ f e

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-25
SLIDE 25

Adding concurrency

Which new axioms do we need for parallel composition? e f ≡ f e e (f g) ≡ (e f) g

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-26
SLIDE 26

Adding concurrency

Which new axioms do we need for parallel composition? e f ≡ f e e (f g) ≡ (e f) g e 1 ≡ e

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-27
SLIDE 27

Adding concurrency

Which new axioms do we need for parallel composition? e f ≡ f e e (f g) ≡ (e f) g e 1 ≡ e e 0 ≡ 0

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-28
SLIDE 28

Adding concurrency

Which new axioms do we need for parallel composition? e f ≡ f e e (f g) ≡ (e f) g e 1 ≡ e e 0 ≡ 0 e (f + g) ≡ e f + e g

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 9 20
slide-29
SLIDE 29

Adding concurrency

g h e f time Thread #2 Thread #1

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-30
SLIDE 30

Adding concurrency

g h e f time Thread #2 Thread #1

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-31
SLIDE 31

Adding concurrency

g h e f time Thread #2 Thread #1

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-32
SLIDE 32

Adding concurrency

g h e f time Thread #2 Thread #1

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-33
SLIDE 33

Adding concurrency

g h e f time Thread #2 Thread #1 Equationally: (e g) · (f h) ≦ (e · f) (g · h).

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-34
SLIDE 34

Adding concurrency

g h e f time Thread #2 Thread #1 Equationally: (e g) · (f h) ≦ p ≦ q ⇐

⇒ p + q ≡ q (e · f) (g · h).

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-35
SLIDE 35

Adding concurrency

g h e f time Thread #2 Thread #1 Equationally: (e g) · (f h) ≦ (e · f) (g · h). Nondeterministic interleaving as special case: e · f + f · e ≦ e f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20
slide-36
SLIDE 36

Adding concurrency

Question

Can we have a regular interpretation − such that e ≡ f ⇐

⇒ e = f?

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 11 20
slide-37
SLIDE 37

Adding concurrency

Question

Can we have a regular interpretation − such that e ≡ f ⇐

⇒ e = f?

NB: − should generalize L(−): for -less terms, L(e) should resemble e.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 11 20
slide-38
SLIDE 38

Regular interpretation: first attempt

Partially ordered multiset (pomset): a · b ∼

= a

b

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 12 20
slide-39
SLIDE 39

Regular interpretation: first attempt

Partially ordered multiset (pomset): a · b ∼

= a

b a b

∼ =

b a

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 12 20
slide-40
SLIDE 40

Regular interpretation: first attempt

Partially ordered multiset (pomset): a · b ∼

= a

b c · (a b)

∼ =

b a c

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 12 20
slide-41
SLIDE 41

Regular interpretation: first attempt

Partially ordered multiset (pomset): a · b ∼

= a

b c · (a b) · d ∼

=

b a c d

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 12 20
slide-42
SLIDE 42

Regular interpretation: first attempt

Partially ordered multiset (pomset): a · b ∼

= a

b c · (a b) · d ∼

=

b a c d Composition lifts to sets of pomsets in the obvious way.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 12 20
slide-43
SLIDE 43

Regular interpretation: first attempt

Straightforward semantics: − : T → 2Pomsets given by

0 = ∅ e + f = e ∪ f e∗ = e ∗ 1 = {1} e · f = e · f a = {a} e f = e f

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 13 20
slide-44
SLIDE 44

Regular interpretation: first attempt

Straightforward semantics: − : T → 2Pomsets given by

0 = ∅ e + f = e ∪ f e∗ = e ∗ 1 = {1} e · f = e · f a = {a} e f = e f

Problem: − is not sound for the exchange law.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 13 20
slide-45
SLIDE 45

Regular interpretation: first attempt

Straightforward semantics: − : T → 2Pomsets given by

0 = ∅ e + f = e ∪ f e∗ = e ∗ 1 = {1} e · f = e · f a = {a} e f = e f

Problem: − is not sound for the exchange law. For instance: a · b ≦ a b should imply that a · b ⊆ a b , but

a · b =

  • a

b

  • a b =
  • a

b

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 13 20
slide-46
SLIDE 46

Regular interpretation: first attempt

Axioms to build ≈ are axioms for ≡, minus exchange law.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 14 20
slide-47
SLIDE 47

Regular interpretation: first attempt

Axioms to build ≈ are axioms for ≡, minus exchange law.

Theorem (Laurence and Struth 2014)

The axioms for ≈ are sound & complete w.r.t. − : e ≈ f ⇐

⇒ e = f

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 14 20
slide-48
SLIDE 48

Regular interpretation: second attempt

We define the subsumption order ⊑ on pomsets. Intuition: U ⊑ V if

i

U and V have the same events, and

ii U has all order in V (and possibly more)

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 15 20
slide-49
SLIDE 49

Regular interpretation: second attempt

We define the subsumption order ⊑ on pomsets. Intuition: U ⊑ V if

i

U and V have the same events, and

ii U has all order in V (and possibly more)

For example: a b ⊑ a b

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 15 20
slide-50
SLIDE 50

Regular interpretation: second attempt

We define the subsumption order ⊑ on pomsets. Intuition: U ⊑ V if

i

U and V have the same events, and

ii U has all order in V (and possibly more)

For example: a b c d

a b c d

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 15 20
slide-51
SLIDE 51

Regular interpretation: second attempt

“Fixed” semantics: e = e ↓ downward closure w.r.t. ⊑ .

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 16 20
slide-52
SLIDE 52

Regular interpretation: second attempt

“Fixed” semantics: e = e ↓. Previous problem no longer occurs:

a · b =

  • a

b

  • a

b , a b , a b

  • = a b
  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 16 20
slide-53
SLIDE 53

Regular interpretation: second attempt

“Fixed” semantics: e = e ↓. Previous problem no longer occurs:

a · b =

  • a

b

  • a

b , a b , a b

  • = a b

Lemma (Hoare et al. 2009)

The axioms for ≡ are sound w.r.t. −, i.e., e ≡ f implies e = f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 16 20
slide-54
SLIDE 54

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-55
SLIDE 55

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-56
SLIDE 56

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

Proof.

If e = f,

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-57
SLIDE 57

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

Proof.

If e = f, then e↓ = f↓ ,

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-58
SLIDE 58

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

Proof.

If e = f, then e↓ = f↓ , thus e↓ ≈ f↓.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-59
SLIDE 59

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

Proof.

If e = f, then e↓ = f↓ , thus e↓ ≈ f↓. Therefore, e↓ ≡ f↓ .

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-60
SLIDE 60

Closure

Definition

Let e ∈ T; a closure of e is a term e↓ such that

1 e↓ ≡ e 2 e = e↓

Lemma (Laurence and Struth 2017)

If closures exist for all terms, then ≡ is complete w.r.t. −, i.e., e = f implies e ≡ f.

Proof.

If e = f, then e↓ = f↓ , thus e↓ ≈ f↓. Therefore, e ≡ e↓ ≡ f↓ ≡ f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 17 20
slide-61
SLIDE 61

Main contribution

Theorem

If e ∈ T, then we can compute a term e↓ that is a closure of e.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 18 20
slide-62
SLIDE 62

Main contribution

Theorem

If e ∈ T, then we can compute a term e↓ that is a closure of e.

Corollary

The axioms for CKA are sound & complete w.r.t. −: e ≡ f ⇐

⇒ e = f

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 18 20
slide-63
SLIDE 63

Main contribution

Theorem

If e ∈ T, then we can compute a term e↓ that is a closure of e.

Corollary

The axioms for CKA are sound & complete w.r.t. −: e ≡ f ⇐

⇒ e = f

The latter can be decided; c.f. [Brunet, Pous, and Struth 2017].

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 18 20
slide-64
SLIDE 64

Further work

Explore coalgebraic perspective:

Efficient equivalence checking through bisimulation? Can completeness be shown coalgebraically?

Add “parallel star” operator — closure method does not apply. Extend Kleene Algebra with Tests (KAT) to add concurrency. Extend extend NetKAT with concurrency.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 19 20
slide-65
SLIDE 65

Thank you for your attention

CoNeCo

Implementation: https://doi.org/10.5281/zenodo.926651. Extended paper: https://arxiv.org/abs/1710.02787.

slide-66
SLIDE 66

Bonus: computing the closure

So, how does one compute a closure?

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 21 20
slide-67
SLIDE 67

Bonus: computing the closure

So, how does one compute a closure?

Lemma

If e, f have closures e↓ and f↓ respectively, then

1 e↓ + f↓ is a closure of e + f 2 e↓ · f↓ is a closure of e · f 3 e↓∗ is a closure of e∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 21 20
slide-68
SLIDE 68

Bonus: computing the closure

So, how does one compute a closure?

Lemma

If e, f have closures e↓ and f↓ respectively, then

1 e↓ + f↓ is a closure of e + f 2 e↓ · f↓ is a closure of e · f 3 e↓∗ is a closure of e∗

One case remains: parallel composition.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 21 20
slide-69
SLIDE 69

Bonus: computing the closure

Sketch: given e f, apply exchange law syntactically, “in the limit”.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 22 20
slide-70
SLIDE 70

Bonus: computing the closure

Sketch: given e f, apply exchange law syntactically, “in the limit”. For instance: if e = a · b and f = c · d:

(a c) · (b d) ≦ e f

(e = a • b, f = c • d)

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 22 20
slide-71
SLIDE 71

Bonus: computing the closure

Sketch: given e f, apply exchange law syntactically, “in the limit”. For instance: if e = a · b and f = c · d:

(a c) · (b d) ≦ e f

(e = a • b, f = c • d)

(a 1) · (b (c · d)) ≦ e f

(e = a • b, f = 1 • c · d)

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 22 20
slide-72
SLIDE 72

Bonus: computing the closure

Sketch: given e f, apply exchange law syntactically, “in the limit”. For instance: if e = a · b and f = c · d:

(a c) · (b d) ≦ e f

(e = a • b, f = c • d)

(a 1) · (b (c · d)) ≦ e f

(e = a • b, f = 1 • c · d)

(1 c) · ((a · b) d) ≦ e f

(e = 1 • a · b, f = c • d) . . .

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 22 20
slide-73
SLIDE 73

Bonus: computing the closure

Sketch: given e f, apply exchange law syntactically, “in the limit”. For instance: if e = a · b and f = c · d:

(a c) · (b d) ≦ e f

(e = a • b, f = c • d)

(a 1) · (b (c · d)) ≦ e f

(e = a • b, f = 1 • c · d)

(1 c) · ((a · b) d) ≦ e f

(e = 1 • a · b, f = c • d) . . . Goal: find enough of these terms to cover all pomsets in e f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 22 20
slide-74
SLIDE 74

Bonus: computing the closure

Obstacles to overcome: How to split terms e and f into heads and tails?

❘ ❘

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 23 20
slide-75
SLIDE 75

Bonus: computing the closure

Obstacles to overcome: How to split terms e and f into heads and tails?

What to do about recursion? For instance,

❘ (e f) · (e∗ f ∗) ≦ e∗ f ∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 23 20
slide-76
SLIDE 76

Bonus: computing the closure

Obstacles to overcome: How to split terms e and f into heads and tails?

❘ splicing relations

What to do about recursion? For instance,

❘ (e f) · (e∗ f ∗) ≦ e∗ f ∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 23 20
slide-77
SLIDE 77

Bonus: computing the closure

Obstacles to overcome: How to split terms e and f into heads and tails?

❘ splicing relations

What to do about recursion? For instance,

❘ fixpoints of inequations (e f) · (e∗ f ∗) ≦ e∗ f ∗

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 23 20
slide-78
SLIDE 78

Bonus: computing the closure

Definition

Let e ∈ T. We define ∇e ⊆ T × T as the smallest relation such that 1 ∇1 1 a ∇a 1 1 ∇a a 1 ∇e∗ 1

ℓ ∇e r ℓ ∇e+f r ℓ ∇e r ℓ ∇e·f r · f ℓ ∇e r ℓ ∇e·f r · f ℓ ∇f r

e · ℓ ∇e·f r

ℓ0 ∇e r0 ℓ1 ∇f r1 ℓ0 ℓ1 ∇ef r0 r1 ℓ ∇e r

e∗ · ℓ ∇e∗ r · e∗

Lemma

Let e ∈ T and U · V ∈ eWCKA; there exist ℓ ∇e r such that U ∈ ℓ and V ∈ r.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 24 20
slide-79
SLIDE 79

Bonus: computing the closure

Suppose that for all g, h ∈ T, we have that Xgh is a closure of g h. Then we find e f +

  • ℓe ∇e re

ℓf ∇f rf

(ℓe ℓf) · (re rf) ≦ Xef

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 25 20
slide-80
SLIDE 80

Bonus: computing the closure

Suppose that for all g, h ∈ T, we have that Xgh is a closure of g h. Then we find e f +

  • ℓe ∇e re

ℓf ∇f rf

(ℓe ℓf) · Xrerf ≦ Xef

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 25 20
slide-81
SLIDE 81

Bonus: computing the closure

Suppose that for all g, h ∈ T, we have that Xgh is a closure of g h. Then we find e f +

  • ℓe ∇e re

ℓf ∇f rf

(ℓe ℓf) · Xrerf ≦ Xef

For Xrerf , we find another inequation, et cetera. . .

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 25 20
slide-82
SLIDE 82

Bonus: computing the closure

Suppose that for all g, h ∈ T, we have that Xgh is a closure of g h. Then we find e f +

  • ℓe ∇e re

ℓf ∇f rf

(ℓe ℓf) · Xrerf ≦ Xef

For Xrerf , we find another inequation, et cetera. . .

Lemma

Continuing this, we get a finite system of inequations M, bef.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 25 20
slide-83
SLIDE 83

Bonus: computing the closure

Theorem

Let e ⊗ f be the least solution to Xef in M,

  • bef. Then the following hold:

1 e ⊗ f ≡ e f 2 e ⊗ f = e f

In other words, e ⊗ f is a closure of e f.

  • T. Kapp´
e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 26 20