Function: matsnf
Section: linear_algebra
C-Name: matsnf0
Prototype: GD0,L,
Help: matsnf(x,{flag=0}): Smith normal form (i.e. elementary divisors) of
 the matrix x, expressed as a vector d. Binary digits of flag mean 1: returns
 [u,v,d] where d=u*x*v, otherwise only the diagonal d is returned, 2: allow
 polynomial entries, otherwise assume x is integral, 4: removes all
 information corresponding to entries equal to 1 in d

