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.

A047791 Numbers n such that n plus digit sum of n (A007953) equals a prime.

Original entry on oeis.org

1, 10, 11, 13, 14, 16, 19, 32, 34, 35, 37, 52, 53, 56, 58, 59, 71, 73, 76, 91, 92, 94, 95, 97, 100, 101, 103, 104, 106, 122, 124, 127, 128, 142, 143, 146, 149, 160, 163, 166, 167, 181, 182, 184, 185, 215, 217, 218, 232, 233, 238, 250, 253, 256, 257, 271, 272
Offset: 1

Views

Author

Keywords

Examples

			Digit sum of 13 = 1 + 3 = 4 -> 13 + 4 = 17 is prime.
		

Crossrefs

Programs

  • Haskell
    a047791 n = a047791_list !! (n-1)
    a047791_list = filter ((== 1) . a010051' . a062028) [1..]
    -- Reinhard Zumkeller, Sep 27 2014
    
  • Mathematica
    Select[Range[272],PrimeQ[#+Total[IntegerDigits[#]]]&] (* Jayanta Basu, May 03 2013 *)
  • PARI
    select( is(n)=isprime(n+sumdigits(n)), [1..300]) \\ M. F. Hasler, Nov 08 2018

Formula

Complement of A107743.
A062028^(-1)(A000040). - M. F. Hasler, Nov 08 2018

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Nov 16 2000