change genprime_ab0 to genprime_range, change is_prime to next_prime
add write output to file