Chapter 10

Graphs

This chapter provides a brief introduction to the concept of graphs and discusses the basic terminology of graphs. Various popular and widely used representations of graphs are explained along with examples. Different operations that are frequently applied on graphs are explained with algorithms, examples and their implementations. Breadth and Depth first traversals of a graph are also exemplified. The chapter also includes the detailed discussion of the Prim’s algorithm regarding the minimal cost spanning tree of a graph among the listed applications, followed by the Abstract Data Type of graph.

10.1 INTRODUCTION

Graph theory is applied in diverse areas such as social sciences, physical sciences, communication engineering ...

Get Data Structures and Algorithms Using C++ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.