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

A355958 Positions where primes occur in A104589.

Original entry on oeis.org

2, 3, 4, 8, 12, 18, 19, 35, 39, 47, 53, 65, 75, 81, 84, 102, 109, 127, 131, 261, 265, 273, 283, 305, 323, 329, 350, 450, 456, 462, 492, 522, 562, 660, 664, 784, 904, 922, 1081, 1213, 1258, 1406, 1443, 1467, 1549, 1655, 1772, 1774, 1786, 1810, 1901, 1919, 2024, 2144, 2161
Offset: 1

Views

Author

Michel Marcus, Jul 21 2022

Keywords

Examples

			The 1st prime in A104589 is 2, and its position is 2, so a(1) = 2.
The 2nd prime in A104589 is 5, and its position is 3, so a(2) = 3.
The 3rd prime in A104589 is 13, and its position is 4, so a(3) = 4.
		

Crossrefs

Programs

  • Mathematica
    s[1] = 1; s[n_] := s[n] = s[n - 1] + Sum[If[CompositeQ[s[k]], 0, s[k]], {k, 1, n - 1}]; Select[Range[2000], PrimeQ[s[#]] &] (* Amiram Eldar, Jul 21 2022 *)
  • PARI
    lista(nn) = my(last=1, s = 1, list = List()); for (n=2, nn, last += s; if (isprime(last), s += last; listput(list, n));); Vec(list);
Showing 1-1 of 1 results.