Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re(2): Pascal triange...

by gumby (Scribe)
on Jun 19, 2002 at 10:40 UTC ( #175615=note: print w/ replies, xml ) Need Help??


in reply to Re: Pascal triange...
in thread Pascal's triangle...

Ok, it's been communicated that using the entropy function would provide a better approximation to nCr. So here is such a formula:

Let H(eps) := -eps.log_2(eps)-(1-eps)log_2(1-eps) be a binary entropy function.

Then binom(n, eps.n) is approximately equal to 2^(n.H(eps)).

Where eps is short for epsilon.

Update: Note that this uses the more common Stirling formula which is slightly less accurate as it truncates terms in the series (instead of approximating them like the formula i posted before).


Comment on Re(2): Pascal triange...

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://175615]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (8)
As of 2015-07-07 08:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (87 votes), past polls