login
a(n) = Sum_{r < n, gcd(r,n)=1} n!/r.
2

%I #12 Sep 03 2017 03:32:35

%S 1,2,9,32,250,864,12348,67584,804816,5760000,116915040,686776320,

%T 19323757440,157991178240,2951575200000,42301705420800,

%U 1202482800691200,10048607738265600,425162773111910400,4541227794432000000

%N a(n) = Sum_{r < n, gcd(r,n)=1} n!/r.

%e a(6) = 6!(1/1 + 1/5) = 864.

%p a:=proc(n) local s,r: s:=0: for r from 1 to n do if gcd(r,n)=1 then s:=s+1/r else s:=s: fi: od: n!*s end: seq(a(n),n=1..23); # _Emeric Deutsch_, Jul 25 2005

%t Do[Print[n! * Plus @@ Map[(1/#)&, Select[Range[n], GCD[ #, n] == 1 &]]], {n, 1, 30}] (* _Ryan Propper_, Jul 25 2005 *)

%Y Cf. A038048, A110373, A110374.

%K easy,nonn

%O 1,2

%A _Amarnath Murthy_, Jul 24 2005

%E More terms from _Emeric Deutsch_, _Ryan Propper_ and _Reinhard Zumkeller_, Jul 25 2005