Edge and Vertex Connectivity for MultiGraphs?

Hi guys,

I’m new here, so forgive me if I have mislabeled this post and it has been miscategorized.

I’m relatively new to Mathematica, and am working on a project for school. I’m having trouble coming up with a way to calculate the edge and vertex connectivity of a multigraph (multiple edges between vertices). I know that Mathematica can calculate these for me, but it does not seem to allow multigraphs; I can plot them using GraphPlot, with MultiedgeStyle->True, but this still does not allow me to get the edge and vertex connectivity.

Thanks for any help or tips you can offer, and sorry if my question is simple--I’m still learning!

Thanks,

Sam

I think EdgeWeight and functions like WeightedAdjacencyMatrix might be what you are seeking.

Thank you so much! You’re a life-saver!

Here’s the example might help you…

edges = {UndirectedEdge[1, 2], UndirectedEdge[1, 2], UndirectedEdge[2, 3], 
 UndirectedEdge[2, 3], UndirectedEdge[3, 4], UndirectedEdge[3, 4], 
 UndirectedEdge[3, 4], UndirectedEdge[1, 5], UndirectedEdge[1, 5], 
 UndirectedEdge[1, 5], UndirectedEdge[1, 5], UndirectedEdge[5, 6], 
 UndirectedEdge[5, 6], UndirectedEdge[2, 6], UndirectedEdge[6, 4], 
 UndirectedEdge[6, 4], UndirectedEdge[6, 4], UndirectedEdge[2, 5], 
 UndirectedEdge[2, 5], UndirectedEdge[3, 6]};

{nedges, weights} = Transpose[Tally[edges]];

g = Graph[nedges, EdgeWeight -> weights, 
  VertexLabels -> Placed["Name", Center], EdgeLabels -> "EdgeWeight", 
  VertexSize -> .2]

EdgeConnectivity[g]