OFFSET
1,3
FORMULA
a(n) ~ c * 2^(n-1), where c = 0.687827... (A327839). - Amiram Eldar, Aug 16 2024
EXAMPLE
a(5) = 11: The following 11 numbers have numbers of divisors that are powers of 2: 17, 19, 21, 22, 23, 24, 26, 27, 29, 30 and 31 with 2, 2, 4, 4, 2, 8, 4, 4, 2, 8 and 2 divisors, respectively.
MATHEMATICA
f[n_] := Boole[n == 2^IntegerExponent[n, 2]]; a[n_] := Sum[f[DivisorSigma[0, k]], {k, 2^(n - 1) + 1, 2^n}]; Array[a, 20] (* Amiram Eldar, Aug 16 2024 *)
PROG
(PARI) a(n)=sum(k=2^(n-1)+1, 2^n, my(d=numdiv(k)); (d/(1<<valuation(d, 2)))==1 ); \\ Joerg Arndt, Feb 27 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Name clarified and more terms from Joerg Arndt, Feb 27 2017
a(25)-a(28) from Jon E. Schoenfield, Jul 31 2018
a(29)-a(35) from Jon E. Schoenfield, Aug 04 2018
STATUS
approved