11
Ping Pong Actors in the ¼ -calculus behavior of threads is defined by parametric equations of process IDs and process terms behavior of threads is defined by parametric equations of process IDs and process terms equations can be (mutually) recursive system is given by a process term referring to the defined process IDs

21
Bound and Free Names Restriction and input prefix bind names in a process term. Occurrences of names in a process term that are not bound are called free. The function fn returns the set of free names of a process term: If fn ( P ) = ; then P is called closed.

22
® -Equivalence We consider process terms P and Q equivalent if they are equal up to consistent renaming of bound names (denoted by P ´ ® Q ) For example: Can we replace x with z ? But we have

24
Labeled Transition System A labeled transition system (LTS) is a tuple M = h S, L, !, I i with S a nonempty set of states L a nonempty set of labels I µ S the set of initial states ! µ S £ L £ S the transition relation For a transition we write

25
Executions and Traces An execution ± of an LTS M = h S, L, !, I i is a sequence of consecutive transitions starting in an initial state s 0 2 I If ± is finite then its final state s f has no outgoing transitions. A trace ¾ is the projection of an execution to its labels We denote by Traces( M ) the set of all traces of M.

26
Semantics of Process Terms The semantics of a process term P is defined operationally by associating a labeled transition system M P with P. M P captures the behavior of P in all possible process contexts. the initial state of M P is P itself the states of M P are process terms describing the continuations of partial executions the transition relation is defined in terms of transition rules that capture synchronization between threads the labels of M P are actions that encode whether a process synchronizes internally or with the environment

27
Structural Congruence The behavior of two ® -equivalent processes P and Q should be indistinguishable, i.e., ´ ® should be a congruence for the transition relation: There are other such structural equivalences. For instance, one would expect that the following processes behave equally: P | Q and Q | P We capture all these cases in a structural congruence relation ´.

34
Free Output Action means P can send the free (i.e., publicly known) name y over x to the environment, resulting in Q Example: note that there is also a silent action possible:

35
Bound Output Action means P can send the bound name y over x to the environment, resulting in Q (i.e., y is leaked to the environment and no longer private to P ) Example: again there is an alternative silent action possible:

40
Ping Pong Actors in the ¼ -calculus Can we express recursive equations in our calculus?

41
Polyadic ¼ -Calculus Multiple names can be communicated in one step

42
Monadic Encoding of Polyadic Calculus We can encode the polyadic calculus in the monadic one using serialization: for some fresh name z Why is the following encoding incorrect?

43
Encoding Recursive Equations Given a recursive definition of a process identifier A and a process term P that uses this definition. We can encode the behavior of A in P as follows: 1.choose a fresh name y not occuring in P or Q 2.let P y and Q y be P and Q, where each occurrence of process identifier A is replaced by 3.replace P by

45
Outlook: Behavioral Equivalence PongTd ( x ) and PingTd ( x ) are ® -equivalent for all names x, so we can safely replace one by the other in any context. Next week: In general, when can we safely replace one process term by another one? They should surely have the same set of traces, but is that enough?