Graph is combination of points and lines. lines are way of showing  connections or relationship between  points. in graph theory points are called VERTICES and lines are called EDGES. Edges represents a relationship between points ( objects) and study of mathematical properties of graph is graph theory. graphs shows connections between things/objects and those objects in graph is represented by points/nodes.

There are two types of graph: undirected graph and directed graph


The A,B,C,D,E,F are vertices ( singular vertex) and the line between A to B, B to C, A to D, D to F, F to E etc. are the edges. The graph represented above are treated as set of vertices and edges. mathematically if we denote a graph as G,vertices as V and edges as E then we can write pictorial representation of graph in mathematics term

G = f ( V, E) where V is set of vertices and E is set of edges formed by joining two vertices.


DEFERENCE : undirected graph and directed graph

  • In undirected graph the ordered pair of vertices are not important while in directed graph  ordered pair of vertices are important. for example edge AB or BA is same in undirected graph while in directed graph AB show the directional relationship.
  • In directed graph the edges are associated with a direction while in undirected graph edges are not associated with direction.
  • Matrix representation of undirected graph becomes symmetric
  • Undirected graph can be converted into directed graph but reverse is not true.

weighted graph

A graph is said to  be weighted graph if every edge and/or vertices in the graph G is assigned a value.

g1The above graph  G = (V,E) is weighted graph in which every edges is assigned a value. for example edge AB is assigned 40 and AD is assigned 50.

GRAPH and its representation

Read this link( )for graph and its representation

Related Contents to follow