login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Number of ones in the binary expansion of (n!)!.
1

%I #22 Oct 29 2021 04:57:14

%S 1,1,1,4,29,293,2566,24844,259437,2908263,35102629,455204360,

%T 6321171774

%N Number of ones in the binary expansion of (n!)!.

%H <a href="/index/Fa#factorial">Index entries for sequences related to factorial numbers</a>

%F a(n) = A000120(A000197(n)).

%e a(3) = 4 because (3!)! = 6! = 720 = 1011010000_2 which has 4 ones.

%p a:= n-> add(i, i=Bits[Split](n!!)):

%p seq(a(n), n=0..10);

%t a[n_] := DigitCount[(n!)!, 2, 1]; Array[a, 10, 0] (* _Amiram Eldar_, Oct 29 2021 *)

%o (Python)

%o from gmpy2 import fac, popcount

%o def A348651(n): return popcount(fac(fac(n))) # _Chai Wah Wu_, Oct 28 2021

%o (PARI) a(n) = hammingweight((n!)!); \\ _Michel Marcus_, Oct 29 2021

%Y Cf. A000120, A000142, A000197, A079584, A152168, A301861.

%K nonn,base,more

%O 0,4

%A _Alois P. Heinz_, Oct 27 2021

%E a(11)-a(12) from _Chai Wah Wu_, Oct 28 2021