SWS: Group 4 Laurence Cabenda, Niels Reyngoud, Roy van den Broek.

Slides:



Advertisements
Similar presentations
Cpt S 223 – Advanced Data Structures Graph Algorithms: Introduction
Advertisements

Social network partition Presenter: Xiaofei Cao Partick Berg.
Signals and Systems March 25, Summary thus far: software engineering Focused on abstraction and modularity in software engineering. Topics: procedures,
Michael Alves, Patrick Dugan, Robert Daniels, Carlos Vicuna
1 Union-find. 2 Maintain a collection of disjoint sets under the following two operations S 3 = Union(S 1,S 2 ) Find(x) : returns the set containing x.
Algorithms + L. Grewe.
CPSC 322, Lecture 5Slide 1 Uninformed Search Computer Science cpsc322, Lecture 5 (Textbook Chpt 3.4) January, 14, 2009.
CPSC 322, Lecture 4Slide 1 Search: Intro Computer Science cpsc322, Lecture 4 (Textbook Chpt ) January, 12, 2009.
Functions.
4 July 2005 overview Traineeship: Mapping of data structures in multiprocessor systems Nick de Koning
1 Module 13 Studying the internal structure of REC, the set of solvable problems –Complexity theory overview –Automata theory preview Motivating Problem.
1 CTC 450 Review Friction Loss Over a pipe length Darcy-Weisbach (Moody’s diagram) Connections/fittings, etc.
Prof. Awad Hanna Precedence Diagram Advantages of using Precedence Diagram: 1. No dummy activity are required. 2. A single number can be assigned to identify.
Theory of Computation. Computation Computation is a general term for any type of information processing that can be represented as an algorithm precisely.
NetworkModel-1 Network Optimization Models. NetworkModel-2 Network Terminology A network consists of a set of nodes and arcs. The arcs may have some flow.
Applied Discrete Mathematics Week 10: Equivalence Relations
Using Dijkstra’s Algorithm to Find a Shortest Path from a to z 1.
Shortest Path. Dijkstra’s Algorithm finds the shortest path from the start vertex to every other vertex in the network. We will find the shortest path.
Networks and the Shortest Path Problem.  Physical Networks  Road Networks  Railway Networks  Airline traffic Networks  Electrical networks, e.g.,
Pluribus: final – Group A Ingmar, Laurence, Kang, Raymon and Roy.
Route aware subsystem Group C Laurence Cabenda Rudy van Wandelen Niels Reyngoud.
CSC 480 Software Engineering Lecture 14 Oct 16, 2002.
Chinese postman problem
Binary Search From solving a problem to verifying an answer.
Project Management “Project Planning & Scheduling”
1© Manhattan Press (H.K.) Ltd Stationary waves in an open pipe.
Algorithms April-May 2013 Dr. Youn-Hee Han The Project for the Establishing the Korea ㅡ Vietnam College of Technology in Bac Giang.
Functional Programming With examples in F#. Pure Functional Programming Functional programming involves evaluating expressions rather than executing commands.
11/1/20151 GC16/3011 Functional Programming Lecture 5 Miranda patterns, functions, recursion and lists.
1 The Floyd-Warshall Algorithm Andreas Klappenecker.
Pseudocode Algorithms Using Sequence, Selection, and Repetition Simple Program Design Third Edition A Step-by-Step Approach 6.
C. Varela; Adapted w. permission from S. Haridi and P. Van Roy1 Functional Programming: Lists, Pattern Matching, Recursive Programming (CTM Sections ,
Merging the specs Huanwen Qu, Jeroen Zuijderwijk, Roy van den Broek.
10-3C Graphs of Radical Equations If you do not have a calculator, please get one from the back wall! The Chapter 10 test is a NON calculator test! Algebra.
Building Abstractions with Variables (Part 1) CS 21a: Introduction to Computing I First Semester,
Complexity & Computability. Limitations of computer science  Major reasons useful calculations cannot be done:  execution time of program is too long.
CPSC 322, Lecture 6Slide 1 Uniformed Search (cont.) Computer Science cpsc322, Lecture 6 (Textbook finish 3.5) Sept, 17, 2012.
Chapter 7 : Risk Management – part 2
CS6045: Advanced Algorithms Sorting Algorithms. Heap Data Structure A heap (nearly complete binary tree) can be stored as an array A –Root of tree is.
Chapter 11 Digital Control Systems
Lecture 12 CSE 331 Sep 28, Upcoming Important Dates Tuesday Oct 8 (~1.5 weeks) Mini Project group compositions Monday Oct 12 (2 weeks) Quiz 1 Monday.
Graphs Definition: a graph is an abstract representation of a set of objects where some pairs of the objects are connected by links. The interconnected.
Lesson 3-2 Functions and Function Notation Objective: To learn about functions, domains and ranges. To use function notation to represent functions.
Energy-efficient Scheduling policy for collaborative execution in mobile cloud computing INFOCOM '13.
Lecture 5 Algorithm Analysis Arne Kutzner Hanyang University / Seoul Korea.
P, NP, and NP-Complete Problems Section 10.3 The class P consists of all problems that can be solved in polynomial time, O(N k ), by deterministic computers.
Mapping GPS locations Ingmar Brouns Richard Nieuwenhuis Roy van den Broek Niels Reyngoud.
Changing the pluribus final A Ingmar Brouns Peter van Keeken Niels Reyngoud Lennart Kats Jeroen Zuijderwijk Team B.
Example of formula (defun roots (a b c) (list
Shortest Path from G to C Using Dijkstra’s Algorithm
Artificial Intelligence
Discussion section #2 HW1 questions?
Enumerating Distances Using Spanners of Bounded Degree
Sequences 11/27/2018 1:37 AM Singly Linked Lists Singly Linked Lists.
Solutions to Systems of Equations
THE CHINESE POSTMAN PROBLEM Liz Biz and Hells Bells.
Shortest Path.
DES Examples Chater#3 DES.
Shortest Path Algorithms
A graphing calculator is required for some problems or parts of problems 2000.
Chapter 7 Functions and Graphs.
Which of the following graphs corresponds to the inequality {image} ?
Unit 4 Scientific Notation
Dynamic Programming General Idea
Shortest Path.
Lecture 11 CSE 331 Sep 21, 2017.
Lecture 12 CSE 331 Sep 22, 2014.
Lecture 11 CSE 331 Sep 22, 2016.
Shortest Path Solutions
Prim’s algorithm for minimum spanning trees
Presentation transcript:

SWS: Group 4 Laurence Cabenda, Niels Reyngoud, Roy van den Broek

Problem Find a generic specification for graph problems like “shortest path” and “highest path” Give the abstract specification Embed concrete problems into this specification We assume that we have a start and an end node

Given: Some type Node Some type D :: (Path, L) Path :: Sequence(Node x Node) L = R U {  }  : absorbing element of L Example: When adding real numbers,  is the absorbing element

Given: We stepped away from last weeks representation with the operators defined on a type D  : L -> L -> L Combining the values of two sequential paths  : L -> L -> L Choosing the best value out of the values of two parallel paths Both are commutative and associative

Input: Sequence S {0…n-1} -> Node Function f: Node x Node -> L Returns the value of the arc between two nodes Gives back  when there’s no direct arc between two nodes Node start, end, such that start  end

Output: (solution_path, solution_value) :: D

Intermezzo: All possible paths We need to have a notion of all possible paths P is the set of all possible paths P = P seq (all 2_tuplepermutations of S )

Intermezzo: All possible paths 2_tuplepermutations {1,2,3} -> {(1,2),(1,3),(2,1),(2,3),(3,1),(3,2)} Analog to k_permutations of a set, k_permutations gives a set of sets k_tuplepermutations gives a set of tuples

Intermezzo: All possible paths P seq (powersequence) {(1,2),(1,3),(2,1),(2,3),(3,1),(3,2)} -> { [(1,2)], [(1,2),(1,3)], [(1,2),(1,3),(2,3)], [(1,3),(1,2)], … } Analog to powerset of a set powerset gives a set of sets powersequences gives a set of sequences

Intermezzo: All possible paths New problem: not all of these paths are valid (e.g. of the form (a,b), (b,c), … ) A path P with length n is valid if:  i  {0..n-2} : f(fst(P[i]), snd(P[i]))    snd(p[i]) = fst(P[i+1])

Another helper function We assume a function exists that calculates the value of a path. value could be defined as: value [] = 0 value (a,b) = f(a,b) value (a,b):rest = f(a,b)  value(rest)

Such that: solution_path must be valid: valid solution_path solution_path should have the correct start and finish nodes first(head(solution_path)) = start second(last(solution_path)) = end solution_value must be equal to the value of solution_path solution_value = value (solution_path)

Such that: And most important ;-): (solution_path, solution_value) is the best possible solution:  (pospath, posval = value (pospad)) : pospath  P : (valid pospath /\ fst (head (pospath)) = s /\ snd (last (pospath)) = e ) -> solution_value  posval = solution_value

Embedding shortest path Shortest path:  should be defined as   should be defined as +  should be defined as  The generic operators in valid, value and the notion of best path now become concrete

Embedding highest path Highest path:  should be defined as 0  should be defined as   should be defined as 