Factor Out The Greatest Common Divisor Matrix