Question: GraphTheory['AllPairsDistance']: Which output is correct?

GraphTheory:-GraphEqual says that G1 and G2 are equal, but GraphTheory:-AllPairsDistance gives different results instead: 

restart;

with(GraphTheory)

M := `<|>`(`<,>`(0, 0, 0), `<,>`(1, 0, 0), `<,>`(1, 1, 0))

G__1 := Graph(convert(-M, Matrix, datatype = integer[8]))

G__2 := Graph(convert(-M, Matrix, datatype = integer))

GraphEqual(G__1, G__2)

true

(1)

AllPairsDistance(G__1)

AllPairsDistance(G__2)

Matrix(%id = 36893491227039185244)

 

Error, (in GraphTheory:-AllPairsDistanceExt) negative cycle detected

 

 

Download allpairs.mws

So, which one is incorrect? Any reasons?

Please Wait...