login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A166849 Primes with digital root 1, 2, 4 or 8. 1
2, 11, 13, 17, 19, 29, 31, 37, 47, 53, 67, 71, 73, 83, 89, 101, 103, 107, 109, 127, 137, 139, 157, 163, 173, 179, 181, 191, 193, 197, 199, 211, 227, 229, 233, 251, 263, 269, 271, 281, 283, 307, 317, 337, 353, 359, 373, 379, 389, 397, 409, 431, 433, 443 (list; graph; refs; listen; history; internal format)
OFFSET

1,1

COMMENTS

Primes which under repeated summation of digits eventually reach 1, 2, 4 or 8.

LINKS

Nathaniel Johnston, Table of n, a(n) for n = 1..10000

EXAMPLE

The prime 229 is a member since 229 -> 13 -> 4.

MAPLE

A166849 := proc(n) option remember: local k: if(n=1)then return 2:fi: k:=nextprime(procname(n-1)): do if((k-1) mod 9 in {0, 1, 3, 7})then return k: fi: k:=nextprime(k): od: end: seq(A166849(n), n = 1..54); # Nathaniel Johnston, May 04 2011

MATHEMATICA

dr[n_]:=NestWhile[Total[IntegerDigits[#]]&, n, #>9&]; Select[Prime[Range[ 100]], MemberQ[{1, 2, 4, 8}, dr[#]]&] (* From Harvey P. Dale, Oct 25 2011 *)

CROSSREFS

Cf. A010888.

Sequence in context: A172071 A058048 A038915 * A119449 A137977 A160950

Adjacent sequences:  A166846 A166847 A166848 * A166850 A166851 A166852

KEYWORD

nonn,base,easy

AUTHOR

Alexander R. Povolotsky (pevnev(AT)juno.com), Oct 21 2009

EXTENSIONS

Edited by N. J. A. Sloane and Zak Seidov, Oct 23 2009

More terms a(11)-a(51) from Vincenzo Librandi (vincenzo.librandi(AT)tin.it), Oct 24 2009

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 14 20:38 EST 2012. Contains 205663 sequences.