login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A260657 Rounded error in Stirling's formula: a(n) = round(n! - exp(-n)*n^(n+1/2)*sqrt(2*Pi)). 1
1, 0, 0, 0, 0, 2, 10, 60, 418, 3343, 30104, 301175, 3314114, 39781325, 517289459, 7243645801, 108675472777, 1739099429899, 29569079533691, 532313816538037, 10115161415506606, 202324846199795597, 4249233149373416698, 93491368355657653179, 2150474710445177712523 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,6

LINKS

G. C. Greubel, Table of n, a(n) for n = 0..200

FORMULA

a(n) ~ exp(-n)*n^(n-1/2)*sqrt(2*Pi)/12.

MATHEMATICA

Table[Round[n! - Exp[-n] n^(n+1/2) Sqrt[2 Pi]], {n, 0, 24}]

PROG

(Sage)

def a(n): # Throws an error if result could not be computed exactly.

    rif = RealIntervalField(max(4, 10*n))

    r = rif(factorial(n)-(n^(1/2+n)*sqrt(2*pi))/exp(n))

    return r.unique_round()

for n in (0..100): print(n, a(n)) # b-file style; Peter Luschny, Nov 18 2015

CROSSREFS

Cf. A000142.

Sequence in context: A276310 A098616 A082042 * A079856 A073329 A290446

Adjacent sequences:  A260654 A260655 A260656 * A260658 A260659 A260660

KEYWORD

nonn

AUTHOR

Vladimir Reshetnikov, Nov 13 2015

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 25 19:39 EST 2021. Contains 341618 sequences. (Running on oeis4.)