A132199 Rowland's prime-generating sequence: first differences of A106108.
1, 1, 1, 5, 3, 1, 1, 1, 1, 11, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 23, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 47, 3, 1, 5, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 101, 3, 1, 1
Offset: 1
Keywords
References
- Eric S. Rowland, A simple prime-generating recurrence, Abstracts Amer. Math. Soc., 29 (No. 1, 2008), p. 50 (Abstract 1035-11-986).
Links
- Robert G. Wilson v, Table of n, a(n) for n = 1..10000 .
- Jean-Paul Delahaye, Déconcertantes conjectures, Pour la Science (French edition of Scientific American), No. 367, May 2008.
- Brian Hayes, Pumping the Primes, bit-player, 19 August 2015.
- Mario Raso, Integer Sequences in Cryptography: A New Generalized Family and its Application, Ph. D. Thesis, Sapienza University of Rome (Italy 2025). See p. 18.
- Eric S. Rowland, A natural prime-generating recurrence, arXiv:0710.3217 [math.NT], 2007-2008.
- Eric S. Rowland, A simple prime-generating recurrence, 2008.
- Eric S. Rowland, Prime-Generating Recurrences and a Tale of Logarithmic Scale, 20 January 2023.
Crossrefs
Programs
-
Haskell
a132199 n = a132199_list !! (n-1) a132199_list = zipWith (-) (tail a106108_list) a106108_list -- Reinhard Zumkeller, Nov 15 2013
-
Maple
A106108 := proc(n) option remember; if n = 1 then 7; else procname(n-1)+igcd(n,procname(n-1)) ; end if; end proc: A132199 := proc(n) A106108(n+1)-A106108(n) ; end proc: # R. J. Mathar, Jul 04 2013
-
Mathematica
a[1] = 7; a[n_] := a[n] = a[n - 1] + GCD[n, a[n - 1]]; t = Array[a, 104]; Rest@t - Most@t (* Robert G. Wilson v, Apr 30 2009 *)
-
PARI
ub=1000; a=7; n=2; while(n
Daniel Constantin Mayer, Aug 31 2014 -
Python
from itertools import count, islice from math import gcd def A132199_gen(): # generator of terms a = 7 for n in count(2): yield (b:=gcd(a,n)) a += b A132199_list = list(islice(A132199_gen(),20)) # Chai Wah Wu, Mar 14 2023
Comments