use minpoly in equals testing

With improvements to minpoly, it should be used in equals now.