Forum discussion on Graph

Answer the question

Re: Answer the question

by Zannatul Mawya Priya 201-15-3209 -
Number of replies: 0
1. Answer:



Graph is a non-linear data structure that is same as the mathematical (discrete mathematics) concept of graphs. It is a collection of nodes (also called as vertices) and edges that connect these vertices. Graphs are used to represent arbitrary relationship among objects. A graph can be directed or undirected.

There are several different types of charts and graphs. The four most common are probably line graphs, bar graphs and histograms, pie charts, and Cartesian graphs.



2. Answer:



The application of graph:

1. In Computer science graphs are used to represent the flow of computation.

2. Google maps uses graphs for building transportation systems, where intersection of two(or more) roads are considered to be a vertex and the road connecting two vertices is considered to be an edge, thus their navigation system is based on the algorithm to calculate the shortest path between two vertices.

3. In Facebook, users are considered to be the vertices and if they are friends then there is an edge running between them. Facebook’s Friend suggestion algorithm uses graph theory. Facebook is an example of undirected graph.

4. In World Wide Web, web pages are considered to be the vertices. There is an edge from a page u to other page v if there is a link of page v on page u. This is an example of Directed graph. It was the basic idea behind Google Page Ranking Algorithm.

5. In Operating System, we come across the Resource Allocation Graph where each process and resources are considered to be vertices. Edges are drawn from resources to the allocated process, or from requesting process to the requested resource. If this leads to any formation of a cycle then a deadlock will occur.