Poisson as Limit of Binomial
Limiting Distributions-Poisson Distribution
We begin by considering a random variable with Binomial distribution . This means that .
sage: def binom(k,p,r):
... return N(binomial(k,r)*p^r*(1-p)^(k-r))
We now plot the frequency plot of for a fixed and varying over some range.
sage: p=1/2
sage: binoms=[bar_chart(map(lambda r:binom(k,p,r),range(k+1)),color='gray',width=0.2)
sage: for k in range(4,31)]
We animate this sequence of plots.
sage: binanim=animate(binoms,xmin=0,xmax=21,ymin=0,ymax=0.5,figsize=[6,4])
Looking at all the charts together, we see that:
- Since the expectation keeps increasing with , the centre of the plot moves to the right.
- The height of the peak decreases and the distribution "flattens out".
sage: binanim.show(delay=100)
We now take the random variable whose distribution is given by for some fixed value of . The mean of this sequence of distributions remains fixed and converge to a random variable which has the Poisson Distribution
sage: c=0.9
sage: pois=bar_chart(map(lambda r:c^r*exp(-c)/factorial(r),range(6)), width=0.3,color="orange") # This is the Poisson
sage: plseq=[pois+bar_chart(map(lambda r:binom(2*k,c/(2*k),r),range(6)),color='gray',width=0.15)
sage: for k in range(1,30)] # These are all the Binomials
sage: poisanim=animate(plseq,xmin=0,xmax=6,ymin=0,ymax=c/2,figsize=[6,4])
sage: poisanim.show(delay=70)
Last modified: Thursday, February 18, 2016, 8:46 AM