Graphs 1.4 - Running Time of Graph Algorithms Running time...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Running Time of Graph Algorithms Running time often a function of both |V| and |E|. For convenience, we sometimes drop the | . | in asymptotic notation, e.g. O(V+E). CSE 2011 Prof. J. Elder - 16 - Last Updated: 4/1/10 10:16 AM Implementing a Graph (Simplified) Adjacency List CSE 2011 Prof. J. Elder - 17 - Adjacency Matrix Last Updated: 4/1/10 10:16 AM Representing Graphs (Details) Three basic methods Edge List Adjacency List Adjacency Matrix CSE 2011 Prof. J. Elder - 18 - Last Updated: 4/1/10 10:16 AM Edge List Structure Vertex object element reference to position in vertex sequence u a Edge object c d b v element w z origin vertex object destination vertex object reference to position in edge sequence u z w v Vertex sequence sequence of vertex objects a Edge sequence b c d sequence of edge objects CSE 2011 Prof. J. Elder - 19 - Last Updated: 4/1/10 10:16 AM Adjacency List Structure Edge list structure a Incidence sequence for each vertex v b u w sequence of references to edge objects of incident edges Augmented edge objects u v w references to associated positions in incidence sequences of end vertices a CSE 2011 Prof. J. Elder - 20 - b Last Updated: 4/1/10 10:16 AM ...
View Full Document

Ask a homework question - tutors are online