OFFSET
0,4
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..150
Wikipedia, Stirling's Approximation
FORMULA
a(n) = floor(sqrt(2*Pi)*n^(n+(1/2))/e^n). - Wesley Ivan Hurt, Jun 11 2016
MAPLE
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
MATHEMATICA
Table[Floor[Sqrt[2*Pi]*n^(n + 1/2)*Exp[-n]], {n, 0, 50}] (* G. C. Greubel, Jun 11 2016 *)
PROG
(PARI) for(n=0, 50, print1(floor(sqrt(2*Pi)*n^(n+(1/2))*exp(-n)), ", ")) \\ G. C. Greubel, Aug 16 2018
(Magma) R:= RealField(); [Floor(Sqrt(2*Pi(R))*n^(n+(1/2))/Exp(n)): n in [0..50]]; // G. C. Greubel, Aug 16 2018
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
a(12) onwards corrected by Sean A. Irvine, Jun 11 2016
STATUS
approved