improve contains/overlaps to (hopefully) work with huge exponents; add some test code