The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
+3 votes
233 views

Write the adjacency matrix representation of the graph given in below figure.

asked in Graph Theory by Veteran (98.7k points)
edited by | 233 views

2 Answers

+4 votes
Best answer
  p1 p2 p3 p4 p5
p1 0 1 0 0 1
p2 0 0 0 1 0
p3 1 0 0 0 0
p4 0 0 1 0 1
p5 0 1 0 0 0
answered by (313 points)
selected by
+3 votes
put $1$ in all places in adjacency marix according to direction given in edges for ex $p1$ to $p5$ there is path going so put $1$ in $p1$ row and $p5$ col but don't put $1$ in $p5$ to $p1$ because there is no path
answered by Active (1.3k points)
edited by


Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

37,162 questions
44,735 answers
127,405 comments
43,806 users