login
a(n) = 1 if sigma(n) and A003961(n) are relatively prime, otherwise 0.
5

%I #14 Nov 28 2021 12:54:13

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

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

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

%N a(n) = 1 if sigma(n) and A003961(n) are relatively prime, otherwise 0.

%C Characteristic function of A349165.

%H Antti Karttunen, <a href="/A349167/b349167.txt">Table of n, a(n) for n = 1..65537</a>

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

%H <a href="/index/Pri#prime_indices">Index entries for sequences computed from indices in prime factorization</a>

%H <a href="/index/Si#SIGMAN">Index entries for sequences related to sigma(n)</a>

%F a(n) = 1 iff A342671(n) == 1, otherwise a(n) = 0.

%t f1[p_, e_] := NextPrime[p]^e; f2[p_, e_] := (p^(e + 1) - 1)/(p - 1); a[1] = 1; a[n_] := Boole @ CoprimeQ[Times @@ f1 @@@ (f = FactorInteger[n]), Times @@ f2 @@@ f]; Array[a, 100] (* _Amiram Eldar_, Nov 28 2021 *)

%o (PARI)

%o A003961(n) = { my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); };

%o A349167(n) = (1==gcd(sigma(n), A003961(n)));

%Y Cf. A000203, A003961, A342671, A349163, A349165, A349166.

%Y Cf. also A348737.

%K nonn

%O 1

%A _Antti Karttunen_, Nov 10 2021