Lecture 15 CSE 331 Oct 4, 2010.

Slides:



Advertisements
Similar presentations
Breadth-First Search Seminar – Networking Algorithms CS and EE Dept. Lulea University of Technology 27 Jan Mohammad Reza Akhavan.
Advertisements

Lecture 38 CSE 331 Dec 7, The last few days Today: Solutions to HW 9 (end of lecture) Wednesday: Graded HW 9 (?), Sample final, Blog post on the.
Lecture 13 CSE 331 Oct 2, Announcements Please turn in your HW 3 Graded HW2, solutions to HW 3, HW 4 at the END of the class Maybe extra lectures.
Lecture 16 CSE 331 Oct 9, Announcements Hand in your HW4 Solutions to HW4 next week Remember next week I will not be here so.
Lecture 12 CSE 331 Sep 30, Announcements Final exam: Dec 16, 11:45am-2:45pm, NSC 210 HW 2 solutions at the end of the lecture Mid term: Oct 16,
Lecture 17 CSE 331 Oct 8, HW 4 due today Q1 and Q2 in one pile Q3 in another pile I will not take any HW after 1:15pm.
Breadth First Search (BFS) Part 2 COMP171. Graph / Slide 2 Shortest Path Recording * BFS we saw only tells us whether a path exists from source s, to.
CISC220 Fall 2009 James Atlas Nov 13: Graphs, Line Intersections.
Lecture 39 CSE 331 Dec 9, Announcements Please fill in the online feedback form Sample final has been posted Graded HW 9 on Friday.
Lecture 18 CSE 331 Oct 11, Mid term Next Monday in class.
Lecture 13 CSE 331 Oct 2, Announcements Mid term in < 2 weeks Graded HW2 at the END of the class.
Lecture 11 CSE 331 Sep 25, Homeworks Please hand in your HW 2 now HW 3 and graded HW 1 at the end of class.
Lecture 23 CSE 331 Oct 24, Reminder 2 points for Piazza participation 3 points for mini-project.
CSE 421 Algorithms Richard Anderson Winter 2009 Lecture 5.
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.
CSE 421 Algorithms Richard Anderson Autumn 2015 Lecture 5.
Brute Force and Exhaustive Search Brute Force and Exhaustive Search Traveling Salesman Problem Knapsack Problem Assignment Problem Selection Sort and Bubble.
Graph Algorithms BFS, DFS, Dijkstra’s.
Lecture 12 Graph Algorithms
Lecture 20 CSE 331 Oct 15, 2010.
Lecture 23 CSE 331 Oct 26, 2016.
Lecture 10 CSE 331 Sep 21, 2016.
Lecture 10 CSE 331 Sep 20, 2017.
Lecture 15 CSE 331 Oct 5, 2012.
Lecture 15 CSE 331 Sep 29, 2014.
CSE 421: Introduction to Algorithms
Lecture 21 CSE 331 Oct 21, 2016.
Lecture 21 CSE 331 Oct 20, 2017.
Lecture 14 CSE 331 Sep 30, 2016.
Lecture 13 CSE 331 Sep 29, 2010.
Lecture 12 CSE 331 Sep 26, 2016.
Lecture 12 CSE 331 Sep 25, 2017.
Lecture 14 CSE 331 Sep 30, 2011.
Lecture 13 CSE 331 Oct 1, 2012.
Lecture 24 CSE 331 Oct 25, 2013.
Elementary Graph Algorithms
Lecture 22 CSE 331 Oct 23, 2017.
Lecture 23 CSE 331 Oct 25, 2017.
Lecture 24 CSE 331 Oct 29, 2012.
Lecture 23 CSE 331 Oct 24, 2011.
Lecture 22 CSE 331 Oct 24, 2016.
Lecture 13 CSE 331 Sep 27, 2017.
Lecture 13 CSE 331 Sep 24, 2013.
Richard Anderson Autumn 2016 Lecture 5
Lecture 20 CSE 331 Oct 17, 2011.
Lecture 14 CSE 331 Oct 3, 2012.
Lecture 12 CSE 331 Sep 28, 2012.
Lecture 12 CSE 331 Sep 26, 2011.
Lecture 14 CSE 331 Sep 29, 2017.
Lecture 9 CSE 331 Sep 19, 2016.
Lecture 16 CSE 331 Oct 2, 2013.
Lecture 22 CSE 331 Oct 15, 2014.
Lecture 18 CSE 331 Oct 9, 2017.
Lecture 11 CSE 331 Sep 23, 2011.
Algorithms Lecture # 29 Dr. Sohail Aslam.
Lecture 15 CSE 331 Oct 3, 2011.
Lecture 11 CSE 331 Sep 19, 2014.
Lecture 24 CSE 331 Oct 24, 2014.
Lecture 11 CSE 331 Sep 21, 2017.
Lecture 12 CSE 331 Sep 22, 2014.
Lecture 23 CSE 331 Oct 24, 2011.
Lecture 26 CSE 331 Nov 1, 2010.
Lecture 11 CSE 331 Sep 22, 2016.
Lecture 19 CSE 331 Oct 10, 2016.
Richard Anderson Winter 2019 Lecture 6
Lecture 11 Graph Algorithms
Lecture 13 CSE 331 Sep 28, 2016.
Richard Anderson Autumn 2015 Lecture 6
Lecture 11 CSE 331 Sep 20, 2013.
Lecture 24 CSE 331 Oct 29, 2018.
Presentation transcript:

Lecture 15 CSE 331 Oct 4, 2010

Announcements Final exam: Dec 14, 3:30pm-6:30pm, Knox 104 Mid term: Oct 18, in class Graded HW 2 on Wed: sorry!

not student post category

Determining connectivity in graphs http://www.cise.ufl.edu/research/sparse/matrices/Nasa/barth5.html s t Are s and t connected?

Brute-force algorithm List all possible distinct vertex sequences between s and t n! such sequences Check if any is a path between s and t

Algorithm motivation all

Distance between u and v Length of the shortest length path between u and v Distance between RM and BO? 1

Questions?

Breadth First Search (BFS) Is s connected to t? Build layers of vertices connected to s Lj : all nodes at distance j from s L0 = {s} Assume L0,..,Lj have been constructed Lj+1 set of vertices not chosen yet but are connected to Lj Stop when new layer is empty

Exercise for you Prove that Lj has all nodes at distance j from s

Given BFS, how to decide if s is connected to t?

BFS Tree BFS naturally defines a tree rooted at s Add non-tree edges Lj forms the jth “level” in the tree u in Lj+1 is child of v in Lj from which it was “discovered” 1 7 1 L0 2 3 L1 2 3 8 4 5 4 5 7 8 L2 6 6 L3

Connected Component Connected component (of s) is the set of all nodes connected to s

Algo to compute the connected component of s?

Today’s agenda Every edge in is between consecutive layers Computing Connected component