Verifying Dijktra’s algorithm in Jahob

Slides:



Advertisements
Similar presentations
1 Chapter 6 Dynamic Programming Slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved.
Advertisements

4/12/2015© 2009 Raymond P. Jefferis IIILect Internet Protocol - Continued.
§3 Shortest Path Algorithms Given a digraph G = ( V, E ), and a cost function c( e ) for e  E( G ). The length of a path P from source to destination.
Graphs: MSTs and Shortest Paths David Kauchak cs161 Summer 2009.
Shortest path algorithm. Introduction 4 The graphs we have seen so far have edges that are unweighted. 4 Many graph situations involve weighted edges.
1 TCOM 799: Algorithms in Networking Instructor: Saswati Sarkar Contact Info: (Phone) Office Hours: 2-4 p.m. 360 MB Course.
Dijkstra’s Shortest Paths CS 312 Lecture 4. Announcements Project 1 comes out Friday –Min spanning trees and scheduling –due 2 weeks from Friday (1 week.
1 Shortest Path Algorithms. 2 Routing Algorithms Shortest path routing What is a shortest path? –Minimum number of hops? –Minimum distance? There is a.
Using Dijkstra’s Algorithm to Find a Shortest Path from a to z 1.
Chapter 9 – Graphs A graph G=(V,E) – vertices and edges
Dijkstras Algorithm Named after its discoverer, Dutch computer scientist Edsger Dijkstra, is an algorithm that solves the single-source shortest path problem.
Review: routing algorithms. –Choose the appropriate paths. –Routing algorithms Flooding Shortest path routing (example). –Dijkstra algorithm. –Bellman-Ford.
WAN technologies and routing Packet switches and store and forward Hierarchical addresses, routing and routing tables Routing table computation Example.
1 Week 5 Lecture 2 IP Layer. 2 Network layer functions transport packet from sending to receiving hosts transport packet from sending to receiving hosts.
Lecture 23 CSE 331 Oct 24, Reminder 2 points for Piazza participation 3 points for mini-project.
E E Module 5 © Wayne D. Grover 2002, (for non-negative edge weights only) Key concepts: “labelling”, “scanning” Label = {distance, predecessor}.
Decision Maths 1 Shortest path algorithm Dijkstra’s Algorithm A V Ali :
Dijkstra animation. Dijksta’s Algorithm (Shortest Path Between 2 Nodes) 2 Phases:initialization;iteration Initialization: 1. Included:(Boolean) 2. Distance:(Weight)
Distance Vector and Link State Routing Pragyaditya Das.
Graph Algorithms Mathematical Structures for Computer Science Chapter 6 Copyright © 2006 W.H. Freeman & Co.MSCS SlidesGraph Algorithms.
Graphs – Part III CS 367 – Introduction to Data Structures.
1 Relates to Lab 4. This module covers link state routing and the Open Shortest Path First (OSPF) routing protocol. Dynamic Routing Protocols II OSPF.
The network layer: routing
All-pairs Shortest paths Transitive Closure
Shortest Paths.
Routing Jennifer Rexford.
Depth First Seach: Output Fix
Shortest Paths and Minimum Spanning Trees
Single-Source Shortest Path
Single-Source Shortest Paths
Distance Vector Routing
Intra-Domain Routing Jacob Strauss September 14, 2006.
Routing: Distance Vector Algorithm
Lecture 23 CSE 331 Oct 26, 2016.
Shortest Path Problems
Shortest Path Graph represents highway system Edges have weights
Graphs & Graph Algorithms 2
Greedy Algorithms / Dijkstra’s Algorithm Yin Tat Lee
Chapter 6 Dynamic Programming
Shortest Paths.
CS 3700 Networks and Distributed Systems
Dijkstra’s Algorithm for the Shortest Path Problem
4.4 Shortest Paths in a Graph
A* Path Finding Ref: A-star tutorial.
CSE 373: Data Structures and Algorithms
Lecture 24 CSE 331 Oct 25, 2013.
Chapter 6 Dynamic Programming
Lecture 23 CSE 331 Oct 25, 2017.
Lecture 23 CSE 331 Oct 24, 2011.
Shortest Path Problems
Chapter 6 Dynamic Programming
CS 3700 Networks and Distributed Systems
Shortest Path Algorithms
Minimum Spanning Tree Algorithms
Shortest Paths and Minimum Spanning Trees
CSE332: Data Abstractions Lecture 18: Minimum Spanning Trees
Slide Courtesy: Uwash, UT
Advanced Computer Networks
Shortest Path Algorithm for Weighted Non-negative Undirected Graphs
Shortest Path Problems
Shortest Paths.
CSE 373 Data Structures and Algorithms
Slide Courtesy: Uwash, UT
Graph Algorithms: Shortest Path
Shortest Paths.
CSE 417: Algorithms and Computational Complexity
CSCI 465 Data Communications and Networks Lecture 16
EE 122: Intra-domain routing: Link State
More Graphs Lecture 19 CS2110 – Fall 2009.
OSPF Protocol.
Presentation transcript:

Verifying Dijktra’s algorithm in Jahob Jonathan Kuhn Robin Mange EPFL-SSC

Our goals Acquire practical skills in software verification Statement checking through implementation Performance evaluation Discussion

Reminder: Dijkstra’s algorithm Computes shortest-paths in directed graphs No negative weight edges Widely used in networking in routing protocols (e.g. OSPF)

Implementation Class Node {} Class Path {} Class Vector{} Class Integer{} Class Dijkstra{} Simulated classes for Vector and Integer Objects

Implementation Init Fill up Vector 1 Main loop of the algorithm While vector 1 is not empty, take the node corresponding to the smallest distance. Remove it from vector 1, and recompute all edges to update minimal distances Fill up Vector 1 Add to the vector 1 all the node except the starting one Init Set distances to -1 and 0 for the start node. Set empty arrays for previous (node) Distances and previous arrays have to be initialized Vector 1 needs to be initialized Specifications of above need to be maintained.

Verification: Unfortunately We still have a method that is not verified. We already can say that: The execution time of a verification process of our entire program (~200 lines) is about 20min… The number of annotation lines is about 80 for 200 lines of code.

Performance VC generation algorithms can be exponential in code size Can lead to long verification times (even for small programs) Important to write modularized code ESC/Java is known to be faster… but has more drawbacks than Jahob E.g. no infinite loop check, arithmetic overflow, unsound, …

Discussion Problems encountered Jahob doesn’t support libraries: need to simulate them Int and objects aren’t treated the same way in decision procedures Strange behavior with invariants in rare cases

But… Jahob was mostly tested on small data structures (linked lists, …) Can be enhanced and extended beyond current state Very promising!

Related work To do: To test several benchmarks to test the correctness of the verification process. If time allows: Use ESC/Java to compare performances with Jahob Translating annotations would be straightforward .