A131955 a(n) = sum of digits of (n!! + a(n-1)).
1, 3, 6, 5, 2, 5, 2, 17, 17, 23, 14, 23, 23, 23, 23, 23, 41, 41, 41, 41, 41, 50, 41, 59, 68, 59, 68, 59, 68, 86, 86, 104, 95, 95, 104, 86, 104, 86, 122, 95, 104, 113, 149, 95, 140, 95, 131, 122, 149, 140, 140, 113, 185, 149, 185, 149, 176, 194, 176, 185, 194, 194, 203
Offset: 1
Examples
a(4) = Sum_digits(6+4!!) = Sum_digits(6+8) = Sum_digits(14) = 5.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
P:=proc(n) local a,i,k,w; a:=0; for i from 1 by 1 to n do w:=0; k:=a+2^((1+2*i-cos(i*Pi))/4)*Pi^((cos(i*Pi)-1)/4)*GAMMA(1+1/2*i); while k>0 do w:=w+k-(trunc(k/10)*10); k:=trunc(k/10); od; a:=w; print(a); od; end: P(100); # alternative: A[1]:= 1: for n from 2 to 100 do A[n]:= convert(convert(doublefactorial(n)+A[n-1],base,10),`+`); od: seq(A[i],i=1..100); # Robert Israel, Oct 29 2020
-
Mathematica
s={1};Do[AppendTo[s,DigitSum[n!!+s[[-1]]]],{n,2,63}];s (* James C. McMahon, Mar 03 2025 *)
Extensions
Offset corrected by Robert Israel, Oct 29 2020