Fast Functions for Prime Numbers
Find the Greatest Common Divisor, Smallest Common Multiple, or Coprima...
Generate a Sequence of Prime Numbers
Test for Prime Numbers
Prime k-tuples
Find the Next and Previous Prime Numbers
Get the n-th Prime from the Sequence of Primes.
Euler's Totient Function
Prime-counting Functions and Estimating the Value of the n-th Prime
Perform Prime Factorization on a Vector
Compute the Primorial
Find Ruth-Aaron Pairs of Integers
Fast functions for dealing with prime numbers, such as testing whether a number is prime and generating a sequence prime numbers. Additional functions include finding prime factors and Ruth-Aaron pairs, finding next and previous prime numbers in the series, finding or estimating the nth prime, estimating the number of primes less than or equal to an arbitrary number, computing primorials, prime k-tuples (e.g., twin primes), finding the greatest common divisor and smallest (least) common multiple, testing whether two numbers are coprime, and computing Euler's totient function. Most functions are vectorized for speed and convenience.