firstly take the least common multiple of the generators of the ideal