Computes the first 30 digits of the ternary expansion of the proper fraction p/q to the fraction i/j
and checks to see if the number is not in the Cantor set.

to the