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 11-17 of 17 results.

A023151 Numbers k such that prime(k) == 9 (mod k).

Original entry on oeis.org

1, 2, 10, 11, 35, 37, 80, 100364, 251711, 251717, 251731, 251735, 251741, 251770, 4124456, 4124582, 27067096, 27067520, 69709706, 69709717, 69709723, 69709868, 69709931, 69709933, 465769825, 465769826, 465769831, 1208198548, 8179002130
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; p = 1; Do[ If[ Mod[p = NextPrim[p], n] == 9, Print[n]], {n, 1, 10^9}] (* Robert G. Wilson v, Feb 18 2004 *)
  • Sage
    def A023151(max) :
        terms = []
        p = 2
        for n in range(1, max+1) :
            if (p - 9) % n == 0 : terms.append(n)
            p = next_prime(p)
        return terms
    # Eric M. Schmidt, Feb 05 2013

Extensions

More terms from Robert G. Wilson v, Feb 18 2004
a(25)-a(29) from Robert G. Wilson v, Feb 22 2006
First two terms inserted by Eric M. Schmidt, Feb 05 2013

A105290 Numbers k such that prime(k+1) == 4 (mod k).

Original entry on oeis.org

1, 3, 11, 13, 69, 71, 637225, 637253, 637313, 637327, 4124459, 4124685, 27067033, 179993017, 179993023, 1208198853, 8179002097, 8179002109, 55762149091
Offset: 1

Views

Author

Zak Seidov, Apr 25 2005

Keywords

Comments

Integers k such that A004649(k+1) = 4. - Michel Marcus, Dec 30 2022

Crossrefs

Programs

  • PARI
    my(n=0, p=2); while(n++, (-4+p=nextprime(p+1))%n || print1(n, ", ")) \\ M. F. Hasler, Feb 05 2009

Extensions

Missing first two terms inserted by M. F. Hasler, Feb 04 2009
a(11)-a(13) from M. F. Hasler, Feb 05 2009
a(14)-a(15) from Sean A. Irvine, Nov 25 2010
a(16) from D. S. McNeil, Nov 25 2010
a(17)-a(19) from Charles R Greathouse IV, May 05 2011

A156152 Primes p such that p = 2 (mod pi(p)), where pi(p) = A000720(p) is the prime counting function.

Original entry on oeis.org

2, 5, 41, 47, 347, 367, 9559817, 514272793, 514274807, 514275529, 3779851091, 27788568469, 27788573621, 204475055227, 11091501631937, 81744303098923, 602656752070661, 602656752071189, 241849345578327359, 241849345578328451, 241849345578337811, 1784546064357416683
Offset: 1

Views

Author

M. F. Hasler, Feb 04 2009

Keywords

Crossrefs

Cf. A156151, A156153 (primes from this sequence).

Programs

  • Mathematica
    f[p_,n_]:=Mod[p,n]==2; lst={};Do[p=Prime[n];If[f[p,n],AppendTo[lst,p]],{n,11!}];lst (* Vladimir Joseph Stephan Orlovsky, Dec 08 2009 *)
  • PARI
    p=c=0; until(0, (-2+p=nextprime(p+1))%c++ || print1(p, ", "))

Formula

a(n) = A000040(A023144(n)).

Extensions

More terms from Max Alekseyev, May 03 2009
a(15)-a(16) from Jinyuan Wang, Feb 22 2020
Terms a(17) and beyond from Giovanni Resta, Feb 23 2020

A156153 Primes p such that p == 2 (mod pi(p)) and pi(p) is prime.

Original entry on oeis.org

5, 41, 367, 9559817, 514275529
Offset: 1

Views

Author

M. F. Hasler, Feb 04 2009

Keywords

Crossrefs

Programs

  • PARI
    p=c=0; until(0, until( isprime(c++), p=nextprime(p+1)); (p-2)%c & next; print1(p, ", ")); \\ Modified by Jinyuan Wang, Feb 22 2020

Formula

A156154 Primes p such that prime(p)=2 (mod p), where prime(p)=A000040(p) is the p-th prime.

Original entry on oeis.org

3, 13, 73, 637321, 27067133
Offset: 1

Views

Author

M. F. Hasler, Feb 04 2009

Keywords

Crossrefs

Cf. A156153.

Programs

  • Mathematica
    Select[Prime[Range[17*10^5]],Mod[Prime[#],#]==2&] (* Harvey P. Dale, Dec 28 2022 *)
  • PARI
    p=c=0; until(0, until( isprime(c++), p=nextprime(p+1)); (p-2)%c & next; print1( c","))

Formula

a(n) = A000040(A156155(n)) ; A156154 = intersection of A000040 and A023144.

A156155 Numbers k such that prime(prime(k)) = 2 (mod prime(k)), where prime(k) = A000040(k) is the k-th prime.

Original entry on oeis.org

2, 6, 21, 51892, 1686970
Offset: 1

Views

Author

M. F. Hasler, Feb 04 2009

Keywords

Crossrefs

Programs

  • PARI
    p=c=0; until(0, until( isprime(c++), p=nextprime(p+1)); (p-2)%c & next; print1( primepi(c)","))

Formula

a(n) = A000720(A156154(n)).

Extensions

a(5) from Jinyuan Wang, Feb 22 2020

A328022 Prime numbers p such that all 4 variables of the equation (p = i * q + r) are prime, with i being the index of p, q the quotient of p/i, and r the remainder of p/i.

Original entry on oeis.org

17, 41, 367, 514275529
Offset: 1

Views

Author

Eduardo P. Feitosa, Oct 01 2019

Keywords

Comments

The other two variables in the equation result from the division of a prime p by its index i, giving quotient q and remainder r. All four of p, i, q, r are required to be prime.
For all remaining terms, q (which has become greater than 2) will be an odd prime, and q increases exponentially slowly. And when q is odd, exactly one of i and r will be odd. Consequently, a new term will only occur when r = 2 and both q and i are prime.
a(5) > 10^22, if it exists. - Giovanni Resta, Oct 02 2019

Examples

			Known values:
   n |  a(n) = p =        i *  q + r
  ===+==============================
   1 |        17 =        7 *  2 + 3
   2 |        41 =       13 *  3 + 2
   3 |       367 =       73 *  5 + 2
   4 | 514275529 = 27067133 * 19 + 2
		

Crossrefs

Programs

  • Mathematica
    Select[Prime@ Range[10^5], AllTrue[Join[{#1, #2}, QuotientRemainder[#1, #2]], PrimeQ] & @@ {#, PrimePi@ #} &] (* Michael De Vlieger, Oct 01 2019 *)
  • PARI
    lista(nn)={my(i=1); forprime(p=3, nn, i++; if(isprime(i), my(q=p\i); if(isprime(q)&&isprime(p-q*i), print1(p, ", ")) ))} \\ Andrew Howroyd, Oct 01 2019

Extensions

a(4) from Andrew Howroyd, Oct 01 2019
Previous Showing 11-17 of 17 results.