Package: primes 1.6.0
Os Keyes
primes: Fast Functions for Prime Numbers
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.
Authors:
primes_1.6.0.tar.gz
primes_1.6.0.zip(r-4.5)primes_1.6.0.zip(r-4.4)primes_1.6.0.zip(r-4.3)
primes_1.6.0.tgz(r-4.4-x86_64)primes_1.6.0.tgz(r-4.4-arm64)primes_1.6.0.tgz(r-4.3-x86_64)primes_1.6.0.tgz(r-4.3-arm64)
primes_1.6.0.tar.gz(r-4.5-noble)primes_1.6.0.tar.gz(r-4.4-noble)
primes_1.6.0.tgz(r-4.4-emscripten)primes_1.6.0.tgz(r-4.3-emscripten)
primes.pdf |primes.html✨
primes/json (API)
# Install 'primes' in R: |
install.packages('primes', repos = c('https://ironholds.r-universe.dev', 'https://cloud.r-project.org')) |
Bug tracker:https://github.com/ironholds/primes/issues
- primes - Pre-computed Prime Numbers
Last updated 10 months agofrom:915c26c5c4. Checks:OK: 9. Indexed: yes.
Target | Result | Date |
---|---|---|
Doc / Vignettes | OK | Nov 11 2024 |
R-4.5-win-x86_64 | OK | Nov 11 2024 |
R-4.5-linux-x86_64 | OK | Nov 11 2024 |
R-4.4-win-x86_64 | OK | Nov 11 2024 |
R-4.4-mac-x86_64 | OK | Nov 11 2024 |
R-4.4-mac-aarch64 | OK | Nov 11 2024 |
R-4.3-win-x86_64 | OK | Nov 11 2024 |
R-4.3-mac-x86_64 | OK | Nov 11 2024 |
R-4.3-mac-aarch64 | OK | Nov 11 2024 |
Exports:coprimecousin_primesgcdgenerate_n_primesgenerate_primesis_primek_tuplenext_primenth_primenth_prime_estimatephiprev_primeprime_countprime_factorsprimorial_nprimorial_pRgcdRscmruth_aaron_pairsscmsexy_prime_tripletssexy_primesthird_cousin_primestwin_primes
Dependencies:Rcpp
Readme and manuals
Help Manual
Help page | Topics |
---|---|
Find the Greatest Common Divisor, Smallest Common Multiple, or Coprimality | coprime gcd lcm Rgcd Rscm scm |
Generate a Sequence of Prime Numbers | generate_n_primes generate_primes |
Test for Prime Numbers | is_prime |
Prime _k_-tuples | cousin_primes k_tuple sexy_primes sexy_prime_triplets third_cousin_primes twin_primes |
Find the Next and Previous Prime Numbers | next_prime prev_prime |
Get the n-th Prime from the Sequence of Primes. | nth_prime |
Euler's Totient Function | phi |
Prime-counting Functions and Estimating the Value of the n-th Prime | nth_prime_estimate prime_count |
Perform Prime Factorization on a Vector | prime_factors |
Pre-computed Prime Numbers | primes |
Compute the Primorial | primorial primorial_n primorial_p |
Find Ruth-Aaron Pairs of Integers | ruth_aaron_pairs |