cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A301861 a(n) is the sum of the decimal digits of (n!)!.

This page as a plain text file.
%I A301861 #43 Mar 20 2022 14:29:36
%S A301861 1,1,2,9,81,783,7164,69048,711009,7961040,95935761,1242436185,
%T A301861 17235507996
%N A301861 a(n) is the sum of the decimal digits of (n!)!.
%C A301861 Presumably, lim_{n->oo} a(n)/A008906(n!) = 9/2.
%H A301861 <a href="/index/Fa#factorial">Index entries for sequences related to factorial numbers</a>
%F A301861 a(n) = A007953(A000197(n)). - _Michel Marcus_, Mar 28 2018
%F A301861 a(n) = A004152(A000142(n)). - _Altug Alkan_, Mar 28 2018
%e A301861 a(0) = digitsum((0!)!) = digitsum(1!) = digitsum(1) = 1.
%e A301861 a(1) = digitsum((1!)!) = digitsum(1!) = digitsum(1) = 1.
%e A301861 a(2) = digitsum((2!)!) = digitsum(2!) = digitsum(2) = 2.
%e A301861 a(3) = digitsum((3!)!) = digitsum(6!) = digitsum(720) = 7+2 = 9.
%e A301861 a(4) = digitsum((4!)!) = digitsum(24!) = digitsum(620448401733239439360000) = 6+2+0+4+4+8+4+0+1+7+3+3+2+3+9+4+3+9+3+6+0+0+0+0 = 81.
%p A301861 a:= n-> add(i, i=convert(n!!, base, 10)):
%p A301861 seq(a(n), n=0..8);  # _Alois P. Heinz_, Oct 27 2021
%t A301861 Table[Plus@@IntegerDigits[(n!)!], {n, 0, 10}] (* _Vincenzo Librandi_, Mar 29 2018 *)
%o A301861 (PARI) a(n) = sumdigits(n!!); \\ _Michel Marcus_, Mar 28 2018
%o A301861 (Magma) [&+Intseq(Factorial(Factorial(n))): n in [0..10]]; // _Vincenzo Librandi_, Mar 29 2018
%o A301861 (Python)
%o A301861 from math import factorial
%o A301861 def A301861(n):
%o A301861     return sum(int(d) for d in str(factorial(factorial(n)))) # _Chai Wah Wu_, Mar 31 2018
%o A301861 # faster program for larger values of n
%o A301861 from gmpy2 import mpz, digits, fac
%o A301861 def A301861(n): return int(sum(mpz(d) for d in digits(fac(fac(n))))) # _Chai Wah Wu_, Oct 24 2021
%Y A301861 Cf. A000142 (factorial numbers), A000197 ((n!)!), A004152 (sum of digits of n!), A007953 (sum of digits of n), A008906 (number of digits in n! excluding trailing zeros), A027868 (number of trailing zeros in n!), A034886 (number of digits in n!), A063979 (number of digits in (n!)!).
%K A301861 nonn,base,hard,more
%O A301861 0,3
%A A301861 _Jon E. Schoenfield_, Mar 28 2018
%E A301861 a(11) from _Chai Wah Wu_, Mar 31 2018
%E A301861 a(12) from _Chai Wah Wu_, Apr 01 2018