login
a(n) = 1 if A344005(d) < A344005(n) for all the proper divisors d of n, otherwise 0. Here A344005(n) is the smallest positive integer m such that n divides m*(m+1).
2

%I #10 Jun 17 2022 18:11:41

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

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

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

%N a(n) = 1 if A344005(d) < A344005(n) for all the proper divisors d of n, otherwise 0. Here A344005(n) is the smallest positive integer m such that n divides m*(m+1).

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

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

%F a(n) = [A354991(n) = 1] = [A354999(n) = 1], where [ ] is the Iverson bracket.

%t s[n_] := Module[{m = 1}, While[! Divisible[m*(m + 1), n], m++]; m]; a[n_] := Module[{sn = s[n]}, If[DivisorSum[n, If[s[#] < sn, 0, 1] &, # < n &] == 0, 1, 0]]; Array[a, 100] (* _Amiram Eldar_, Jun 17 2022 *)

%o (PARI)

%o A344005(n) = for(m=1, oo, if((m*(m+1))%n==0, return(m))); \\ From A344005

%o A354993(n) = { my(x=A344005(n)); fordiv(n, d, if(A344005(d)==x, return(d==n))); };

%Y Characteristic function of A354994.

%Y Cf. A344005, A354991, A354999.

%Y Cf. also A344880, A345950.

%K nonn

%O 1

%A _Antti Karttunen_, Jun 17 2022