This document discusses concurrent processes and reactions. It begins by defining sequential process expressions, labels, and flowgraphs. Labels represent observable actions or interactions between processes, while flowgraphs depict the structure but not dynamics of a system. Reactions represent unobservable interactions between system components. Concurrency process expressions are then introduced, which include summation, composition, and restriction. Structural congruence and standard forms are defined as ways to represent processes. The document concludes by mentioning reaction rules will be covered in the next section.
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Concurrent Processes and Reaction
1. Concurrent Processes and Reaction
John Justine Villar Jhoirene Clemente
January 10, 2013
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 1 / 30
2. Sequential Process Expression
A Process Expression carries information about both the behaviour and the
structure of the system.
Definition 1 (Sequential Process Expression)
The set Pseq of sequential process expressions is defined by the following
syntax: P ::= A < a1 , . . . , an > | i∈I αi .Pi where I is any finite indexing
set. We use P, Q, Pi , . . . to stand for process expressions.
Here are some notations defined in Section 3.
Process identifiers: A, B, . . .
Process with name parameters: A < a, b, c >
We write a to denote a sequence of names a1 , a2 , . . . , an
The notation {b/a}P means replacing ai by bi in P where 1 ≤ i ≤ n.
The notation fn(P) denotes the set of names which occur in a process
expression. (‘fn’ stands for free names)
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 2 / 30
3. Sequential Process Expression
We also assume that every process identifier A has a defining equation of the
form
def
A(a) = PA
where PA is a summation, and the names a = a1 , . . . , an include all the free
names fn(PA ) of PA .
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 3 / 30
4. Labels and Flowgraphs
Outline
1 Labels and Flowgraphs
2 Observation and Reactions
3 Concurrency Process Expressions
4 Structural Congruence
5 Reaction Rules
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 4 / 30
5. Labels and Flowgraphs
Labels and Flowgraphs
Definition 2 (Labels)
Label L is the union of the set of names and co-names.
def ¯
L = N∪N
where N is an infinite set of names,
¯
N is and infinite set of co-names, and
¯
N ∩ N = ∅.
Labels are used in Labelled Transition Systems (LTS).
Labels are used as buttons of black boxes.
We call ¯ the complement of a.
a
As an extension of complementation,
¯ def a
a=
.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 5 / 30
6. Labels and Flowgraphs
Labels and Flowgraphs
Figure: Black box A with buttons a and ¯
b.
Every complementary pair (a, ¯) of labels will represent a means of
a
interaction between black boxes. So if we have another black box B with
buttons b and ¯, we have the following system.
c
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 6 / 30
7. Labels and Flowgraphs
Labels and Flowgraphs
This is an example of a single flowgraph.
Figure: The system containing black box A and B with interaction on the
complementary pair (b, ¯
b).
Definition 3 (Flowgraph)
Flowgraph depicts the structure of a system, i.e. linkage among its
components.
Flowgraphs should not be confused with transition systems.
Flowgraphs do not depict the dynamic property of a system.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 7 / 30
8. Labels and Flowgraphs
Labels and Flowgraphs
Here is another example of a flowgraph
Figure: System containing a scheduler with client processes P1 , . . . , Pn .
Note that each Pi may have many other labelled ports and a port may bear any
number of arcs.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 8 / 30
9. Observation and Reactions
Outline
1 Labels and Flowgraphs
2 Observation and Reactions
3 Concurrency Process Expressions
4 Structural Congruence
5 Reaction Rules
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 9 / 30
10. Observation and Reactions
Observation and Reactions
The complementary label (b, ¯ is not to be thought of as a buffer or channel
b)
having some capacity. It is a means of synchronized action or handshake.
Suppose we think of black boxes A and B as separate sequential processes.
The defining equations are
def
A = a.A
def
A =¯ b.A
def
B = b.B
def
B = ¯.Bc
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 10 / 30
11. Observation and Reactions
Observation and Reactions
The composite system consisting of A and B running concurrently, with no
interdependence except that any action ¯ by A must be synchronized with an
b
action b by B and conversely.
the transition a occurs, leading to states A and B holding simultaneously;
the shared transition occurs, leading to A and B ;
the transitions a and ¯ occur in either order, or simultaneously, leading to
c
A and B again;
and so on.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 11 / 30
12. Observation and Reactions
Observation and Reactions
We shall think of the labels b and ¯ as representing observable actions, or
b
observations.
We observe b by interacting
with it, i.e. by performing
its complement ¯ and conversely.
b,
Observations = Interactions
The shared transition in the figure
above is unobservable; we can think of it as internal action or a reaction.
Definition 4 (Reaction)
Reaction is the interaction (i.e. mutual observation) between two components
of the system, which will be denoted as τ ; being unobservable, it has no
complement.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 12 / 30
13. Observation and Reactions
Observation and Reactions
Definition 5 (Act)
def
Act = L ∪ {τ }
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 13 / 30
14. Concurrency Process Expressions
Outline
1 Labels and Flowgraphs
2 Observation and Reactions
3 Concurrency Process Expressions
4 Structural Congruence
5 Reaction Rules
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 14 / 30
15. Concurrency Process Expressions
Concurrency Process Expressions
Summation
i∈I αi .Pi
Composition
P|Q
Restriction
(new a) P, where a is a bound name and fn(P) is the set of all names
occurring free, or those that are not bound to P.
Definition 6 (Concurrent Process Expression)
The set P of (concurrent) process expressions is defined by the following
syntax:
P := A < a1 , . . . , an > | αi .Pi | P1 |P2 | (new a) P
i∈I
where I is any finite indexing set.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 15 / 30
16. Concurrency Process Expressions
Concurrency Process Expressions
Changing a bound name into a fresh name us called alpha-conversion. Two
terms are structurally congruent if one is derived from the other by
alpha-conversion.
Example:
(new b)a.b = (new b )a.b
Alpha-conversion is also used to perform substitution
Example:
P = (new b)a.b
{b/a}P = (new b )b.b
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 16 / 30
17. Concurrency Process Expressions
Concurrency Process Expressions
To illustrate a reaction,
let P = A |B, where A = ¯ and B = b.B . Thus
b.A
P ≡ ¯ |b.B ,
b.A
so reaction between b and ¯ will occur.
b
We have the reaction
P → A|B
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 17 / 30
18. Concurrency Process Expressions
Concurrency Process Expressions
To illustrate an alternative reaction,
let P = new a ((a.Q1 + b.Q2 )|¯.0) | (¯ 1 + ¯.R2 )
a b.R a
P → new a Q1 |(¯ 1 + ¯.R2 )
b.R a
and
P → new a (Q2 |¯)|R1
a
Note that, a’s in a.Q1 and ¯.R2 are different. Therefore,
a
P new a(Q1 |¯)|R2
a
¯ b.R
P ≡ new a ((a .Q1 + b.Q2 )|a |(¯ 1 + ¯.R2 ))
a
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 18 / 30
19. Concurrency Process Expressions
Concurrency Process Expressions
To illustrate an alternative reaction,
let P = new a ((a.Q1 + b.Q2 )|¯.0) | (¯ 1 + ¯.R2 )
a b.R a
P → new a Q1 |(¯ 1 + ¯.R2 )
b.R a
and
P → new a (Q2 |¯)|R1
a
Note that, a’s in a.Q1 and ¯.R2 are different. Therefore,
a
P new a(Q1 |¯)|R2
a
¯ b.R
P ≡ new a ((a .Q1 + b.Q2 )|a |(¯ 1 + ¯.R2 ))
a
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 18 / 30
20. Structural Congruence
Outline
1 Labels and Flowgraphs
2 Observation and Reactions
3 Concurrency Process Expressions
4 Structural Congruence
5 Reaction Rules
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 19 / 30
21. Structural Congruence
Structural Congruence
Definition 7 (Process Context)
A process context C is, informally speaking, a process expression containing a
hole, represented by [ ]. Formally, process context are given by the syntax
C := [ ] | α.C + M |new a C | C|P | P|C
C[Q] denotes the results of filling the hole in the context C by the process Q.
The elementary contexts are α.[ ] + M, new a [ ], [ ]|P, P|[ ].
Note in particular that C = [ ] is the identify context; in this case C[Q] = Q.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 20 / 30
22. Structural Congruence
Structural Congruence
Definition 8 (Process Congruence)
∼ ∼
Let = be an equivalence relation over P, i.e. it is reflexive (P = P),
∼ ∼ ∼ ∼
symmetric (if P = Q then Q = P) and transitive (if P = Q and Q = R then
∼ ∼
P = R). Then = is said to be a process congruence if it is preserved by all
∼
elementary contexts; that is, if P = Q then
∼
α.P + M = α.Q + M
∼
new a P = new a Q
∼
P|R = Q|R
∼
R|P = R|Q
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 21 / 30
23. Structural Congruence
Structural Congruence
Proposition 4.1
∼
An arbitrary equivalence relation = is a process congruence if and only if ,
for all contexts C,
∼ ∼
P = Q implies C[P] = C[Q].
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 22 / 30
24. Structural Congruence
Structural Congruence
Definition 9 (Structural Congruence)
Structural Congruence, written ≡, is the process congruence over P
determined by the following equations:
1 Change of bound name (alpha-conversion)
2 Reordering of terms in a summation
3 P|0 ≡ P, P|Q ≡ Q|P, P|(Q|R) ≡ (P|Q)|R
4 new a (P|Q) ≡ P|new a Q if a ∈ fn(P)
/
new a 0 ≡ 0, new ab P ≡ new ba P
def
5 A(b) ≡ {b/a}PA if A(a) = PA
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 23 / 30
25. Structural Congruence
Structural Congruence
Definition 10 (Standard Form)
A process expression new a (M1 | . . . |Mn ), where each Mi is a non-empty sum,
is said to be in standard form. (If n = 0 we take M1 | . . . | Mn to mean 0, If a is
empty then there is no restriction.)
Theorem 11
Every process is structurally congruent to a standard form.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 24 / 30
26. Structural Congruence
Structural Congruence
Definition 10 (Standard Form)
A process expression new a (M1 | . . . |Mn ), where each Mi is a non-empty sum,
is said to be in standard form. (If n = 0 we take M1 | . . . | Mn to mean 0, If a is
empty then there is no restriction.)
Theorem 11
Every process is structurally congruent to a standard form.
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 24 / 30
28. Structural Congruence
Structural Congruence
Linking in a more general case
The linking operator can be generalised thus:
def
P Q = new m({m/r}P) | {m/l}Q)
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 26 / 30
29. Reaction Rules
Outline
1 Labels and Flowgraphs
2 Observation and Reactions
3 Concurrency Process Expressions
4 Structural Congruence
5 Reaction Rules
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 27 / 30
30. Reaction Rules
Reaction Rules
REACT Rule
TAU Rule
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 28 / 30
31. Reaction Rules
Reaction Rules
Example 1:
Q = ¯.(b.B|¯
a bC)
Example 2:
a.A|Q
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 29 / 30
32. Reaction Rules
Reaction Rules
Example 3:
P = new a((a.Q1 + b.Q2 )|¯.0)|(¯ 1 + ¯.R2 )
a b.R a
John Justine Villar, Jhoirene Clemente () Concurrent Processes and Reaction January 10, 2013 30 / 30