Synchronization Algebras with Mobility for Graph Transformations - PowerPoint PPT Presentation

About This Presentation
Title:

Synchronization Algebras with Mobility for Graph Transformations

Description:

Set of rules for composing productions ... merge of parameters. Synchronizing two outputs: the one with lowest priority is discarded ... – PowerPoint PPT presentation

Number of Views:40
Avg rating:3.0/5.0
Slides: 56
Provided by: rb790
Category:

less

Transcript and Presenter's Notes

Title: Synchronization Algebras with Mobility for Graph Transformations


1
Synchronization Algebras with Mobility for Graph
Transformations
FGUC 2004, London, 3-4 September 2004
Ivan Lanese Dipartimento di Informatica
Università di Pisa
joint work with Ugo Montanari Dipartimento di
Informatica Università di Pisa
2
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

3
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

4
How to model systems (I)
  • Systems are not built directly over the assembler
    language and the hardware functionalities
  • infrastructure makes some primitives available
  • TCP/IP, RPC, Bluetooth
  • systems are built on top of these primitives
  • To model systems we need
  • to model the primitives of the infrastructure
  • to model systems using these primitives

5
How to model systems (II)
  • To model infrastructure
  • synchronization algebras
  • extended with mobility and local resources
  • To model systems
  • graph transformations
  • we use the Synchronized Hyperedge Replacement
    (SHR) approach

6
Why graphs?
  • Are a natural model for distributed systems
  • Represent the spatial structure
  • Suggestive visual representation
  • Sound mathematical foundations
  • Are a concurrent model
  • Graph transformations model system computation
    and reconfiguration

7
Which graphs?
  • We use hypergraphs with labeled (hyper)edges
  • Subset of nodes (free nodes) as interface
  • important for compositionality
  • Computational interpretation
  • edges are processes or systems
  • nodes are links or ports
  • synchronization is performed via shared nodes

8
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

9
The Synchronized Hyperedge Replacement approach
  • An approach to graph transformation aimed at
    modeling distributed systems
  • productions with local effects
  • composition via synchronization with mobility
  • Implementable in a distributed setting since
  • applying a production is a local operation
  • synchronization can be performed using a
    distributed algorithm

10
SHR a 2 step approach
  • Productions to describe the behaviour of single
    hyperedges
  • Hyperedges rewritten into generic graphs
  • Constraints on surrounding nodes
  • Global constraint-solving algorithm to derive
    transitions
  • To select which productions can be applied
  • Allows to define complex transformations

11
Edge Replacement Systems
  • A production describes how the hyperedge L is
    transformed into the graph R

12
Edge Replacement Systems
  • A production describes how the hyperedge L is
    transformed into the graph R

Many productions can be applied concurrently
13
Synchronized Hyperedge Replacement
  • We associate actions to nodes attached to edges
    to be rewritten
  • A transition is allowed iff the synchronization
    constraints associated to nodes are satisfied
  • Many synchronization models are possible (Milner,
    Hoare, ...)

14
An example Hoare synchronization
  • All the edges attached to a node must do the same
    action

a
?
A2
A2
15
SHR with mobility
  • We introduce name mobility
  • Actions carry tuples of references to nodes (new
    or already existent)
  • References associated to synchronized actions are
    matched and corresponding nodes are merged

altx1gtaltx2gt
altxgt
A1
A1
?
x
x1x2
A2
A2
16
The replicating net
  • Requires the same action on all external nodes
  • Creates a copy of itself for each parameter of
    the action

17
The replicating net in action
R
R
R
18
The replicating net in action
R
R
R
R
R
R
19
An algebraic presentation
  • We use judgements to represent graphs
  • To simplify the definition of the semantics
  • G G where G is a finite set of nodes and G is a
    term generated by
  • G nil s(x1,,xn) GG ?x G
  • s is an edge label, x and x1,,xn are nodes
  • ? is a binder for x
  • We require that G contains at least names in fn(G)

?
20
Example ring
21
Transitions as syntactic judgements
  • Transitions
  • ? ? ? (Act x N)
  • Associates to each external node its action and
    its tuple of references to nodes
  • ? ??? is an idempotent substitution (forces
    merges on nodes)

22
Deriving transitions
  • Productions
  • Transitions are generated from productions by
    applying a suitable set of inference rules
  • Inference rules are parametric w.r.t. the
    synchronization model, which is expressed by an
    algebra

?,?
x1,,xn L(x1,,xn) ?? ? G
?
?
23
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

24
Synchronization Algebra with Mobility
  • A tuple ltAct,,e,Init,Fin,Mobgt
  • Act ranked set of actions
  • partial function Act x Act-gtAct
  • e element of Act
  • Init subset of Act
  • Fin subset of Act
  • Mob set of mobility patterns

25
Synchronization Algebra with Mobility
  • A tuple ltAct,,e,Init,Fin,Mobgt
  • Act ranked set of actions
  • partial function Act x Act-gtAct
  • Defines action composition
  • Undefined if the actions can not synchronize
  • Returns the composed action otherwise
  • e element of Act
  • Init subset of Act
  • Fin subset of Act
  • Mob set of mobility patterns

26
Synchronization Algebra with Mobility
  • A tuple ltAct,,e,Init,Fin,Mobgt
  • Act ranked set of actions
  • partial function Act x Act-gtAct
  • e element of Act
  • corresponds to no synchronization
  • Init subset of Act
  • Fin subset of Act
  • Mob set of mobility patterns

27
Synchronization Algebra with Mobility
  • A tuple ltAct,,e,Init,Fin,Mobgt
  • Act ranked set of actions
  • partial function Act x Act-gtAct
  • e element of Act
  • Init subset of Act
  • contains trivial actions that can be produced on
    isolated nodes
  • Fin subset of Act
  • Mob set of mobility patterns

28
Synchronization Algebra with Mobility
  • A tuple ltAct,,e,Init,Fin,Mobgt
  • Act ranked set of actions
  • partial function Act x Act-gtAct
  • e element of Act
  • Init subset of Act
  • Fin subset of Act
  • contains actions that correspond to completed
    synchronizations (only actions in Fin are allowed
    on hidden nodes)
  • Mob set of mobility patterns

29
What is a mobility pattern
c
a
b


30
Example Hoare synchronization
31
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

32
Parametric inference rules
  • Set of rules for composing productions
  • Rules that allow to derive transitions for each
    graph starting from productions
  • disjoint union
  • merging of nodes ? synchronization
  • adding a new node
  • hiding a node

33
The rule for synchronization
34
What we have obtained?
  • Make the dimensions of infrastructure modelling
    and system modelling orthogonal
  • Unify different existing models from SHR
    literature
  • Hoare and Milner synchronizations
  • Allow to model more complex primitives as
    required in global computing systems

35
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

36
Priority communication
37
Priority communication mobility
  • Synchronizing input and output
  • merge of parameters
  • Synchronizing two outputs
  • the one with lowest priority is discarded

n lt m
38
The Game of Life
  • A cellular automata a grid of interconnected
    cells that can be alive or not (empty)
  • A living cell stays alive if it has 2 or 3 alive
    neighbours, dies otherwise
  • A dead cell becomes alive if it has 3 alive
    neighbours

39
Modelling the Game of Life
  • Edges with labels A (alive) and E (empty)
  • Edges share an hidden node with each neighbour
  • At each step a node must communicate its state
    and get the state of the neighbours
  • Action (a,e) Im alive, I argue you are empty
  • Sinchronizations such as (a,e)(e,a)ok
  • ok is the only non trivial final action
  • No mobility

40
Life productions
?
  • A production for each guess on the states of
    neighbours

41
Life
(w,w)
(b,w)
(b,w)
(w,b)
(w,b)
(w,w)
(w,b)
(w,w)
(b,w)
(w,w)
(w,b)
(w,b)
(w,w)
(w,w)
(b,w)
(b,w)
42
Life
(b,w)
(b,w)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
ok
(b,b)
ok
ok
(b,b)
(b,b)
ok
ok
ok
ok
ok
ok
ok
ok
(b,b)
ok
(b,b)
ok
(b,w)
(b,b)
ok
ok
ok
(b,b)
(b,b)
ok
ok
ok
ok
ok
ok
ok
(b,b)
ok
ok
ok
(b,b)
(b,b)
(b,b)
ok
ok
ok
(b,w)
(b,w)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
(b,b)
43
Life
44
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

45
Mapping Fusion Calculus into SHR
  • SHR is expressive enough to model Fusion Calculus
    processes
  • Fusion Calculus can be (easily) mapped into SHR
    with Milner synchronization
  • We will not present the mapping in detail
  • The induced semantics is
  • correct transitions are preserved
  • concurrent SHR transitions correspond to sets of
    indipendent Fusion transitions

46
Fusion Calculus vs Milner SHR
  • Fusion Milner SHR
  • Processes Graphs
  • Sequential processes Hyperedges
  • Names Nodes
  • Parallel comp. Parallel comp.
  • Scope Restriction
  • Sets of indip. transit. Transitions

47
Milner synchronization model
48
Example
49
Changing the synchronization model
  • Lets choose the broadcast synchronization model
    ? create a broadcast Fusion calculus

50
Example
51
Roadmap
  • Introduction
  • Background Synchronized Hyperedge Replacement
  • Synchronization algebras with mobility
  • Parametric inference rules
  • Examples
  • An application to Fusion Calculus
  • Conclusion and future work

52
Conclusions
  • We have extended a known approach to graph
    transformations by making it parametric w.r.t.
    the synchronization model
  • We have presented some possible applications
  • We have mapped Fusion Calculus into SHR
  • We have derived for free a broadcast Fusion
    calculus

53
Future work
  • Define and study an abstract semantics
  • Which equivalence is induced on Fusion processes?
  • Consider nodes with different synchronization
    models in the same graph
  • Apply synchronization algebras with mobility to
    other formalisms
  • Apply SHR to bigraphs?
  • Implementation

54
Questions?
55
Bibliography (1)
  • For Synchronized Hyperedge Replacement
  • P. Degano and U. Montanari. A model for
    distributed systems based on graph rewriting.
    Journal of ACM 34(2), 1987
  • D. Hirsch and U. Montanari. Synchronized
    hyperedge replacement with name mobility. Proc.
    of CONCUR 2001, LNCS, 2001
  • G. Ferrari, U. Montanari and E. Tuosto. A lts
    semantics of ambients via graph synchronization
    with mobility. Proc. of ICTCS01, LNCS 2202, 2001
  • For synchronization algebras
  • G. Winskel. Event structures. LNCS 255, 1986
  • For Fusion Calculus vs SHR
  • I. Lanese and U. Montanari. A graphical Fusion
    Calculus. Proc. of CoMeta final workshop, ENTCS,
    to appear
Write a Comment
User Comments (0)
About PowerShow.com