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.

A361680 The n-th prime p such that p + 2^n is also prime.

Original entry on oeis.org

3, 7, 11, 31, 47, 67, 83, 163, 179, 193, 263, 367, 389, 499, 563, 571, 887, 967, 1229, 1087, 1367, 1873, 1289, 2647, 1907, 2083, 1979, 2557, 2267, 3697, 2909, 3121, 3761, 4507, 4373, 4723, 5279, 5857, 6359, 6793, 7727, 8167, 7853, 6823, 6779, 8059, 9479, 10567
Offset: 1

Views

Author

Alois P. Heinz, Mar 20 2023

Keywords

Comments

This sequence is non-monotonic: a(19) = 1229 > a(20) = 1087.

Crossrefs

Main diagonal of A361679.
Cf. A000040.

Programs

  • Maple
    b:= proc() option remember; local f; f:= proc() [] end;
          proc(n, k) option remember; local p;
            p:= `if`(nops(f(k))=0, 1, f(k)[-1]);
            while nops(f(k)) b(n$2):
    seq(a(n), n=1..55);

Formula

a(n) = A361679(n,n).

A361744 A(n,k) is the least m such that there are k primes in the set {prime(n) + 2^i | 1 <= i <= m}, or -1 if no such number exists; square array A(n,k), n > 1, k >= 1, read by antidiagonals.

Original entry on oeis.org

1, 2, 1, 3, 3, 2, 4, 5, 4, 1, 6, 11, 6, 3, 2, 7, 47, 8, 5, 4, 1, 12, 53, 10, 7, 8, 13, 2, 15, 141, 16, 9, 20, 21, 6, 3, 16, 143, 18, 15, 38, 33, 30, 7, 1, 18, 191, 20, 23, 64, 81, 162, 39, 3, 4, 28, 273, 28, 29, 80, 129, 654, 79, 5, 12, 2
Offset: 2

Views

Author

Jean-Marc Rebert, Mar 22 2023

Keywords

Examples

			p = prime(2) = 3, m=1, u = {p + 2^k | 1 <= k <= m} = {5} contains one prime, and no lesser m satisfies this, so A(2,1) = 1.
Square array A(n,k) n > 1 and k >= 1 begins:
 1,     2,     3,     4,     6,     7,    12,    15,    16,    18, ...
 1,     3,     5,    11,    47,    53,   141,   143,   191,   273, ...
 2,     4,     6,     8,    10,    16,    18,    20,    28,    30, ...
 1,     3,     5,     7,     9,    15,    23,    29,    31,    55, ...
 2,     4,     8,    20,    38,    64,    80,   292,  1132,  4108, ...
 1,    13,    21,    33,    81,   129,   285,   297,   769,  3381, ...
 2,     6,    30,   162,   654,   714,  1370,  1662,  1722,  2810, ...
 3,     7,    39,    79,   359,   451,  1031,  1039, 11311, 30227, ...
 1,     3,     5,     7,     9,    13,    15,    17,    23,    27, ...
		

Crossrefs

Cf. A057732 (1st row), A094076 (1st column).
Cf. A361679.
Cf. A019434 (primes 2^n+1), A057732 (2^n+3), A059242 (2^n+5), A057195 (2^n+7), A057196(2^n+9), A102633 (2^n+11), A102634 (2^n+13), A057197 (2^n+15), A057200 (2^n+17), A057221 (2^n+19), A057201 (2^n+21), A057203 (2^n+23).
Cf. A205558 and A231232 (with 2*k instead of 2^k).

Programs

  • PARI
    A(n, k)= {my(nb=0, p=prime(n), m=1); while (nb
    				
Showing 1-2 of 2 results.