* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download binomial coefficient and the gaussian
Survey
Document related concepts
Transcript
BINOMIAL COEFFICIENT AND THE GAUSSIAN The binomial coefficient is defined asC (n, k ) = n! k!(n − k )! and can be written out in the form of a Pascal Triangle starting at the zeroth row with element C(0,0)=1 and followed by the two numbers C(1, 0)=1 and C(1, 1)=1 in the first row. The second row produces the numbers [1, 2, 1] and the third row the four numbers [1, 3, 3, 1]. The row number is here given by the value of n, and the number of elements in a row will be n+1. From these first few results one can state that- C (n, k ) + C (n, k + 1) = C (n + 1, k + 1) The Pascal Triangle thus reads1 1 1 1 2 1 1 3 3 1 1 4 6 4 1 1 5 10 10 5 1 1 6 15 20 15 6 1 1 7 21 35 35 21 7 1 1 8 28 56 70 56 28 8 1 1 9 36 84 126 126 84 36 9 1 It is known that the numbers in the individual rows of this triangle also give the coefficients in the binomial expansion of (a+b)^n. Thus, for example, for n=4, we have (a + b) 4 = a 4 + 4a 3b + 6a 2b 2 + 4ab3 + b 4 One also notices that the binomial coefficients for fixed n are symmetric about their central maximum value. Plotting their normalized values at n=72 with -15<k<15 we get the graph- We have superimposed on these values the Gaussian exp(-k^2/36). The results are almost identical. Indeed as n is allowed to become large one has the result- exp(−2k 2 / n) ≈ [(n / 2)!]2 [(n / 2)!]2 C (n, k + n / 2) = n! (n / 2 + k )!(n / 2 − k )! with n>2k. At n=128 and k=8 one finds- exp(1) ≈ 128! 2 [64! C (128,72)] = 2.704150286… which is close to the correct value of 2.718281828.. An even better approximation occurs when k is near zero since the two sides of the equation are normalized at k=0. So keeping k=1 and k<<n, we find- N + 2 exp(1) ≈= N N This yields the approximation 2.71801005.. for N=10,000. Note that one can also use the Stirling Approximation for large n. It gives, for example, the estimaten +1 / 2 C (n, k ) ≈ 1 n [ ] 2π k k +1 / 2 (n − k ) n − k +1 / 2 for n >> 1 which yields the approximation C(1000,500)≈0.270355…·10^300 compared to the exact value of C(1000,5000)=0.270288…·10^300. Going back to the Pascal Triangle given above one notices the following2 ∑ C (2, k ) = 1 + 2 + 1 = 2 2 k =0 3 C (3, k ) = 1 + 3 + 3 + 1 = 23 ∑ k =0 4 ∑ C (4, k ) = 1 + 4 + 6 + 4 + 1 = 2 4 k =0 From this it follows that- n ∑ C ( n, k ) = 2 k =0 n . One also notices that if C(n,1) is prime then C(n,k)/C(n,1) is an integer provided 0<k<n. Furthermore a violation of this condition indicates that the number is composite . Thus one has thatC ( n, k ) ( N − 1)! 1 k −1 N is prime if T (k ) = C (n,1) = k!( N − k )! = ∏ ( N − n) k! n =1 is an integer for all values of k ranging from k=1 through k=N/2. Any violation will indicate the number N is composite. Consider the number N=177. On running the one line MAPLE programfor k from 1 to 60 do {k,(1/k!)*product((177-n),n=1..k-1)}od; one finds T(3),T(6),T(9),T(12),T(15),T(59) up to k=60 to be non-integer and hence the number is composite. An extra benefit is that one actually finds the factors to be the lowest values of k not multiples of a lower value. Thus k=3 and k=59 in this case, so that 177=3·59. Unfortunately this approach for determining the primeness of a large number will be quite cumbersome and is actually more time consuming than just looking at the ratio N/(2k+1) for 2k+1<sqrt(N). Running the one-linerfor k from 1 to 14 do {2*k+1,177/(2*k+1)}od; already produces an integer for k=1 yielding 177/3=57 so that 177=3(57). Going back to the Pascal Triangle we observe that the sequence of numbers lying on the vertical line dividing the triangle in half is1-2-6-20-70-252-924- … In terms of the C(n,k) coefficient this means the sequence goes asC(0,0)-C(2,1)-C(4,2)-C(6,3)-C(8,4)-…C(2n,n)… Adding the terms together through the 2m th row, we find the Sum(m) to bem m ( 2n)! 2 n = 0 n! Sum(m) = ∑ C (2n, n) = ∑ n =0 For m=6 this sum equals Sum(6)=1+2+6+20+70+252+924=1275. One can also ask for the value of the reciprocal series which converges to the finite value - 1 1 1 1 n!2 =1+ + + + + ... = 1.73639985871871507790979516836… ∑ 2 6 20 70 ( 2 )! n n=0 ∞ We can also work out the seriesn S (n) = ∑ [C (n, k )]2 k =0 It yields S(1)=2, S(2)=6, S(3)=20, and S(4)=70. From this one sees that S(n) sums to C(2n,n). Finally we point out that one can generalize the Pascal Triangle starting with m ones in the first row and then adding the m nearest values in the (n-1) row to find the element in the nth row. For m=3 this will lead to the triangle- 1 1 4 1 5 15 1 6 21 50 1 1 2 3 6 10 16 30 45 90 126 1 1 1 3 2 1 7 6 3 1 19 16 10 4 1 51 45 30 15 5 1 141 126 90 50 21 6 1 etc. with the generating formula- D(n, k ) = D(n − 1, k − 2) + D(n − 1, k − 1) + D(n − 1, k ) Thus D(5,5)=51=16+19+16 and D(6,7)=126=51+45+30. Note that for this m=3 case that the number of elements in the nth row is 2n+1 and they sum to 3^n. The elements in the nth row again have the character of a Gaussian distribution with very small discrepancies noticed near the tails as shown on the following graph- . Comparing this result and that for the classic Pascal triangle, we can conclude that- m ones in the first row of a modified Pascal Triangle will lead to a triangle whose elements in the nth row number [(m-1)n]+1 and add up to m^n. The element F(n,k) of such a modified Pascal Triangle will be given byF(n,k)= F(n-1,k-m+1)+F(n-1,k-m+2)+……..+F(n-1,k) Also one notes that there is a generating function for the coefficients F(n,k) for a given value of m . For example at m=3 the generating function is G=1+x+x^2 which has coefficients [1,1,1] and corresponds to the first row of D(1,k). G^2=1+2x+3x^2+2x^3+x^4 has the coefficients [1,2,3,2,1] and thus yields the coefficients D(2,k). For m=3 and n=6 we find12 (1 + x + x 2 ) 6 = ∑ D(6, k ) x k = 1 + 6 x + 21x 2 + 50 x 3 + 90 x 4 + 126 x 5 + 141x 6 k =0 + 126 x 7 + 90 x 8 + 50 x 9 + 21x10 + 6 x11 + x12 December 2009