prime factorization for small enough numbers