find prime factors for integer vector iteration