login
a(n) = 1 if the product of exponents in the prime factorization of n is 2, otherwise 0.
6

%I #17 Jan 05 2023 03:20:04

%S 0,0,0,1,0,0,0,0,1,0,0,1,0,0,0,0,0,1,0,1,0,0,0,0,1,0,0,1,0,0,0,0,0,0,

%T 0,0,0,0,0,0,0,0,0,1,1,0,0,0,1,1,0,1,0,0,0,0,0,0,0,1,0,0,1,0,0,0,0,1,

%U 0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,1,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,1

%N a(n) = 1 if the product of exponents in the prime factorization of n is 2, otherwise 0.

%C a(n) = 1 if there is exactly one exponent in the prime factorization of n that is larger than 1, and that exponent is 2, otherwise 0.

%H Antti Karttunen, <a href="/A359474/b359474.txt">Table of n, a(n) for n = 1..100000</a>

%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>.

%H <a href="/index/Eu#epf">Index entries for sequences computed from exponents in factorization of n</a>.

%F a(n) = [A005361(n) == 2], where [ ] is the Iverson bracket.

%F a(n) = [A000688(n) == 2].

%F a(n) = [A046660(n) == 1].

%F a(n) = A359471(n) - A008966(n).

%F a(n) = A302048(n) + A359475(n).

%F a(n) = A359429(n) * A359466(n).

%F Sum_{k=1..n} a(k) ~ c * n, where c = A271971. - _Amiram Eldar_, Jan 05 2023

%t a[n_] := If[PrimeOmega[n] - PrimeNu[n] == 1, 1, 0]; Array[a, 100] (* _Amiram Eldar_, Jan 05 2023 *)

%o (PARI) A359474(n) = (2==factorback(factor(n)[, 2])); \\ From the "is" function given in A048109

%Y Characteristic function of A060687.

%Y Cf. A000688, A005361, A008966, A046660, A271971, A302048, A359429, A359466, A359471, A359472, A359475.

%K nonn

%O 1

%A _Antti Karttunen_, Jan 04 2023