[Math] Software to find out adjacency matrix of a graph.

graph theorymath-software

I am looking for a graph theoretical software. I can draw a graph delete or add its vertices and edges whatever I want. The software shall give me the Adjacency matrix, degree matrix etc.

Is such a software exists? If available please provide its name and publisher.

Anyhow how can I implement it in C or C++?

I am currently using Matlab, but it is not much helpful.

Thank you for your help.

Best Answer

You can use sage, http://www.sagemath.org/. Suppose, for example, to find the adjacent matrix of $K_5$, then the following program will find it for you.

sage: g= graphs.CompleteGraph(5)

sage: g.adjacency_matrix()

The manual is here http://www.sagemath.org/doc/reference/graphs/sage/graphs/generic_graph.html

Related Question