Fixes a but in the principal, nth root method