diff --git a/src/matrix/render.clj b/src/matrix/render.clj index dbd180e..ebd518d 100644 --- a/src/matrix/render.clj +++ b/src/matrix/render.clj @@ -191,3 +191,5 @@ :mul (pretty-mul inner) :add (pretty-add inner)))) ([op _] (with-inc-row-indices op))) + +;TODO: better row formatting (each column is only as wide as the longest in the column) diff --git a/test/matrix/core_test.clj b/test/matrix/core_test.clj index 7a468da..a5565e2 100644 --- a/test/matrix/core_test.clj +++ b/test/matrix/core_test.clj @@ -26,4 +26,12 @@ (map-matrix int (auto-final [[2 3 15] - [1 -1 0]])))))) + [1 -1 0]]))))) + (testing "A nightmare" + ; https://www.desmos.com/calculator/17l6cwgtgc + (is (= [[1 0 0 -14/5] + [0 1 0 6/5] + [0 0 1 46/5]] + (auto-final [[3 1 1 2] + [1 -2 1 4] + [-1 1 0 4]])))))