login
a(n) = pi(A340063(n)) = A000720(A340063(n)) for prime A340063(n) and otherwise k such that A340063 is the k-th positive integer having its digitsum.
1

%I #11 Jan 06 2021 19:57:04

%S 1,1,2,2,3,3,3,4,1,5,5,6,2,4,7,6,8,3,5,9,1,10,7,11,2,6,12,3,13,8,14,4,

%T 7,15,2,16,3,17,9,18,4,8,19,5,20,10,21,4,22,5,9,23,5,24,1,25,6,10,26,

%U 11,27,7,28,12,29,7,11,30,1,6,31,8,32,6,33,13,34,2

%N a(n) = pi(A340063(n)) = A000720(A340063(n)) for prime A340063(n) and otherwise k such that A340063 is the k-th positive integer having its digitsum.

%H David A. Corneth, <a href="/A340294/b340294.txt">Table of n, a(n) for n = 1..10000</a>

%e a(17) = 8 as A340063(17) = 19 which is the 8th prime.

%e a(25) = 2 as A340063(25) = 14 which is composite and 14 is the second positive integer with digitsum 5.

%Y Cf. A000720, A254524, A340063.

%K nonn,base

%O 1,3

%A _David A. Corneth_, Jan 03 2021