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

A232861 Numbers k with k - 1, k + 1, prime(k) - k, prime(k) + k, k*prime(k) - 1, k*prime(k) + 1 all prime.

Original entry on oeis.org

22110, 23742, 128238, 275592, 346560, 1061910, 1281522, 1339002, 1378188, 1461600, 1850130, 2064150, 2354952, 2478270, 2523708, 2689260, 2694300, 3916638, 4422618, 4933530, 6179082, 6541080, 6641562, 6740478, 6759030, 7315812, 8484798, 8711010, 9133308, 9687720
Offset: 1

Views

Author

Zhi-Wei Sun, Dec 01 2013

Keywords

Comments

Obviously, each term of the sequence is a multiple of 6.
Conjecture: (i) This sequence contains infinitely many terms.
(ii) Let P(x) be a non-constant integer-valued polynomial with positive leading coefficient. Then, there are infinitely many positive integers k with prime(k) - k in the range P(Z) = {P(m): m is an integer}, if and only if the degree of P(x) is at most 3. We may also replace prime(k) - k by prime(k) + k.

Examples

			a(1) = 22110 with the six numbers 22110 - 1 = 22109, 22110 + 1 = 22111, prime(22110) - 22110 = 228841, prime(22110) + 22110 = 273061, 22110*prime(22110) - 1 = 5548526609, 22110*prime(22110) + 1 = 5548526611 all prime.
		

Crossrefs

Programs

  • Mathematica
    n=0
    Do[If[PrimeQ[k-1]&&PrimeQ[k+1]&&PrimeQ[Prime[k]-k]&& PrimeQ[Prime[k]+k]&& PrimeQ[k*Prime[k]-1]&& PrimeQ[k*Prime[k]+1],n=n+1;Print[n," ",k]],{k,1,9700000}]

A115883 The n-th prime minus n gives a triangular number.

Original entry on oeis.org

1, 2, 4, 5, 7, 13, 34, 37, 46, 62, 104, 111, 210, 259, 274, 296, 306, 439, 488, 502, 513, 751, 763, 817, 969, 998, 1132, 1231, 1405, 1586, 1849, 1982, 2107, 2488, 2578, 2695, 2732, 2752, 2989, 3008, 3079, 3322, 3958, 4201, 4628, 5035, 5594, 5722, 5929
Offset: 1

Views

Author

Giovanni Resta, Feb 06 2006

Keywords

Examples

			prime(13)-13 = 41-13 = 28 = T(7).
		

Crossrefs

Programs

A104269 Prime numbers p such that primepi(p) + p is a square.

Original entry on oeis.org

11, 37, 443, 571, 1049, 1307, 1451, 1523, 2837, 3593, 5233, 8539, 9257, 9439, 10391, 10987, 17579, 21881, 23321, 23909, 25117, 30557, 30893, 31231, 42239, 47123, 64811, 65789, 83089, 91631, 92219, 95747, 97549, 99971, 101197, 101807, 110603, 114487, 120431
Offset: 1

Views

Author

Zak Seidov, Feb 26 2005

Keywords

Comments

A064371(p) + A000040(A064371(p)) = A086968(p)^2.
p^2 is prime + its index A086968; p + p-th prime is a square A064371.
Equals the prime terms of A073945. - Bill McEachen, Oct 26 2021

Examples

			37 is a term because 37 is 12th prime and 37 + 12 = 49 = 7^2.
		

Crossrefs

Programs

  • Maple
    q:= n-> isprime(n) and issqr(n+numtheory[pi](n)):
    select(q, [$0..150000])[];  # Alois P. Heinz, Oct 27 2021
  • Mathematica
    Select[Prime@Range[10^4],IntegerQ@Sqrt[PrimePi@#+#]&] (* Giorgos Kalogeropoulos, Oct 26 2021 *)
  • PARI
    isok(n) = isprime(n) && issquare(n + primepi(n)); \\ Michel Marcus, Oct 05 2013

Formula

a(n) = A086968(n)^2 - pi(a(n)).

Extensions

Definition corrected by Michel Marcus, Oct 05 2013

A105645 Numbers n such that the n-th prime - n is a cube.

Original entry on oeis.org

1, 2, 38, 152, 542, 746, 1632, 2243, 5317, 7520, 15006, 33156, 39925, 101946, 130340, 136572, 331757, 397252, 560017, 722898, 1037524, 1197551, 1737710, 1754109, 2160356, 2217439, 2559702, 2820804, 5173565, 6197364, 7014969, 7597461
Offset: 1

Views

Author

Zak Seidov, May 03 2005

Keywords

Comments

Corresponding cubes are: {1,1,5,9,15,17,23,26,36,41,53,71,76}^3. Cf. A064370: numbers n such that the n-th prime - n is a square.

Crossrefs

Cf. A064370.

Programs

  • Mathematica
    Transpose[Select[Table[{Prime[n],n},{n,76*10^5}],IntegerQ[Surd[#[[1]]- #[[2]],3]]&]][[2]] (* Harvey P. Dale, Jun 22 2016 *)
  • PARI
    isok(n) = ispower(prime(n)-n, 3); \\ Michel Marcus, Oct 05 2013

Extensions

a(14)-a(32) from Donovan Johnson, Dec 02 2009

A113410 Numbers n such that n^2 is of the form k-th prime - k for some k.

Original entry on oeis.org

1, 5, 21, 23, 27, 31, 33, 37, 45, 53, 67, 70, 96, 101, 102, 128, 135, 144, 167, 178, 186, 188, 196, 197, 199, 202, 216, 219, 246, 247, 252, 255, 264, 299, 300, 341, 356, 363, 369, 381, 382, 407, 410, 426, 427, 494, 503, 506, 520, 528, 538, 550, 562, 573, 607
Offset: 1

Views

Author

Zak Seidov, Oct 28 2005

Keywords

Comments

Values of k: A064370. Numbers n such that n^2 is of the form k-th prime + k for some k A086968.

Crossrefs

Programs

  • Mathematica
    Sqrt[#]&/@Select[Table[Prime[k]-k,{k,2,40000}],IntegerQ[Sqrt[#]]&] (* Harvey P. Dale, Aug 04 2019 *)

A245061 Prime numbers p such that p - primepi(p) is a square, where primepi is the prime counting function.

Original entry on oeis.org

2, 3, 37, 541, 647, 881, 1151, 1301, 1627, 2377, 3271, 5179, 5641, 10501, 11597, 11821, 18503, 20543, 23339, 31259, 35461, 38669, 39499, 42901, 43331, 44201, 45523, 51973, 53407, 67213, 67757, 70489, 72169, 77291, 98893, 99551, 128291, 139721, 145207, 150011
Offset: 1

Views

Author

Chai Wah Wu, Jul 10 2014

Keywords

Examples

			37 is in the sequence because primepi(37) = 12, and 37 - 12 = 5^2.
541 is in the sequence because primepi(541) = 100, and 541 - 100 = 21^2.
547 is not in the sequence because primepi(547) = 101, and 547 - 101 = 446, which is not a perfect square.
		

Crossrefs

Programs

  • Maple
    with(numtheory): A245061:=n->`if`(type(sqrt(n-pi(n)),integer) and type(n,prime), n, NULL): seq(A245061(n), n=2..10^5); # Wesley Ivan Hurt, Jul 10 2014
  • Mathematica
    Select[Prime[Range[200]], IntegerQ[Sqrt[# - PrimePi[#]]] &] (* Alonso del Arte, Jul 11 2014 *)
  • PARI
    select(p->issquare(p-primepi(p)), primes(15000)) \\ Michel Marcus, Jul 11 2014
    
  • Python
    import sympy,gmpy2
    [sympy.prime(n) for n in range(1,10**6) if gmpy2.is_square(sympy.prime(n)-n)] # Chai Wah Wu, Jul 11 2014

Formula

a(n) = prime(A064370(n+1)). - Michel Marcus, Jul 11 2014

Extensions

More terms from Michel Marcus, Jul 11 2014

A114067 The n-th prime minus n gives a fourth power.

Original entry on oeis.org

1, 2, 2603, 4485, 2894125, 8422110, 16832512, 17322137, 20485427, 32550001, 34980568, 49197457, 58325415
Offset: 1

Views

Author

Giovanni Resta, Feb 13 2006

Keywords

Examples

			p(32550001)-32550001 = 236421376 = 592240896 = 156^4.
		

Crossrefs

Subsequence of A064370 (gives a square).

Programs

  • PARI
    isok(n) = ispower(prime(n) - n, 4); \\ Michel Marcus, Jan 22 2014
Showing 1-7 of 7 results.