concurrent kleene algebra free model and completeness
play

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


  1. Concurrent Kleene Algebra: Free Model and Completeness Tobias Kapp´ e Paul Brunet Alexandra Silva Fabio Zanasi University College London Leiden, 28 May 2018

  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

  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

  4. Introduction Let’s write a program that outputs n > 0 space-separated � ’s. i := 1 i := 1 while i < n do print � print � while i < n do print print i := i + 1 print � i := i + 1 end print � end T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20

  5. Introduction Let’s write a program that outputs n > 0 space-separated � ’s. i := 1 i := 1 while i < n do print � print � while i < n do print print i := i + 1 print � i := i + 1 end print � end Are these programs equivalent? T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 2 20

  6. Introduction Programs are expressions T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 3 20

  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

  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

  9. Introduction program expression a , b , . . . ∈ Σ atomic action T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  10. Introduction program expression a , b , . . . ∈ Σ atomic action abort execution 0 T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  11. Introduction program expression a , b , . . . ∈ Σ atomic action abort execution 0 no-operation 1 T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  12. Introduction program expression a , b , . . . ∈ Σ atomic action abort execution 0 no-operation 1 e + f nondeterministic choice T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  13. Introduction program expression a , b , . . . ∈ Σ atomic action abort execution 0 no-operation 1 e + f nondeterministic choice sequential composition e · f T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  14. Introduction program expression a , b , . . . ∈ Σ atomic action abort execution 0 no-operation 1 e + f nondeterministic choice sequential composition e · f e ∗ repetition T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 4 20

  15. Introduction i := 1 i := 1 while i < n do print � print � while i < n do print print i := i + 1 print � i := i + 1 end print � end T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20

  16. Introduction i := 1 i := 1 while i < n do print � print � while i < n do ( � · ) ∗ · � print print i := i + 1 print � i := i + 1 end print � end T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20

  17. Introduction i := 1 i := 1 while i < n do print � print � while i < n do ( � · ) ∗ · � � · ( · � ) ∗ print print i := i + 1 print � i := i + 1 end print � end T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 5 20

  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 ∗ · g ≦ f e · f + g ≦ f = 1 + e ∗ · e ≡ e ∗ ⇒ g · f ∗ ≦ e e · f + g ≦ e = T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 6 20

  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 ∗ · g ≦ f e · f + g ≦ f = 1 + e ∗ · e ≡ e ∗ ⇒ g · f ∗ ≦ e e · f + g ≦ e = T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 6 20

  20. Introduction � · ( · � ) ∗ ≡ ( � · ) ∗ · � T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 7 20

  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

  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

  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

  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

  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

  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

  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

  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

  29. Adding concurrency e f Thread #1 g Thread #2 h time T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20

  30. Adding concurrency e f Thread #1 g Thread #2 h time T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20

  31. Adding concurrency e f Thread #1 g Thread #2 h time T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20

  32. Adding concurrency e f Thread #1 g Thread #2 h time T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20

  33. Adding concurrency e f Thread #1 g Thread #2 h time 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

  34. Adding concurrency e f Thread #1 g Thread #2 h time Equationally: ( e � g ) · ( f � h ) ≦ ( e · f ) � ( g · h ) . p ≦ q ⇐ ⇒ p + q ≡ q T. Kapp´ e, P . Brunet, A. Silva, F. Zanasi Concurrent Kleene Algebra: Free Model and Completeness 10 20

  35. Adding concurrency e f Thread #1 g Thread #2 h time 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

  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

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend