Fix for prime divisor code

As mentioned in Issue #9