OFFSET
1
LINKS
FORMULA
EXAMPLE
For n = 8 = 2^3, a(8) = 0 as 3 is not a power of 2 (in A000079).
MATHEMATICA
a[n_] := If[AllTrue[FactorInteger[n][[;; , 2]], # == 2^IntegerExponent[#, 2] &], 1, 0]; Array[a, 100] (* Amiram Eldar, Jul 19 2022 *)
PROG
(PARI) A355823(n) = factorback(apply(e->!bitand(e, e-1), factor(n)[, 2]));
CROSSREFS
Characteristic function of A138302, "Exponentially 2^n-numbers".
KEYWORD
nonn,mult
AUTHOR
Antti Karttunen, Jul 19 2022
STATUS
approved