# UnitGaussianElimination¶

References: J-G. Dumas, F. Heckenbach, D. Sauders, V. Welker: Computing simplicial homology based on efficient Smith normal form algorithms. Descrition: Gaussion elimination using only 1 or -1 as pivots

pre_gauss: Matrix Integer -> Matrix Integer
pre_gauss(m) performs Gaussian eliminaton on rows of m using only 1 and -1 as pivots. Note: m is modified in place
pre_lr: (Matrix Integer, Vector Integer, Vector Integer) -> Matrix Integer
pre_lr(m, pi, pj) is like pre_gauss, but records positions of pivots in pi and pj and returns transformation matrix. m, pi, pj are modified in place
pre_smith: Matrix Integer -> Matrix Integer
pre_smith(m) first performs pre_gauss(m) and then drops all rows and colums of m contaning pivots.