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.

Previous Showing 31-39 of 39 results.

A176466 The smallest prime q which stays prime through at least 3 iterations of q -> 2 * q + prime(n+1).

Original entry on oeis.org

2, 13, 5, 199, 2, 13, 251, 487, 61, 5, 113, 19, 2, 13, 157, 1621, 269, 23, 139, 557, 5, 37, 241, 5, 19, 587, 823, 41, 97, 5, 109, 13, 1151, 31, 1409, 53, 5, 1543, 67, 421, 5, 1039, 2, 13, 41, 359, 1697, 43, 101, 157, 1531, 179, 79, 193, 37, 181, 149, 113, 4519, 197, 397, 23, 739, 2, 283, 29, 5, 163, 1031, 1987
Offset: 1

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Apr 18 2010

Keywords

Comments

See comments and references of A176379.
q, 2 * q + prime(n+1), 4 * q + 3 * prime(n+1) and 8 * q + 7 * prime(n+1) are required to be prime.
List of (q,first iteration, 2nd iteration, 3rd iteration):
(2,7,17,37) (13,31,67,139) (5,17,41,89) (199,409,829,1669) (2,17,47,107)
(13,43,103,223) (251,521,1061,2141) (487,997,2017,4057) (61,151,331,691) (5,41,113,257)
(113,263,563,1163) (19,79,199,439) (2,47,137,317) (13,73,193,433) (157,367,787,1627)
(1621,3301,6661,13381) (269,599,1259,2579) (23,113,293,653) (139,349,769,1609) (557,1187,2447,4967)
(5,89,257,593) (37,157,397,877) (241,571,1231,2551) (5,107,311,719) (19,139,379,859)
(587,1277,2657,5417) (823,1753,3613,7333) (41,191,491,1091) (97,307,727,1567) (5,137,401,929)
(109,349,829,1789) (13,163,463,1063) (1151,2441,5021,10181) (31,211,571,1291) (1409,2969,6089,12329)
(53,263,683,1523) (5,173,509,1181) (1543,3253,6673,13513) (67,307,787,1747) (421,1021,2221,4621)
(5,191,563,1307) (1039,2269,4729,9649) (2,197,587,1367) (13,223,643,1483) (41,281,761,1721)
(359,929,2069,4349) (1697,3617,7457,15137) (43,313,853,1933) (101,431,1091,2411) (157,547,1327,2887)

Examples

			n=1: q=2, iteration 2 * q + prime(2) = 7, iteration 2 * 7 + 3 = 17, 2 * 17 + 3 = 37: q=2 is first term
n=2: q=13, iteration 2 * 13 + prime(3) = 31, iteration 2 * 31 + 5 = 67, iteration 2 * 67 + 5 = 139, q=13 is 2nd term
		

Crossrefs

Programs

  • Maple
    A176466 := proc(n)
        pk1 := ithprime(n+1) ;
        for pidx from 1 do
            p := ithprime(pidx) ;
            pitr := 2*p+pk1 ;
            if not isprime(pitr) then
                next ;
            end if;
            pitr := 2*pitr+pk1 ;
            if not isprime(pitr) then
                next ;
            end if;
            pitr := 2*pitr+pk1 ;
            if not isprime(pitr) then
                next ;
            else
                return p ;
            end if;
        end do:
    end proc:
    seq(A176466(n),n=1..80) ; # R. J. Mathar, May 21 2025

A176619 Primes p such that 2p + 3, 4p + 9, 3p + 2 and 9p + 8 are also primes.

Original entry on oeis.org

5, 7, 97, 167, 397, 607, 2617, 2707, 7687, 12097, 14407, 16787, 19577, 22307, 23827, 24967, 25717, 28547, 31687, 43037, 43517, 46817, 58967, 59617, 63607, 70237, 70957, 78517, 85027, 96797
Offset: 1

Views

Author

Ulrich Krug (leuchtfeuer37(AT)gmx.de), Apr 22 2010

Keywords

Comments

These primes stay prime under two iterations of p->2p+3 as well as under two iterations of p->3p+2.
For all entries >5 the least significant digit is 7.

Examples

			2*5 + 3 = 13 = prime(6),
4*5 + 9 = 29 = prime(10),
3*5 + 2 = 17 = prime(7),
9*5 + 8 = 53 = prime(16); 5 = prime(3) = a(1).
		

References

  • Joe Buhler: Algorithmic Number Theory: Third International Symposium, ANTS-III, Springer New York, 1998
  • F. Ischebeck: Einladung zur Zahlentheorie, B. I. Wissenschaftsverlag, Mannheim-Leipzig-Wien-Zuerich, 1992

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(100000)|IsPrime(2*p+3) and IsPrime(4*p+9) and IsPrime(3*p+2) and IsPrime(9*p+8 )] // Vincenzo Librandi, Jan 29 2011
  • Mathematica
    Select[Prime[Range[10000]],AllTrue[{2#+3,4#+9,3#+2,9#+8},PrimeQ]&] (* Harvey P. Dale, Dec 15 2024 *)

Formula

A023242 INTERSECT A023246.

A237495 Primes which start a Cunningham chain of length 5 where every prime in the chain is the smaller of a pair of twin primes.

Original entry on oeis.org

41887255409, 364223689829, 376655795669, 790031896499, 1558600513469, 2180283962009, 3266149150109, 4424063189699, 4655123392919, 6924093600269, 7706450161409, 9792446379869, 14825914106849, 15049625144399, 15612571518389, 18228407987789, 20440411077239
Offset: 1

Views

Author

Abhiram R Devesh, Feb 08 2014

Keywords

Comments

This is subset of the sequence A236443. Of the first 10000 terms in the sequence A236443 only 48 have length 5.
a(n) generates a Cunningham chain of length 5 and a_n(i) + 2 is also prime for i = 1,2,3,4 and 5.
This sequence is infinite under Dickson's conjecture.

Examples

			a(1) = 41887255409, with associated Cunningham chain of length 5: 41887255409, 83774510819, 167549021639, 335098043279, 670196086559, each of which is the smaller of a pair of twin primes.
		

Crossrefs

Cf. A178421, A005602, A236443 is a superset of this sequence.

Extensions

a(11)-a(17) from David Radcliffe, Aug 09 2025

A321058 Indices of records in A067849.

Original entry on oeis.org

1, 2, 44, 561329, 9549959, 42932384, 13044904289, 277344139214, 2045466215756534, 47702521115271164
Offset: 1

Views

Author

Torlach Rush, Oct 26 2018

Keywords

Comments

The corresponding record values are 2,4,6,7,8,9,10,12,13,14.
From David A. Corneth, Nov 10 2018: (Start)
Terms a(n) are of the form 3*k+2 for n > 1.
If 2^k - 1 is composite then a(n) is not divisible by any prime factor of 2^k-1 for n > k. So for example, gcd(a(n), 105) = 1 for n > 5. (End)
From Glen Whitney, Sep 14 2022: (Start)
Similarly to Corneth's observations, modulo any prime p, any residue for a(n) of the form 2^k - 1 mod p is forbidden for n greater than or equal to the number of such residues; for example a(n) may not be congruent to 0, 1, or 3 mod 7 for n >= 3.
For n > 2, if a(n) appears in this sequence, 2a(n) + 1 must appear in A057331. (End)

Examples

			2 is a term because A067849(2) = 4 > A067849(1) = 2.
44 is a term because A067849(44) = 6 > A067869(2) = 4.
		

Crossrefs

Programs

  • PARI
    b(n) = {my(nb = 0, newn); while (isprime(newn=2*n+1), nb++; n = newn); nb;} \\ A067849
    lista(nn) = {my(mmax = -1, mm); for (n=1, nn, if ((mm=b(n)) > mmax, mmax = mm; print1(n, ", ")););} \\ Michel Marcus, Nov 10 2018

Extensions

a(7) from Amiram Eldar, Nov 10 2018
a(8)-a(10) from A057331 by Glen Whitney, Sep 14 2022

A364091 a(n) is the first prime p such that the longest sequence of primes p = p_1, p_2, ... with |p_{k+1} - 2*p_k| = 1 has length n.

Original entry on oeis.org

13, 7, 11, 5, 3, 2, 16651, 15514861, 85864769, 26089808579, 665043081119, 554688278429, 758083947856951, 95405042230542329, 69257563144280941
Offset: 1

Views

Author

Robert Israel, Jul 04 2023

Keywords

Comments

a(n) = A000040(k) where A263879(k) = n is the first appearance of n in A263879.

Examples

			a(4) = 5 because 5, 2*5 + 1 = 11, 2*11 + 1 = 23, 2*23 + 1 = 47 is a sequence of primes of length 4 while 2*47 - 1 = 93 and 2*47 + 1 = 95 are not primes, and 5 is the smallest prime that works.
		

Crossrefs

Programs

  • Maple
    M:= 10: # for a(1) .. a(N)
    f:= proc(n) option remember; local x;
      if n mod 3 = 1 then x:= 2*n-1 else x:= 2*n+1 fi;
      if isprime(x) then 1 + procname(x) else 1 fi;
    end proc:
    f(2):= 6: f(3):= 5:
    V:= Vector(M):
    p:= 1: count:= 0:
    for k from 1 while count < M do
      p:= nextprime(p);
      v:= f(p);
      if v <= M and V[v] = 0 then V[v]:= p; count:= count+1; fi
    od:
    convert(V,list);
  • Python
    from sympy import isprime, nextprime
    def A364091(n):
        if 5 <= n <= 6: return 8-n
        q = 5
        while True:
            p, c = q, 1
            while isprime(p:=(p<<1)+(-1 if p%3==1 else 1)):
                c += 1
                if c > n:
                    break
            if c == n:
                return q
            q = nextprime(q) # Chai Wah Wu, Jul 07 2023

Formula

a(n) = min(A005602(n), A005603(n)) for n >= 7.

A110089 Smallest prime beginning (through <*2+1> or/and <*2-1>) a complete Cunningham chain (of the first or the second kind) of length n.

Original entry on oeis.org

11, 3, 2, 509, 2, 89, 16651, 15514861, 85864769, 26089808579, 665043081119, 554688278429, 758083947856951, 95405042230542329, 69257563144280941
Offset: 1

Views

Author

Alexandre Wajnberg, Sep 04 2005

Keywords

Comments

The word "complete" indicates each chain is exactly n primes long for the operator in function (i.e. the chain cannot be a subchain of another one); and the first and/or last term may be involved in a chain of the other kind (i.e. the chain may be connected to another one). a(1)-a(8) computed by Gilles Sadowski.

Examples

			a(1)=11 because 2, 3, 5 and 7 are included in longer chains than one prime long; and 11 (although included in a <2p+1> chain) has no prime connection through <2p-1>.
a(2)=3 because 3 begins (through 2p+1>) the first complete two primes chain: 3-> 7 (even if 3 and 7 are also part of two others chains, but through <2p-1>).
a(3)=2 because (although 2 begins also a five primes chain through <2p+1>) it begins, through <2p-1>, the first complete three primes chain encountered: 2->3->5.
		

Crossrefs

Formula

a(n) = min(A005602(n), A005603(n)). - R. J. Mathar, Jul 23 2008

Extensions

a(8)-a(13) via A005602, A005603 from R. J. Mathar, Jul 23 2008
a(14)-a(15) via A005602, A005603 from Jason Yuen, Sep 03 2024

A176268 Primes of a Generalized Cunningham chain of length 9 by the function f(p) = 2 * p + 13.

Original entry on oeis.org

3467, 6947, 13907, 27827, 55667, 111347, 222707, 445427, 890867
Offset: 1

Views

Author

Eva-Maria Zschorn (e-m.zschorn(AT)zaschendorf.km3.de), Apr 13 2010

Keywords

Comments

See comments and references of A176223 and A176247
Chain of 8 primes: 2, 17, 47, 107, 227, 467, 947, 1907
It is conjectured that arbitrarily long such chains exist

Examples

			3467 = prime(486), (3467 - 13)/ 2 = 1727 = 11 * 157 is composite
f(3467) = 6947 = prime(891), f(6947) = 13907 = prime(1644)
f(13907) = 27827 = prime(3040), f( 27827) = 55667 = prime(5649)
f(55667) = 111347 = prime(10565), f(111347) = 222707 = prime(19832)
f(222707) = 445427 = prime(37374), f(445427) = 890867 = prime(70612)
f(890867) = 1781747 = 11 * 161977
3467 is smallest prime for such a chain of 9 primes
		

References

  • Joe Buhler: Algorithmic Number Theory: Third International Symposium, ANTS-III, New York: Springer, 1998
  • David J. Darling: The Universal Book of Mathematics: From Abracadabra to Zeno's Paradoxes, Hoboken: John Wiley & Sons, 2004
  • Paulo Ribenboim: Die Welt der Primzahlen. Geheimnisse und Rekorde, Springer-Verlag GmbH & Co. KG, 2006

Crossrefs

A237017 Primes which start a Cunningham chain of length 4 where every entity of the chain is smallest of the prime number pair (p, p+8).

Original entry on oeis.org

359, 1069199, 1392269, 2614169, 10528649, 16981379, 18287309, 19463519, 21071489, 21171509, 22121579, 24857639, 40887569, 41809259, 76130129, 88362479, 118136279, 128893049, 131612609, 153318449, 289743689, 315495539
Offset: 1

Views

Author

Abhiram R Devesh, Feb 02 2014

Keywords

Comments

a(n) generates a Cunningham chain of length 4 and a_n(i) + 8 is also prime for i = 1,2,3 and 4.
This sequence is infinite under Dickson's conjecture.

Examples

			a(1)=359, with associated Cunningham chain 359, 719, 1439, 2879; all of which are the lower member of a pair (p, p+8): (359,367), (719,727), (1439,1447), (2879,2887).
		

Crossrefs

Programs

  • Python
    from sympy import isprime, primerange
    is_a237017 = lambda p: all(isprime(q) for q in (p+8, 2*p+1, 2*p+9, 4*p+3, 4*p+11, 8*p+7, 8*p+15))
    print(*[p for p in primerange(10**7) if is_a237017(p)], sep=', ')
    # David Radcliffe, May 11 2025

A330092 The least prime that starts a chain of exactly n primes such that the product of each successive pair is a golden semiprime (A108540).

Original entry on oeis.org

5, 3, 2, 103, 2437, 6991, 455033, 252492571, 8276659373, 18749113741
Offset: 1

Views

Author

Amiram Eldar, Dec 01 2019

Keywords

Comments

The question of the existence of arbitrary long chains of such primes was asked by Jonathan Vos Post in A107768.
Such chains may be called "golden chains of primes". They are analogous to Cunningham chains: this sequence is analogous to A005602, as A108541 is analogous to A005384.

Examples

			a(1) = 5 since 5 is not a lesser prime of a golden semiprime, i.e., it is not in A108541.
a(2) = 3 since 3 * 5 is a golden semiprime.
a(3) = 2 since {2, 3, 5} is a chain of 3 primes such that 2 * 3 and 3 * 5 are golden semiprimes.
		

Crossrefs

Programs

  • Mathematica
    goldPrime[p_] := Module[{x = GoldenRatio*p}, p1 = NextPrime[x, -1]; p2 = NextPrime[p1]; q = If[x - p1 < p2 - x, p1, p2]; If[Abs[q - x] < 1, q, 0]];
    goldChainLength[p_] := -1 + Length @ NestWhileList[goldPrime, p, # > 0 &];
    max = 7; seq = Table[0, {max}]; count = 0; p = 1; While[count < max, p = NextPrime[p]; i = goldChainLength[p]; If[i <= max && seq[[i]] < 1, count++; seq[[i]] = p]]; seq
Previous Showing 31-39 of 39 results.