login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A005393 Leading term of Stirling's approximation to n!, sqrt(2*Pi)*n^(n+(1/2))/e^n, rounded down. 2

%I #16 Sep 08 2022 08:44:33

%S 0,0,1,5,23,118,710,4980,39902,359536,3598695,39615625,475687486,

%T 6187239475,86661001740,1300430722199,20814114415223,353948328666100,

%U 6372804626194309,121112786592293963,2422786846761133393,50888617325509644403

%N Leading term of Stirling's approximation to n!, sqrt(2*Pi)*n^(n+(1/2))/e^n, rounded down.

%H G. C. Greubel, <a href="/A005393/b005393.txt">Table of n, a(n) for n = 0..150</a>

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Stirling%27s_approximation">Stirling's Approximation</a>

%F a(n) = floor(sqrt(2*Pi)*n^(n+(1/2))/e^n). - _Wesley Ivan Hurt_, Jun 11 2016

%p A005393:=n->floor(sqrt(2*Pi)*n^(n+(1/2))/exp(1)^n): seq(A005393(n), n=0..30); # _Wesley Ivan Hurt_, Jun 11 2016

%t Table[Floor[Sqrt[2*Pi]*n^(n + 1/2)*Exp[-n]], {n, 0, 50}] (* _G. C. Greubel_, Jun 11 2016 *)

%o (PARI) for(n=0,50, print1(floor(sqrt(2*Pi)*n^(n+(1/2))*exp(-n)), ", ")) \\ _G. C. Greubel_, Aug 16 2018

%o (Magma) R:= RealField(); [Floor(Sqrt(2*Pi(R))*n^(n+(1/2))/Exp(n)): n in [0..50]]; // _G. C. Greubel_, Aug 16 2018

%Y Cf. (rounded up) A005395.

%K nonn,easy

%O 0,4

%A _N. J. A. Sloane_

%E a(12) onwards corrected by _Sean A. Irvine_, Jun 11 2016

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)