MPRI – Course on Concurrency Lectures 11 and 12 The pi-calculus expressiveness hierarchy Catuscia Palamidessi INRIA Futurs and LIX

Slides:



Advertisements
Similar presentations
Types and Programming Languages Lecture 7 Simon Gay Department of Computing Science University of Glasgow 2006/07.
Advertisements

Tintu David Joy. Agenda Motivation Better Verification Through Symmetry-basic idea Structural Symmetry and Multiprocessor Systems Mur ϕ verification system.
08 April PPS - Groupe de Travail en Concurrence The probabilistic asynchronous -calculus Catuscia Palamidessi, INRIA Futurs, France.
Paris, 3 Dec 2007MPRI Course on Concurrency MPRI – Course on Concurrency Lecture 12 Probabilistic process calculi Catuscia Palamidessi LIX, Ecole Polytechnique.
Giving a formal meaning to “Specialization” In these note we try to give a formal meaning to specifications, implementations, their comparisons. We define.
Programming Paradigms for Concurrency Lecture 11 Part III – Message Passing Concurrency TexPoint fonts used in EMF. Read the TexPoint manual before you.
01/05/2015 Agay Spring School, March'02 Mobility 1 : the Pi Calculus Cédric Fournet Microsoft Research Cambridge.
Outline. Theorem For the two processor network, Bit C(Leader) = Bit C(MaxF) = 2[log 2 ((M + 2)/3.5)] and Bit C t (Leader) = Bit C t (MaxF) = 2[log 2 ((M.
Behavioral Equivalence Hossein Hojjat Formal Lab University of Tehran.
Probabilistic Methods in Concurrency Lecture 9 Other uses of randomization: a randomized protocol for anonymity Catuscia Palamidessi
Bangalore, 2 Feb 2005Probabilistic security protocols 1 CIMPA School on Security Specification and verification of randomized security protocols Lecture.
Probabilistic Methods in Concurrency Lecture 3 The pi-calculus hierarchy: separation results Catuscia Palamidessi
Byzantine Generals Problem: Solution using signed messages.
Induction and recursion
Math 3121 Abstract Algebra I
Course on Probabilistic Methods in Concurrency (Concurrent Languages for Probabilistic Asynchronous Communication) Lecture 1 The pi-calculus and the asynchronous.
A Semantic Characterization of Unbounded-Nondeterministic Abstract State Machines Andreas Glausch and Wolfgang Reisig 1.
1 Introduction to Computability Theory Lecture12: Reductions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture4: Regular Expressions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture11: Variants of Turing Machines Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture13: Mapping Reductions Prof. Amos Israeli.
Department of mathematics and computer science 1 of 21 Rob van Glabbeek (Sydney) Marc Voorhoeve (TUE) Liveness, Fairness and Impossible Futures.
Lecture 9 Recursive and r.e. language classes
1 Module 9 Recursive and r.e. language classes –representing solvable and half-solvable problems Proofs of closure properties –for the set of recursive.
Lecture 8 Recursively enumerable (r.e.) languages
CPSC 668Set 3: Leader Election in Rings1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
A denotational framework for comparing models of computation Daniele Gasperini.
Induction Sections 4.1 and 4.2 of Rosen Fall 2010
CS294, YelickSelf Stabilizing, p1 CS Self-Stabilizing Systems
1 Ivan Lanese Computer Science Department University of Bologna Italy On the expressive power of primitives for compensation handling Joint work with Catia.
Prof. Diletta Romana Cacciagrano.  From sequential over concurrent to mobile systems  Introduction to the Pi-Calculus  Operational Equivalences based.
Selected topics in distributed computing Shmuel Zaks
Lecture #12 Distributed Algorithms (I) CS492 Special Topics in Computer Science: Distributed Algorithms and Systems.
MATH 224 – Discrete Mathematics
Probabilistic Methods in Concurrency Lecture 4 Problems in distributed systems for which only randomized solutions exist Catuscia Palamidessi
11 February CdP INRIA Futurs Catuscia Palamidessi INRIA Saclay.
SDS Foil no 1 Process Algebra Process Algebra – calculating with behaviours.
10 December 2002ENS Cachan1 Generalized dining philosophers Catuscia Palamidessi, INRIA in collaboration with Mihaela Oltea Herescu, IBM Michael Pilquist,
Review for Exam 2. Topics included Deadlock detection Resource and communication deadlock Graph algorithms: Routing, spanning tree, MST, leader election.
2G1516 Formal Methods2005 Mads Dam IMIT, KTH 1 CCS: Operational Semantics And Process Algebra Mads Dam Reading: Peled 8.3, 8.4, 8.6 – rest of ch. 8.
Logic CL4 Episode 16 0 The language of CL4 The rules of CL4 CL4 as a conservative extension of classical logic The soundness and completeness of CL4 The.
College Algebra Sixth Edition James Stewart Lothar Redlin Saleem Watson.
CS4231 Parallel and Distributed Algorithms AY 2006/2007 Semester 2 Lecture 8 Instructor: Haifeng YU.
MPRI – Course on Concurrency Probabilistic methods in Concurrency Catuscia Palamidessi INRIA Futurs and LIX
Reading and Writing Mathematical Proofs Spring 2015 Lecture 4: Beyond Basic Induction.
In section 11.9, we were able to find power series representations for a certain restricted class of functions. Here, we investigate more general problems.
11/19/20151 Metodi formali nello sviluppo software a.a.2013/2014 Prof.Anna Labella.
Probabilistic Anonymity Mohit Bhargava, IIT New Delhi Catuscia Palamidessi, INRIA Futurs & LIX.
Paris, 17 December 2007MPRI Course on Concurrency MPRI – Course on Concurrency Lecture 14 Application of probabilistic process calculi to security Catuscia.
MPRI 3 Dec 2007Catuscia Palamidessi 1 Why Probability and Nondeterminism? Concurrency Theory Nondeterminism –Scheduling within parallel composition –Unknown.
Lecture 5 1 CSP tools for verification of Sec Prot Overview of the lecture The Casper interface Refinement checking and FDR Model checking Theorem proving.
2G1516 Formal Methods2005 Mads Dam IMIT, KTH 1 CCS: Processes and Equivalences Mads Dam Reading: Peled 8.5.
14 October BASICS'09, Shanghai On the expressive power of synchronization primitives in the π-calculus Catuscia Palamidessi, INRIA Saclay, France.
Concurrency 5 The theory of CCS Specifications and Verification Expressive Power Catuscia Palamidessi
Agreement in Distributed Systems n definition of agreement problems n impossibility of consensus with a single crash n solvable problems u consensus with.
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS Spring 2014 Prof. Jennifer Welch CSCE 668 Set 3: Leader Election in Rings 1.
1 Fault tolerance in distributed systems n Motivation n robust and stabilizing algorithms n failure models n robust algorithms u decision problems u impossibility.
Failure Detectors n motivation n failure detector properties n failure detector classes u detector reduction u equivalence between classes n consensus.
Chapter 5. Section 5.1 Climbing an Infinite Ladder Suppose we have an infinite ladder: 1.We can reach the first rung of the ladder. 2.If we can reach.
6 October PPDP / GPCE 2002 Mobile Calculi Catuscia Palamidessi, INRIA Futurs, France joint work with Mihaela Herescu, IBM, Austin for Distributed.
Process Algebra (2IF45) Basic Process Algebra Dr. Suzana Andova.
16 January 2004LIX1 Equipe Comète Concurrency, Mobility, and Transactions Catuscia Palamidessi INRIA-Futurs and LIX.
Catuscia Palamidessi, INRIA Saclay, France
Induction and recursion
Distributed Consensus
Induction and recursion
Probabilistic Methods in Concurrency Lecture 7 The probabilistic asynchronous p-calculus Catuscia Palamidessi
Locality In Distributed Graph Algorithms
Expressive Power of CCS
Presentation transcript:

MPRI – Course on Concurrency Lectures 11 and 12 The pi-calculus expressiveness hierarchy Catuscia Palamidessi INRIA Futurs and LIX Page of the course:

Paris, 16 December 2004MPRI Course on Concurrency2 Content of the slides / Plan of the lecture Discussion on the notion of expressiveness – encoding Encoding some of the features of the synchronous  -calculus into the asynchronous  -calculus –Output prefix –Blind choice –Input-guarded choice Separation results –Impossibility of encoding the  -calculus with mixed guarded choice into the asynchronous  -calculus –Impossibility of encoding the  -calculus with mixed guarded choice into ccs Bibliography Exercises

Paris, 16 December 2004MPRI Course on Concurrency3 The asynchronous  -calculus: syntax It differs from the  -calculus for the absence of the output prefix (replaced by output action) and also for the absence of the + action prefixes (input, silent) x, y are channel names inaction prefix output action parallel restriction, new name replication

Paris, 16 December 2004MPRI Course on Concurrency4 The  -calculus: syntax Similar to CCS with value passing, but values are channel names, and recursion is replaced by replication ( ! ) action prefixes (input, output, silent) x, y are channel names inaction prefix parallel sum restriction, new name replication

Paris, 16 December 2004MPRI Course on Concurrency5 Expressive power of  a wrt  Clearly the (synchronous)  calculus is at least as expressive as the asynchronous  calculus. In fact, the latter is practically a subset of the former. Indeed, the output action can be seen as the output-prefix process with continuation 0. This relation is a strong bisimulation: What about the opposite direction? In general, in order to compare the expressive power of two languages, we look for the existence/non existence of an encoding with certain properties among these languages What is a good notion of encoding to be used as a basis to measure the relative expressive power?

Paris, 16 December 2004MPRI Course on Concurrency6 A “good” notion of encoding In general we would be happy with an encoding being: –Compositional wrt the operators –(Preferably) homomorphic wrt | (distribution-preserving) –Preserving some kind of semantics. Here there are several possibilities Preserving observables Preserving equivalence This is one of the most popular requirements for an encoding. However it is not clear how it relates to the notion of expressive power. (Preferably) the encoding should not introduce divergences, in the sense that if in the original process all the computations converge, then the same holds for its translation. Note that weak bisimulations are insensitive wrt divergences

Paris, 16 December 2004MPRI Course on Concurrency7 Encoding the output prefix The encoding of Boudol Boudol [1992] provided the following encoding of  (without choice) into  a. : The idea is to force both partners to proceed only when it is sure that the communication can take place, by using a sort of rendez-vous protocol Boudol proved this encoding sound wrt the Morris ordering Exercise. Define an encoding which takes only two steps instead than three. (Such a kind of encoding was defined by Honda-Tokoro [1992].)

Paris, 16 December 2004MPRI Course on Concurrency8 Encoding the output prefix The encoding of Honda-Tokoro Honda-Tokoro [1992] defined the following encoding of  (without choice) into  a. in which the communication protocol takes two steps instead than three. The idea is to let the receiver take the initiative (instead than the sender) Honda proved this encoding sound and “almost” complete wrt a certain logical semantics Honda-Tokoro defined also another encoding of  (without choice) into a polyadic version of  a. in which the communication protocol takes two steps and the sender takes the initiative. This encoding was shown in Lecture 7.

Paris, 16 December 2004MPRI Course on Concurrency9 Properties of output encodings wrt testing Definition of testing semantics: –A process P may satisfy a test T (notation P may T) iff there exists a computation of [ P |T ] which reaches a state where the action  (a special action of the test) is enabled. –A process P must satisfy a test T (notation P must T) iff every computation of [ P |T ] reaches a state where the action  (a special action of the test) is enabled. –P ⊑ may Q iff for every test T, if P may T then Q may T –P ⊑ must Q iff for every test T, if P must T then Q must T –P ≃ x Q iff P ⊑ X Q and Q ⊑ X P, X = may, must In contrast to weak bisimulation, testing semantics is sensitive wrt divergency We don’t expect the encodings of output prefix to be correct wrt testing semantics (why?), but we would like the encoding to satisfy at least the following properties :

Paris, 16 December 2004MPRI Course on Concurrency10 Properties of output encodings wrt testing The encodings of Boudol and Honda-Tokoro –Verify –Do not verify (they preserve may testing but not must testing) Theorem [Cacciagrano, Corradini and Palamidessi, 2004] Let [[ ]] be an encoding of  (without choice) into  a such that: –[[ ]] is compositional wrt the prefixes –There exists a P such that [[ P ]] diverges then [[ ]] does not preserve must testing The problem however is uniquely a problem of fairness: Theorem [Cacciagrano, Corradini and Palamidessi, 2004] The encodings of Boudol and Honda-Tokoro A) preserve must testing if we restrict to fair computations only B) preserve a version of must testing called “fair must testing”

Paris, 16 December 2004MPRI Course on Concurrency11 Encoding internal choice in  a The blind choice (or internal choice) construct has the following semantics In  this operator can be represented by the construct Exercise: Let  - be  without the + operator, and  © be  where the + operator can only occur in the context of (a construct representing) a blind choice. Give an encoding

Paris, 16 December 2004MPRI Course on Concurrency12 Encoding input-guarded choice in  a Input-guarded choice is a construct of the form: Let  ic be  where + can only occur in an input-guarded choice. The following encoding of  ic into  a was defined by Nestmann and Pierce [1996] Nestmann and Pierce proved that his encoding is fully abstract wrt a notion of equivalence called coupled bisimulation, and it does not introduce divergences.

Paris, 16 December 2004MPRI Course on Concurrency13 aa  ic  op ss  II ccs vp  op Honda-Tokoro Boudol Nestmann-Pierce Nestmann  a : asynchronous   ic : asynchronous  + input-guarded choice  op : asynchronous  + output prefix  s : asynchronous  + separate choice  I :  with internal choice (Sangiorgi) ccs vp : value-passing ccs : Language inclusion : Encoding : Non-encoding The  -calculus hierarchy Palamidessi

Paris, 16 December 2004MPRI Course on Concurrency14 The separation between  and  s This separation result is based on the fact that it is not possible to solve the symmetric leader election problem in  s, while it is possible in  Some definitions: –Leader Election Problem (LEP): All the nodes of a distributed system must agree on who is the leader. This means that in every possible computation, all the nodes must eventually output the name of the leader on a special channel out No deadlock No livelock No conflict (only one leader must be elected, every process outputs its name and only its name) –Symmetric LEP: the LEP on a symmetric network Hypergraphs and hypergraph associated to a network Hypergraph automorphism Orbits, well-balanced automorphism Examples Symmetry

Paris, 16 December 2004MPRI Course on Concurrency15 The separation between  and  s Theorem: If a network with at last two nodes has an automorphism   id with only one orbit, then it is not possible to write in  s a symmetric solution to the LEP Corollary: The same holds if the authomorphism is well- balanced Proof (sketch). We prove that in  s every system trying to solve the electoral problem has at least one diverging computation 1.If the system is symmetric, then the first action cannot be 2.As soon as a process perform an action, let all the other processes in the same orbit perform the same action as well. At the end of the round in the orbit, the system is again symmetric. Note that the system can change communication structure dynamically

Paris, 16 December 2004MPRI Course on Concurrency16 The separation between  and  s Crucial point: if the action performed by P i is a communication with P j in the same orbit, we need to ensure that P j can do the same action afterwards. This property holds in fact, due to the following: Lemma: Diamond lemma for  s Note that in  (in  with mixed choice)  the diamond lemma does not hold

Paris, 16 December 2004MPRI Course on Concurrency17 The separation between  and  s Remark: In  (in  with mixed choice) we can easily write a symmetric solution for the LEP in a network of two nodes: P0P0P0P0 P1P1 y x

Paris, 16 December 2004MPRI Course on Concurrency18 The separation between  and  s Corollary: there does not exists an encoding of  (  with mixed choice) in  s which is homomorphic wrt | and renaming, and preserves the observables on every computation. Proof (scketch): An encoding homomorphic wrt | and renaming transforms a symmetric solutions to the LEP in the source language into a symmetric solution to the LEP in the target language

Paris, 16 December 2004MPRI Course on Concurrency19 The separation between  and  I, ccs vp Theorem: If a network with at least two nodes has a well- balanced automorphism   id such that –  i and  node P, if  i  id then there is no arc between P and  i (P), then in  I and ccs vp there is no symmetric solution to the LEP. Example: a network which satisfies the above condition

Paris, 16 December 2004MPRI Course on Concurrency20 The separation between  and  I, ccs vp A solution to the leader election problem for the same network in  winner looser

Paris, 16 December 2004MPRI Course on Concurrency21 The separation between  and  I, ccs vp Corollary: there does not exists an encoding of  (  with mixed choice) in  s which is homomorphic wrt | and renaming, does not increase the connectivity, and preserves the observables on every computation.

Paris, 16 December 2004MPRI Course on Concurrency22 Bibliography Encodings of the output prefix and of the blind choice Kohei Honda and Mario Tokoro, An Object Calculus for Asynchronous Communication. Proc. of ECOOP'91, LNCS 512, pp , Springer-Verlag, 1991 (Lecture 2). Object Calculus for Asynchronous Communication Encodings of the input guarded choice Uwe NestmannUwe Nestmann and Benjamin Pierce Uwe Nestmann and Benjamin Pierce, Decoding Choice Encodings. Journal of Information & Computation 163(1): 1-59, 2000.Benjamin Pierce Uwe NestmannBenjamin Pierce impossibility results shown in these slides Catuscia Palamidessi. Comparing the Expressive Power of the Synchronous and the Asynchronous  -calculus. Mathematical Structures in Computer Science, 13(5): , Catuscia Palamidessi

Paris, 16 December 2004MPRI Course on Concurrency23 Exercises Prove the first Theorem at Page 10 Formulate a notion of fair testing semantics and prove the second Theorem at Page 10 Consider the result of Nestmann and Pierce, at Page 12. Would that still hold if we replace coupled bisimulation by weak bisimulation? Motivate your answer Give a ring with four symmetric processes, write a program for them in the  -calculus solving the leader election problem. Given a ring four symmetric processes, write a program for them in the  -calculus which makes the graph fully connected Generalize previous exercise to the case of n arbitrary nodes