Graphs Examples on some basic graph concepts and definitions All graphics are taken from the LEDA demos: basic_graph_algorithms, gw_shortest_paths, graphwin.

Slides:



Advertisements
Similar presentations
The Primal-Dual Method: Steiner Forest TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA A A AA A A A AA A A.
Advertisements

Graphs CSCI 2720 Spring 2005.
Simple Graph Warmup. Cycles in Simple Graphs A cycle in a simple graph is a sequence of vertices v 0, …, v n for some n>0, where v 0, ….v n-1 are distinct,
Chapter 9 Graphs.
Chapter 10: Trees. Definition A tree is a connected undirected acyclic (with no cycle) simple graph A collection of trees is called forest.
1 Representing Graphs. 2 Adjacency Matrix Suppose we have a graph G with n nodes. The adjacency matrix is the n x n matrix A=[a ij ] with: a ij = 1 if.
Introduction to Graphs
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2001 Wednesday, 9/26/01 Graph Basics.
Applications of Depth-First Search
1 Section 8.4 Connectivity. 2 Paths In an undirected graph, a path of length n from u to v, where n is a positive integer, is a sequence of edges e 1,
Graphs Chapter 20 Data Structures and Problem Solving with C++: Walls and Mirrors, Frank Carrano, © 2012.
Chapter 9: Graphs Basic Concepts
Discrete Mathematics Lecture 9 Alexander Bukharovich New York University.
GRAPH THEORY.  A graph is a collection of vertices and edges.  An edge is a connection between two vertices (or nodes).  One can draw a graph by marking.
GRAPHS CSE, POSTECH. Chapter 16 covers the following topics Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component,
7.1 and 7.2: Spanning Trees. A network is a graph that is connected –The network must be a sub-graph of the original graph (its edges must come from the.
ساختمانهای گسسته دانشگاه صنعتی شاهرود – فروردین 1392.
1 12/2/2015 MATH 224 – Discrete Mathematics Formally a graph is just a collection of unordered or ordered pairs, where for example, if {a,b} G if a, b.
COSC 2007 Data Structures II Chapter 14 Graphs I.
ساختمانهای گسسته دانشگاه صنعتی شاهرود – فروردین 1392.
Chap. 11 Graph Theory and Applications 1. Directed Graph 2.
Homework #5 Due: October 31, 2000 Christine Kang Graph Concepts and Algorithms.
GRAPHS. Graph Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component, spanning tree Types of graphs: undirected,
 Quotient graph  Definition 13: Suppose G(V,E) is a graph and R is a equivalence relation on the set V. We construct the quotient graph G R in the follow.
Walks, Paths and Circuits. A graph is a connected graph if it is possible to travel from one vertex to any other vertex by moving along successive edges.
Graphs Upon completion you will be able to:
Graph Theory. undirected graph node: a, b, c, d, e, f edge: (a, b), (a, c), (b, c), (b, e), (c, d), (c, f), (d, e), (d, f), (e, f) subgraph.
CSE 421 Algorithms Richard Anderson Winter 2009 Lecture 5.
Graphs. Contents Terminology Graphs as ADTs Applications of Graphs.
Introduction to Graph Theory By: Arun Kumar (Asst. Professor) (Asst. Professor)
Graph Concepts and Algorithms Using LEDA By Caroline Moore and Carmen Frerichs (252a-at and 252a-ao) each graph in the presentation was created using gw_basic_graph_algorithms.
Graph Concepts Elif Tosun 252a-aa (All graphics created by using demo/graphwin/gw*)
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.
Tree - in “math speak” An ________ graph is a set of vertices/nodes and a set of edges, each edge connects two vertices. Any undirected graph in which.
Graph Concepts Illustrated Using The Leda Library Amanuel Lemma CS252 Algorithms.
Graph Representations And Traversals. Graphs Graph : – Set of Vertices (Nodes) – Set of Edges connecting vertices (u, v) : edge connecting Origin: u Destination:
CSC 252: Algorithms October 28, 2000 Homework #5: Graphs Victoria Manfredi (252a-ad) notes: -Definitions for each of the graph concepts are those presented.
DATA STRUCTURE Presented By: Mahmoud Rafeek Alfarra Using C# MINISTRY OF EDUCATION & HIGHER EDUCATION COLLEGE OF SCIENCE AND TECHNOLOGY KHANYOUNIS- PALESTINE.
Graph Terms By Susan Ott. Vertices Here are 7 vertices without any edges Each Vertex is labeled a different color and number.
CSC 213 – Large Scale Programming Lecture 31: Graph Traversals.
1 Data Structures and Algorithms Graphs. 2 Graphs Basic Definitions Paths and Cycles Connectivity Other Properties Representation Examples of Graph Algorithms:
Leda Demos By: Kelley Louie Credits: definitions from Algorithms Lectures and Discrete Mathematics with Algorithms by Albertson and Hutchinson graphics.
CSC 252 Pallavi Moorthy Homework 5. 1.) Vertices, edges From cd../../handout/demo/graph_alg/gw_shortest_path.
Graph Search Applications, Minimum Spanning Tree
Tracing An Algorithm for Strongly Connected Components that uses Depth First Search Graph obtained from Text, page a-al: Geetika Tewari.
Basic Concepts Graphs For more notes and topics visit:
Minimum Spanning Tree Chapter 13.6.
CSE 373, Copyright S. Tanimoto, 2001 Graphs 1 -
Grade 11 AP Mathematics Graph Theory
Graph theory Definitions Trees, cycles, directed graphs.
Graph Algorithms Using Depth First Search
Spanning Trees Discrete Mathematics.
Planarity Testing.
Connected Components Minimum Spanning Tree
CSE 373, Copyright S. Tanimoto, 2002 Graphs 1 -
CS223 Advanced Data Structures and Algorithms
Chapter 9: Graphs Basic Concepts
Elementary Graph Algorithms
Trees L Al-zaid Math1101.
Warm Up – Wednesday.
Richard Anderson Autumn 2016 Lecture 5
10.1 Graphs and Graph Models
Theorem 5.13: For vT‘, l’(v)= min{l(v), l(vk)+w(vk, v)}
Trees 11.1 Introduction to Trees Dr. Halimah Alshehri.
A Introduction to Computing II Lecture 13: Trees
Trees 11.1 Introduction to Trees Dr. Halimah Alshehri.
Graphs G = (V, E) V are the vertices; E are the edges.
Miniconference on the Mathematics of Computation
Richard Anderson Lecture 5 Graph Theory
Chapter 9: Graphs Basic Concepts
Presentation transcript:

Graphs Examples on some basic graph concepts and definitions All graphics are taken from the LEDA demos: basic_graph_algorithms, gw_shortest_paths, graphwin Geetika Tewari 252a-al

Vertex: The point of intersection of lines Vertex: The point of intersection of lines. The terminating point of some lines in a figure or curve Several Vertices Edge: Line that connects 2 vertices Loop: an edge that connects the same two vertices

Multiple Edges: More than one edge connecting two vertices

Undirected Graph: A graph whose edges are all undirected Directed graph: A graph whose edges are directed

Simple Graph: A graph that does not contain any loops or multiple edges

Examples 1. Example of a graph: Notice it is undirected, has multiple edges and loops

2. Example of a graph: Notice the unconnected components

3. Example of a mutigraph (graph with multiple edges)

Special Cases of graphs 1. Complete Graph: A full graph where every edge is connected to every other edge Complete graph of 3 vertices Complete graph of 11 vertices

2. Bipartite Graphs: A graph whose vertices can be divided into two classes. Edges exist only between vertices that belong to different classes. An example of a complete bipartite graph

Paths Path in an directed graph: a series of connected vertices Notice in this example there is a path from vertex 0 to vertex 4: {0, 1, 3, 4}, and a path from vertex 0 to vertex 2:{0, 1, 3, 2}……

Path in an undirected graph In this graph there is a path {11, 5, 7, 13, 10} There are other paths too..

Hamilton Path in an Undirected Graph: A path that spans all the vertices in a graph Hamilton Path in a Directed Graph: A path that spans all the vertices in the digraph Eg: {0, 3, 5, 7, 10, 17, 21, 28}

Cycles: In a graph a path {Vo, V1, V2……Vk} forms a cycle if Vo = Vk and if V1, V2….Vk are distinct.  There is a cycle in this undirected graph: {0, 1, 3, 0}, Cycles in this directed graph: {2, 3, 4, 2}

Hamilton Cycles: A Cycle that covers all the vertices in a graph Hamilton Cycle in a directed graph {0, 1, 3, 2, 4, 5, 6, 7, 0} Hamiltion Cycle in an undirected graph {7, 8, 1, 4, 3, 2, 0, 5, 6, 7}

Cyclic and Acyclic Digraphs A cyclic digraph: a directed graph with cycles: {0, 3, 6, 0}, {0, 1, 2, 4, 5, 3, 6, 0} An acyclic digraph: a directed graph with no cycles

Tree: A connected, acyclic undirected graph Forest: An acyclic undirected graph, i.e. many trees grouped together

Articulation Points In an Undirected Graph An articulation point is a vertex in a graph whose removal disconnects the graph. In the example below, the red vertices are the articulation points.