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.

A068951 Scan the primes, record digit-sum if it is itself prime.

Original entry on oeis.org

2, 3, 5, 7, 2, 5, 11, 5, 7, 11, 7, 13, 11, 17, 2, 5, 5, 11, 13, 7, 13, 11, 17, 11, 13, 17, 19, 7, 11, 13, 7, 11, 17, 11, 13, 5, 7, 11, 7, 13, 11, 17, 13, 19, 19, 5, 13, 7, 11, 17, 11, 13, 17, 19, 17, 13, 19, 17, 23, 7, 13, 11, 13, 17, 13, 17, 17, 13, 19, 13, 19, 17, 23, 17, 11, 13
Offset: 1

Views

Author

Francois Jooste (phukraut(AT)hotmail.com), Mar 10 2002

Keywords

Examples

			a(13)=5 since the 13th prime is 41 and 4+1=5, which is prime.
		

Crossrefs

Cf. A046704.

Programs

  • Maple
    dig := X->convert((convert(X,base,10)),`+`); a := n->`if`(isprime(dig(ithprime(n)))=true,dig(ithprime(n)),printf(""));
  • Mathematica
    Select[Total[IntegerDigits[#]]&/@Prime[Range[200]],PrimeQ] (* Harvey P. Dale, Oct 17 2020 *)