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-3 of 3 results.

A217199 Odd primes p such that 2p-1 is prime and no p is equal to 2q-1 with q in the sequence.

Original entry on oeis.org

3, 7, 19, 31, 79, 97, 139, 199, 211, 229, 271, 307, 331, 337, 367, 379, 439, 499, 547, 577, 601, 607, 619, 691, 727, 811, 829, 937, 967, 1009, 1069, 1171, 1279, 1297, 1399, 1429, 1459, 1531, 1609, 1627, 1759, 1867, 2011, 2029, 2089, 2131, 2179, 2221, 2281
Offset: 1

Views

Author

Michel Marcus, Sep 27 2012

Keywords

Comments

At each step, the smallest possible p is chosen.
These are the primes described in lemma 2 of the paper by Holt. - T. D. Noe, Sep 28 2012
This sequence was used by Holt (2003) to prove that there are at least two solutions k to phi(n+k) = phi(k) for all even n <= 1.38*10^26595411. - Amiram Eldar, Mar 19 2021

Crossrefs

Programs

  • Mathematica
    t = {}; p = 2; Do[p = NextPrime[p]; If[PrimeQ[2*p - 1] && ! MemberQ[2*t - 1, p], AppendTo[t, p]], {PrimePi[2281]}]; t
  • PARI
    intab(val, tab) = {for (ii=1, length(tab),if (tab[ii] == val, return (1);););return(0);}
    lista(nn) = {tab = []; for (i=1, nn, len = length(tab); if (len == 0, p = 3, p = nextprime(tab[len]+1)); while (! isprime(2*p-1) || intab((p+1)/2, tab) , p = nextprime(p+1);); tab = concat(tab, p); print1(p, ", "););}

A217198 A sequence of odd primes p such that 2p-1 is prime and no p is equal to any 2q-1 with q in the sequence.

Original entry on oeis.org

3, 7, 31, 37, 97, 139, 157, 199, 211, 229, 271, 307, 331, 337, 367, 379, 439, 499, 547, 577, 601, 607, 619, 691, 727, 811
Offset: 1

Views

Author

Michel Marcus, Sep 27 2012

Keywords

Comments

Sequence used in conjunction with A001259 in the referenced articles.
It is not clear that this sequence is correct -- it certainly does not match the title. See A217199 for the correct version. - T. D. Noe, Sep 28 2012

Crossrefs

A379144 a(n) is the number of iterations of the function x --> 2*x - 1 such that x remains prime, starting from A005382(n).

Original entry on oeis.org

2, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 2, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 3, 1, 2, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 2, 1, 1, 1, 1
Offset: 1

Views

Author

Ctibor O. Zizka, Dec 16 2024

Keywords

Comments

Cunningham chain of the second kind of length i is a sequence of prime numbers (p_1, ..., p_i) such that p_(r + 1) = 2*p_r - 1 for all 1 =< r < i. This sequence tells the length of the Cunningham chain of the second kind for primes from A005382.

Examples

			n = 1: A005382(1) = 2 --> 3 --> 5 --> 9, 9 is not a prime, thus a(1) = 2.
n = 3: A005382(3) = 7 --> 13 --> 25, 25 is not a prime, thus a(3) = 1.
		

Crossrefs

Programs

  • Mathematica
    s[n_] := -2 + Length[NestWhileList[2*# - 1 &, n, PrimeQ[#] &]]; Select[Array[s, 5000], # > 0 &] (* Amiram Eldar, Dec 16 2024 *)

Formula

a(A110581(n)) = 1.
a(A057326(n)) = 2.
Showing 1-3 of 3 results.