aysylu / loom

Graph library for Clojure. Mailing list https://groups.google.com/forum/#!forum/loom-clj
http://aysy.lu/loom/
886 stars 108 forks source link

Add algorithm for simple cycles in a directed graph #126

Open npcoder2k14 opened 4 years ago

npcoder2k14 commented 4 years ago
npcoder2k14 commented 4 years ago

Closing it since build failed on this one. Will reopen to trigger the build

npcoder2k14 commented 4 years ago
npcoder2k14 commented 4 years ago

@aysylu Can you suggest to me what am I doing wrong?

Testing loom.test.alg FAIL in (bellman-ford-test) (at /home/travis/build/aysylu/loom/target/loom.js:1021:261) expected: (= [{:e INF, :d INF, :b INF, :a INF, :c 0} {:c [:c]}] (bellman-ford g11 :c)) actual: (not (= [{:e nil, :d nil, :b nil, :a nil, :c 0} {:c [:c]}] [{:c 0, :a ##Inf, :b ##Inf, :d ##Inf, :e ##Inf} {:c (:c)}])) FAIL in (bellman-ford-test) (at /home/travis/build/aysylu/loom/target/loom.js:1021:261) expected: (= [{:e 7, :d 5, :c 4, :a INF, :b 0} {:b [:b], :c [:b :c], :d [:b :d], :e [:b :d :e]}] (bellman-ford g12 :b)) actual: (not (= [{:e 7, :d 5, :c 4, :a nil, :b 0} {:b [:b], :c [:b :c], :d [:b :d], :e [:b :d :e]}] [{:b 0, :a ##Inf, :c 4, :d 5, :e 7} {:b (:b), :c (:b :c), :d (:b :d), :e (:b :d :e)}])) FAIL in (bellman-ford-test) (at /home/travis/build/aysylu/loom/target/loom.js:1021:261) expected: (= [{:e INF, :d INF, :b INF, :a INF, :c 0} {:c [:c]}] (bellman-ford g12 :c)) actual: (not (= [{:e nil, :d nil, :b nil, :a nil, :c 0} {:c [:c]}] [{:c 0, :a ##Inf, :b ##Inf, :d ##Inf, :e ##Inf} {:c (:c)}])) FAIL in (bellman-ford-test) (at /home/travis/build/aysylu/loom/target/loom.js:1021:261) expected: (= [{:e 2, :b -5, :c -1, :a INF, :d 0} {:d [:d], :c [:d :e :b :c], :b [:d :e :b], :e [:d :e]}] (bellman-ford g12 :d)) actual: (not (= [{:e 2, :b -5, :c -1, :a nil, :d 0} {:d [:d], :c [:d :e :b :c], :b [:d :e :b], :e [:d :e]}] [{:d 0, :a ##Inf, :b -5, :c -1, :e 2} {:d (:d), :b (:d :e :b), :c (:d :e :b :c), :e (:d :e)}])) FAIL in (bellman-ford-test) (at /home/travis/build/aysylu/loom/target/loom.js:1021:261) expected: (= [{:d -2, :b -7, :c -3, :a INF, :e 0} {:e [:e], :c [:e :b :c], :b [:e :b], :d [:e :b :d]}] (bellman-ford g12 :e)) actual: (not (= [{:d -2, :b -7, :c -3, :a nil, :e 0} {:e [:e], :c [:e :b :c], :b [:e :b], :d [:e :b :d]}] [{:e 0, :a ##Inf, :b -7, :c -3, :d -2} {:e (:e), :b (:e :b), :c (:e :b :c), :d (:e :b :d)}])) Testing clojure.test.check.properties

Some Bellman-ford tests are failing for me which I haven't even touched.