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.
%I A033548 #48 Dec 30 2023 23:45:30 %S A033548 131,263,457,1039,1049,1091,1301,1361,1433,1571,1913,1933,2141,2221, %T A033548 2273,2441,2591,2663,2707,2719,2729,2803,3067,3137,3229,3433,3559, %U A033548 3631,4091,4153,4357,4397,4703,4723,4903,5009,5507,5701,5711,5741,5801,5843 %N A033548 Honaker primes: primes P(k) such that sum of digits of P(k) equals sum of digits of k. %C A033548 A090431(A049084(a(n))) = 0. %D A033548 Proposed by _G. L. Honaker, Jr._ %H A033548 Charles R Greathouse IV, <a href="/A033548/b033548.txt">Table of n, a(n) for n = 1..10000</a> (first 1000 terms from T. D. Noe) %F A033548 a(n) = A000040(A033549(n)). - _R. J. Mathar_, Jul 07 2021 %e A033548 131 is the 32nd prime and sum of digits of both is 5. %p A033548 read("transforms") : %p A033548 isA033548 := proc(n) %p A033548 if isprime(n) and digsum(n) = digsum(numtheory[pi](n)) then %p A033548 true ; %p A033548 else %p A033548 false; %p A033548 end if; %p A033548 end proc: %p A033548 A033548 := proc(n) %p A033548 local p, k; %p A033548 if n = 1 then %p A033548 131; %p A033548 else %p A033548 p := nextprime(procname(n-1)) ; %p A033548 while true do %p A033548 if isA033548(p) then %p A033548 return p; %p A033548 end if; %p A033548 p := nextprime(p) ; %p A033548 end do: %p A033548 end if; %p A033548 end proc: %p A033548 seq(A033548(n),n=1..40) ; # _R. J. Mathar_, Jul 07 2021 %t A033548 Prime[ Select[ Range[ 2000 ], Apply[ Plus, IntegerDigits[ # ] ] == Apply[ Plus, IntegerDigits[ Prime[ # ] ] ] & ] ] (* _Santi Spadaro_, Oct 14 2001 *) %t A033548 Select[ Prime@ Range@ 5927, Plus @@ IntegerDigits@ # == Plus @@ IntegerDigits@ PrimePi@ # &] (* _Robert G. Wilson v_, Jun 07 2009 *) %t A033548 nn=800;Transpose[Select[Thread[{Prime[Range[nn]],Range[nn]}],Total[IntegerDigits[First[#]]]== Total[ IntegerDigits[ Last[#]]]&]][[1]] (* _Harvey P. Dale_, Jun 13 2011 *) %o A033548 (Haskell) %o A033548 a033548 n = a033548_list !! (n-1) %o A033548 a033548_list = filter ((== 0) . a090431 . a049084) a000040_list %o A033548 -- _Reinhard Zumkeller_, Mar 16 2014 %o A033548 (PARI) is(n)=isprime(n) && sumdigits(n)==sumdigits(primepi(n)) \\ _Charles R Greathouse IV_, Jun 18 2015 %o A033548 (Python) %o A033548 from sympy.ntheory.factor_ import digits %o A033548 from sympy import primepi, primerange %o A033548 print([n for n in primerange(1, 5901) if (sum(digits(n)[1:])==sum(digits(primepi(n))[1:]))]) # _Indranil Ghosh_, Jun 27 2017, after _Charles R Greathouse IV_ %Y A033548 Cf. A007605, A033549, A049084, A072439, A090431. %K A033548 nonn,base,nice %O A033548 1,1 %A A033548 Calculated by _Jud McCranie_ %E A033548 More terms from _Robert G. Wilson v_, Jun 07 2009