Asynchronous ASMs Phase Synchronization on Undirected Trees Egon Börger Dipartimento di Informatica, Universita di Pisa

Slides:



Advertisements
Similar presentations
Chapter 5: Tree Constructions
Advertisements

© Egon Börger: Linked List 1 Double Linked Lists : Desired Operations Define an ASM which offers the following operations, predicates and functions on.
Real-Time Process Control Systems (Real-Time Controller ASM for the Railroad Crossing Case Study) Egon Börger Dipartimento di Informatica, Universita di.
Great Theoretical Ideas in Computer Science for Some.
Impossibility of Distributed Consensus with One Faulty Process
Lecture 7 March 1, 11 discuss HW 2, Problem 3
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
Temporal Logic and the NuSMV Model Checker CS 680 Formal Methods Jeremy Johnson.
Chapter 15 Basic Asynchronous Network Algorithms
Chapter 5 Shortest Paths: Label-Correcting Algorithms
Self Stabilizing Algorithms for Topology Management Presentation: Deniz Çokuslu.
Junction Trees And Belief Propagation. Junction Trees: Motivation What if we want to compute all marginals, not just one? Doing variable elimination for.
Termination Detection of Diffusing Computations Chapter 19 Distributed Algorithms by Nancy Lynch Presented by Jamie Payton Oct. 3, 2003.
Graph Traversals Visit vertices of a graph G to determine some property: Is G connected? Is there a path from vertex a to vertex b? Does G have a cycle?
Graph Traversals Visit vertices of a graph G to determine some property: Is G connected? Is there a path from vertex a to vertex b? Does G have a cycle?
Minimum Spanning Trees
Minimum Spanning Trees
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS Fall 2011 Prof. Jennifer Welch CSCE 668 Self Stabilization 1.
Tirgul 8 Graph algorithms: Strongly connected components.
Lectures on Network Flows
1 Chapter 7 Network Flow Slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved.
Junction Trees: Motivation Standard algorithms (e.g., variable elimination) are inefficient if the undirected graph underlying the Bayes Net contains cycles.
Data Structures, Spring 2004 © L. Joskowicz 1 Data Structures – LECTURE 14 Strongly connected components Definition and motivation Algorithm Chapter 22.5.
1 Maximal Independent Set. 2 Independent Set (IS): In a graph, any set of nodes that are not adjacent.
Asynchronous ASMs Network Leader Election Egon Börger Dipartimento di Informatica, Universita di Pisa
1 Complexity of Network Synchronization Raeda Naamnieh.
Chapter 5 Routing Algorithm in Networks. How are message routed from origin to destination? 1) Circuit-Switching → telephone net. Dedicated bandwidth.
CPSC 668Set 2: Basic Graph Algorithms1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
Asynchronous ASMs Ring Load Balance Egon Börger Dipartimento di Informatica, Universita di Pisa
1 Minimum Spanning Trees Gallagher-Humblet-Spira (GHS) Algorithm.
Asynchronous ASMs Master/Slave Agreement Egon Börger Dipartimento di Informatica, Universita di Pisa
© nCode 2000 Title of Presentation goes here - go to Master Slide to edit - Slide 1 Reliable Communication for Highly Mobile Agents ECE 7995: Term Paper.
CSE 780 Algorithms Advanced Algorithms Graph Alg. DFS Topological sort.
Bakery Algorithm - Proof
CPSC 668Self Stabilization1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
Temporal Logic and Model Checking. Reactive Systems We often classify systems into two types: Transformational: functions from inputs available at the.
© Egon Börger: Daemon Game 1 Daemon Game (Turner 1993) Problem Description Design a system for the following multi-player game: –A Daemon generates Bump.
Tirgul 11 BFS,DFS review Properties Use. Breadth-First-Search(BFS) The BFS algorithm executes a breadth search over the graph. The search starts at a.
Asynchronous Multi-Agent ASMs An Introduction Egon Börger Dipartimento di Informatica, Universita di Pisa
Distributed systems Module 2 -Distributed algorithms Teaching unit 1 – Basic techniques Ernesto Damiani University of Bozen Lesson 4 – Consensus and reliable.
Advanced Topics in Algorithms and Data Structures Page 1 An overview of lecture 3 A simple parallel algorithm for computing parallel prefix. A parallel.
Illustrating Stepwise Refinement Shortest Path ASMs Egon Börger Dipartimento di Informatica, Universita di Pisa
Data Structures, Spring 2006 © L. Joskowicz 1 Data Structures – LECTURE 14 Strongly connected components Definition and motivation Algorithm Chapter 22.5.
Tirgul 7 Review of graphs Graph algorithms: – BFS (next tirgul) – DFS – Properties of DFS – Topological sort.
Message Passing Systems A Formal Model. The System Topology – network (connected undirected graph) Processors (nodes) Communication channels (edges) Algorithm.
Message Passing Systems A Formal Model. The System Topology – network (connected undirected graph) Processors (nodes) Communication channels (edges) Algorithm.
Selected topics in distributed computing Shmuel Zaks
Introduction to ASMs Dumitru Roman Digital Enterprise Research Institute
Distributed Coloring Discrete Mathematics and Algorithms Seminar Melih Onus November
CS4231 Parallel and Distributed Algorithms AY 2006/2007 Semester 2 Lecture 10 Instructor: Haifeng YU.
Asynchronous Multi-Agent ASMs An Introduction Egon Börger Dipartimento di Informatica, Universita di Pisa
DISTRIBUTED SYSTEMS II A POLYNOMIAL LOCAL SOLUTION TO MUTUAL EXCLUSION Prof Philippas Tsigas Distributed Computing and Systems Research Group.
SOFTWARE DESIGN. INTRODUCTION There are 3 distinct types of activities in design 1.External design 2.Architectural design 3.Detailed design Architectural.
1 Leader Election in Rings. 2 A Ring Network Sense of direction left right.
1 Chapter 22: Elementary Graph Algorithms II. 2 About this lecture Depth First Search DFS Tree and DFS Forest Properties of DFS Parenthesis theorem (very.
DISTRIBUTED ALGORITHMS Spring 2014 Prof. Jennifer Welch Set 2: Basic Graph Algorithms 1.
EMIS 8374 Shortest Path Trees Updated 11 February 2008 Slide 1.
Great Theoretical Ideas in Computer Science for Some.
1 Chapter 11 Global Properties (Distributed Termination)
Asynchronous ASMs Echo Algorithm Egon Börger Dipartimento di Informatica, Universita di Pisa
Data Structures and Algorithm Analysis Lecture 5
Breadth-First Search (BFS)
CSC317 Graph algorithms Why bother?
Lectures on Network Flows
Tree Construction (BFS, DFS, MST) Chapter 5
Lectures on Graph Algorithms: searching, testing and sorting
Shortest-Path Property 4.1
Lecture 6 Shortest Path Problem.
Synchronizers Outline motivation principles and definitions
Presentation transcript:

Asynchronous ASMs Phase Synchronization on Undirected Trees Egon Börger Dipartimento di Informatica, Universita di Pisa

© Egon Börger: Phase Synchronization 2 Phase Synchronization : problem statement Goal: Design a distributed algorithm that guarantees synchronized execution of phases of computations, occurring at nodes of an undirected tree (connected acyclic network), using only communication between tree neighbors Algorithmic Idea: every agent (tree node) before becoming busy in a new phase has to –synchronize with its neighbor nodes, moving the synchronization up along the tree structure –wait until all agents are waiting for the phase increase to start –increase its phase - when the phase shift becomes movable down - and move the phase shift further down along the tree structure until all nodes have become busy in the new phase

© Egon Börger: Phase Synchronization 3 Phase Synchronization ASM: Agent Signature Agent : an undirected tree of agents equipped with: –neighb  Agent (external function) –phase: the current phase –synchPartner, waitPartner: Agent yields the neighbor node an agent is synchronized with (in moving the synchronization up or down the tree) resp. waiting for (to reverse the previous upward synchronization downwards) –ctl_state : {busy, waiting } Initially –ctl_state = busy, phase = 0, synchPartner = waitPartner = undef

© Egon Börger: Phase Synchronization 4 busy waiting Synchronization MovableUp MoveSynchronizationUp PhaseShift MovableDown MovePhaseShiftDown SynchronizationMovableUp   y  neighb SynchronizationMovableUpTo(y) for some neighb y all other neighbors synchronize with self in phase(self) MoveSynchronizationUp  choose y  neighb with SynchronizationMovableUpTo(y) synchronize self with y in phase(self) MoveSynchronizationUpTo(y) PhaseShiftMovableDown waitPartner synchronizes with self in phase(self) MovePhaseShiftDown  phase : = phase +1  z  neighb-{waitPartner} self.synchPartner(phase(self)) : = z waitPartner.synchPartner (phase(self)):= undef ASM for Phase Synchronization MoveSynchronizationUpTo(y)   z  neighb-{y} z.synchPartner(phase(self)) := undef SynchronizationMovableUpTo(y)   z  neighb-{y} z.synchPartner(phase(self)) = self self.synchPartner(phase(self)) := y, self.waitPartner(phase(self)) := y

© Egon Börger: Phase Synchronization 5 Phase Synchronization ASM : Correctness & Liveness Proposition: In every infinite distributed run of agents equipped with the ASM for phase synchronization: –in any state any two busy agents are in the same phase (correctness property) –if every enabled agent will eventually make a move, then each agent will eventually reach each phase (liveness property)

© Egon Börger: Phase Synchronization 6 Phase Synch: PhaseShiftMovableDown Lemma Lemma: For every phase p, whenever in a run a state is reached where for the first time u.waitPartner(p)=v synchronizes with u in phase p, every element of subtree(u,v)  subtree(v,u)  {u,v} is waiting in phase p where subtree(x,y) = {n| n reachable by a path from x without touching y}

© Egon Börger: Phase Synchronization 7 Proof of PhaseShiftMovableDown Lemma Proof of the lemma follows from the following two claims. Claim 1. When Synchronization is moved up in phase(u)=p from busy u to to v=u.synchPartner(p), the elements of subtree(u,v) are waiting, u becomes waiting, and they all remain so until the next application of a Shift rule “ MovePhaseShiftDown”. –Claim 1 follows by induction on the applications of the Synchronization rule. n=1: true at the leaves n+1: follows by induction hypothesis and Synchronization rule from subtree(u,v)=  i<n subtree(u i,u)  {u 0,...,u n-1 } for neighb(u}= {u 0,...,u n } with v= u n (by connectedness)

© Egon Börger: Phase Synchronization 8 Proof of PhaseShiftMovableDown Lemma Claim 2. For every infinite run and every phase p, a state is reached in which all agents are waiting in phase p and for some agent u its waitPartner in phase p synchronizes with u in phase p. –Follows by induction on p.

© Egon Börger: Phase Synchronization 9 Reference W.Reisig: Elements of Distributed Algorithms Springer-Verlag 1998 –See Section 36 (in particular Fig. 36.1) and a correctness and liveness proof in Section 81 E. Börger, R. Stärk: Abstract State Machines. A Method for High-Level System Design and Analysis Springer-Verlag 2003, see –See Chapter 6.1