test for prime number check efficiency

checking smaller of num/denom is better than checking the larger
number.  Now need to clean up