Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.math.mathematica

Topic: Formula Stirlinga
Replies: 4   Last Post: May 4, 2013 4:22 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
Bill Rowe

Posts: 1,647
Registered: 3/14/08
Re: Formula Stirlinga
Posted: May 4, 2013 4:22 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On 5/1/13 at 9:43 PM, karchevskymi@gmail.com wrote:

>n = 1000; N[n! - Sqrt[2*Pi*n]*(n/Exp[1])^n] = 3.35308734163*10^2563
>Why does Stirling's formula works incorrect?


Stirling's formula is a valid approximation. But the way you are
trying to demonstrate that isn't effective. Note

In[1]:= n = 1000;
N[(Sqrt[2*Pi*n]*(n/E)^n)/n!]

Out[2]= 0.999917

In[3]:= 100 (1 - %)

Out[3]= 0.00833299

That is there is an error of about 0.008%

and

In[4]:= Log[10, n!] + Log[10, %/100]

Out[4]= 2563.53

That is an error of 0.008 amounts to a difference of 10^2563





Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.