cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A083771 Rearrangement of primes such that every partial product + 1 is a prime.

Original entry on oeis.org

2, 3, 5, 7, 11, 19, 29, 13, 59, 37, 31, 47, 67, 53, 41, 97, 73, 113, 103, 43, 71, 233, 61, 151, 109, 101, 251, 107, 587, 79, 223, 167, 311, 239, 137, 139, 359, 181, 257, 337, 163, 173, 881, 563, 149, 409, 157, 179, 293, 127, 331, 191, 269, 317, 83, 277, 23, 821, 373, 271, 283, 461, 569, 853, 487, 433, 647, 953, 383, 199, 367, 1231, 397, 307, 457, 691, 523, 463, 1061, 281, 787, 421, 197, 857, 1103, 347, 631, 499, 991, 643, 769, 983, 607, 811, 449, 1223, 733, 1327, 683, 1021
Offset: 1

Views

Author

Amarnath Murthy and Meenakshi Srikanth (menakan_s(AT)yahoo.com), May 06 2003

Keywords

Comments

Though initial terms match it is different from A039726, in that a smaller prime may appear later.
Some of the larger entries may only correspond to probable primes.
A158076 suggests that the numbers in this sequence can be generated quite easily/quickly. Perhaps this sequence is a fast method to generate large probable primes. [Dmitry Kamenetsky, Mar 12 2009]
Records: 2, 3, 5, 7, 11, 19, 29, 59, 67, 97, 113, 233, 251, 587, 881, 953, 1231, 1327, 1553, 1657, 2383, 3251, 3769, 6737, 6947, 7103, 7879, 8263, 10159, 11369, 22003, ..., . - Robert G. Wilson v, Jul 20 2017
Position of the n_th prime: 1, 2, 3, 4, 5, 8, 472, 6, 57, 7, 11, 10, 15, 20, 12, 14, 9, 23, 13, 21, 17, 30, 55, 478, 16, 26, 19, 28, 25, 18, 50, 345, 35, 36, 45, 24, ..., . - Robert G. Wilson v, Jul 20 2017

Examples

			The n-th term is the smallest prime that is not already in the sequence, such that one plus the product of the first n terms is prime. [_Dmitry Kamenetsky_, Mar 12 2009]
		

Crossrefs

Cf. number of primality tests required for each term in this sequence is in A158076. [Dmitry Kamenetsky, Mar 12 2009]

Programs

  • Mathematica
    f[s_List] := Block[{p = Times @@ s, q = 2}, While[ MemberQ[s, q] || !PrimeQ[p*q + 1], q = NextPrime@ q]; Append[s, q]]; Nest[f, {2}, 63] (* Robert G. Wilson v, Jul 20 2017 *)
  • PARI
    { terms=100; a=A083772=vector(terms); a[1]=2; tmp=1; A083772[1]=3; for(k=2,terms, tmp=tmp*a[k-1]; p=1; while(1, until(isprime(p), p=p+2); for(m=1,k-1, if(p==a[m], break, if(m==k-1, if(isprime(tmp*p+1), a[k]=p; A083772[k]=tmp*p+1; print1(a[k],","); break(2))))))); a }

Extensions

More terms from Rick L. Shepherd, Mar 18 2004

A093441 Lexicographically earliest sequence of primes such that a(n) - 1 == 0 (mod a(n - 1) - 1) where a(n) - 1 is a squarefree number; a(1) = 3.

Original entry on oeis.org

3, 7, 31, 211, 2311, 43891, 1272811, 16546531, 976245271, 36121074991, 1119753324691, 52628406260431, 3526103219448811, 186883470630786931, 7662222295862264131, 743235562698639620611, 54256196077000692304531, 6130950156701078230411891, 631487866140211057732424671
Offset: 1

Views

Author

Amarnath Murthy, Apr 01 2004

Keywords

Crossrefs

Distinct from A073918.
Cf. A083772. - R. J. Mathar, Sep 05 2008

Programs

  • Mathematica
    a[1] = 3; a[n_] := a[n] = Block[{k = m = a[n - 1] - 1}, k *= 2; While[ !PrimeQ[k + 1] || !SquareFreeQ[k], k += m]; k + 1]; Table[ a[n], {n, 17}] (* Robert G. Wilson v, Apr 30 2004 *)

Extensions

a(7)-a(17) from Robert G. Wilson v, Apr 30 2004
a(18)-a(19) from Amiram Eldar, Jan 19 2023
Showing 1-2 of 2 results.