A377934 a(n) is the number of perfect powers m^k with k>=3 (A076467) <= 10^n.
1, 2, 7, 17, 38, 75, 152, 306, 616, 1260, 2598, 5401, 11307, 23798, 50316, 106776, 227236, 484737, 1036002, 2217529, 4752349, 10194727, 21887147, 47020054, 101065880, 217325603, 467484989, 1005881993, 2164843035, 4660016778, 10032642455, 21602193212, 46518438071
Offset: 0
Keywords
Examples
a(0) = 1: 1^k with any k>2 (<= 10^0); a(1) = 2: 1 and 2^3 (<=10^1); a(2) = 7: 2 powers <= 10 and 16, 27, 32, 64, 81 (<=10^2).
Links
- Chai Wah Wu, Table of n, a(n) for n = 0..2999
Programs
-
Python
from math import gcd from sympy import integer_nthroot, mobius def A377934(n): return int(integer_nthroot(10**(n//(a:=gcd(n,4))),4//a)[0]-sum(mobius(k)*(integer_nthroot(10**(n//(b:=gcd(n,k))),k//b)[0]+integer_nthroot(10**(n//(c:=gcd(n,d:=k<<1))),d//c)[0]-2) for k in range(3,(10**n).bit_length()))) # Chai Wah Wu, Nov 24 2024
Formula
a(n) = 10^n - Sum_{k=1..floor(log2(10^n))} mu(k)*(floor(10^(n/k))+floor(10^(n/(2k)))-2). - Chai Wah Wu, Nov 24 2024
Extensions
a(28) onwards from Chai Wah Wu, Nov 24 2024