login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A276255 Sum of first n Honaker primes. 1
131, 394, 851, 1890, 2939, 4030, 5331, 6692, 8125, 9696, 11609, 13542, 15683, 17904, 20177, 22618, 25209, 27872, 30579, 33298, 36027, 38830, 41897, 45034, 48263, 51696, 55255, 58886, 62977, 67130, 71487, 75884, 80587, 85310, 90213, 95222, 100729, 106430, 112141 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

A Honaker prime is a prime number prime(k) such that k and prime(k) have the same sum of digits.

LINKS

K. D. Bajpai, Table of n, a(n) for n = 1..7300

EXAMPLE

The first Honaker prime is 131, so a(1) = 131.

The second Honaker prime is 263, so a(2) = 131 + 263 = 394.

MATHEMATICA

Accumulate[Select[Prime@Range@3000, Plus @@ IntegerDigits@# == Plus @@ IntegerDigits@PrimePi@# &]] (* Bajpai *)

Accumulate[Table[Prime[n] * Boole[Plus@@IntegerDigits[n] == IntegerDigits[Prime[n]]], {n, 1000}] (* Alonso del Arte, Aug 25 2016 *)

PROG

(Perl) use ntheory ":all"; my($s, $i)=(0, 0); forprimes { say $s+=$_ if sumdigits($_) == sumdigits(++$i) } 1e7; # Dana Jacobsen, Aug 29 2016

(PARI) first(n)=my(v=vector(n), i, k, s); forprime(p=2, , if(sumdigits(k++)==sumdigits(p), v[i++] = s+=p); if(i==n, return(v))) \\ Charles R Greathouse IV, Aug 29 2016

CROSSREFS

Cf. A033548.

Sequence in context: A242846 A142129 A068680 * A142555 A118507 A105837

Adjacent sequences:  A276252 A276253 A276254 * A276256 A276257 A276258

KEYWORD

nonn,base

AUTHOR

K. D. Bajpai, Aug 25 2016

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 5 11:18 EDT 2020. Contains 333239 sequences. (Running on oeis4.)