Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Ten Cards Project MTH 496: Dr. Curtis Bennett Fall 2000 JS NN BV Works Cited Bennett, Curtis. MTH 496, Michigan State University: Fall 2000. Contact. Zemeckis and Burgess (directors), Sagan (producer), 1997. Hungerford, Thomas W. Abstract Algebra: An Introduction, Second edition. Saunders College Publishing: Fort Worth, TX, 1997. Thomas, George B., Jr. and Ross L. Finney. Calculus and Analytical Geometry, Ninth edition. Addison-Wesley Publishing Company: Reading, MA, 1996. Wade, William R. An Introduction to Analysis, Second edition. Prentice Hall: Upper Saddle River, NJ, 2000. Page 1 Our group chose this project because we imagined that it was the one that would be the most interesting, curious, and thought provoking on which to work. Luckily for us, it had all of these characteristics. Before beginning to discuss the process our group followed in solving this perplexing question, we must first explain the problem. We were to either use cards 1 through 10 from a deck of playing cards (flipping them one by one), or write a program on the calculator that puts these 10 non-repeating numbers in random order. If any number in the sequence was in the correct position (for example, 2 in the 2nd position), the trial was a failure. If no cards fell in the correct position, the trial was considered a success. We were to look at the total probability of success for 10 cards. For this, we used both cards and a calculator program. The first step was to decide how many trials would be sufficient to provide us with an approximation close enough to our desired, unknown probability. We thought that 1000 card trials and 1000 calculator trials would be sufficient, considering that the greater the number of trials, the closer our probability would be to the unidentified probability. While completing this time consuming process, we also looked at how many failures contained not just 1 card in the correct position, but more than one card in the right place. We were not sure, at the time, if this would help in finding a pattern later. One other item that needed to be considered was consistency in various card trials. To compensate for inconsistency, we decided to shuffle 5 or 11 times for the vast majority of the trials. We felt that 5 would be the least amount of shuffles that would insure a true random placement of the cards. As far as we could tell, this would be the best manner in which to produce concordant random card trials. Page 2 One of our concerns going into the trials was the difference between the successes of the card trials and the calculator trials. So, at the end of this procedure, we were interested to compare the probability of the card trials to those of the calculator. As one can see, the number of successes did not differ greatly, as our results were: 359 – successes out of 1000 card trials 360 – successes out of 1000 calculator trials. These results only differ by 1 success, leading us to believe that both the card and calculator trials could be used to find our total probability for success in using 10 cards. Our final probability was 719 / 2000, or 0.3595. From the description of the problem, it was our assumption that the final probability would relate to a classical number, so these numbers are where our focus landed. After looking at these classical numbers in math (such as and e), we found this result to be very close to 1 / e, or about 0.36788. Our result only differs by about 0.838%. This gave us good reason to attempt to prove that the total probability for success using 10 cards would be 1 / e, or e^-1. We began this proof with the method most obvious to us; enumerate as many cards as possible. After writing out all possible permutations for cards 1 through 5, the number of successes for each were examined, as we looked for any patterns that might appear. The results were as follows: Cards: Probability for success: 1 2 3 0/1 1/2 2/6 4 5 9 / 24 44 / 120. Page 3 The pattern that we saw is: add the previous two number of successes and multiply by (n – 1), n being the card number for which one wants a probability. Since the total permutations are known (n!), the new probabilities can be found. Now, we had to prove that this pattern is true. In order to do this, we needed to look at the breakdown of permutations for each number of cards. For this, we had: 3 cards 4 cards 21_ -| 0 2143 -| 231 -| 1 2341 -| 2413 -| 5 cards 1 21453 -| 21534 -| 6 cards 2 9 2 23154 -| 23451 | 23514 | | 24513 | 24531 | 24153 | | 25134 | 25413 | 25431 -| 9 44 Now that we have seen how the numbers relate to one another, we could use a 1 – 1 mapping to show that the probability of the (n – 1) card directly contributes to the probability of the n-th card. Initially, we struggled to find a way to prove our findings and to show that the probability converges to 1 / e, or e^-1 (as will be seen later). Throughout the semester, we discussed many different possibilities of where to start our proof. Among these were Page 4 ideas such as: what to do with summations, exponents, and factorials; proof by contradiction (week seven); analogous proofs to those of the Taylor and Maclaurin series; induction of a series (proven later); one-to-one and onto mapping (also proven later); and the extreme case of enumerating the permutations for cards 7 through 10 (which would be over three million possibilities, obviously a little tedious). We saw relationships existing between n, (n – 1), (n – 2), and (n + 1) cards. For example, the 23 to the 2_ successes for n cards, compared to the 21 success of the (n + 1) cards. First, n cards can be broken up into n subsets (1---------, 2---------, … , n---------). So, we want to then prove that each subset contains the same amount of successes. In the next 4 cases, we used the previously mentioned one-to-one and onto mapping technique to show that these subsets have an equal number of successes. We will now define some terms in order to prove the mapping through these cases. I) A function f: BC is said to be injective (or one-to-one) provided that whenever f(a) = f(b) in C, then a = b in B. II) A function f: BC is said to be surjective (or onto) provided that every element of C is the image under f of at least one element of B, that is, if cC, then there exists bB such that f(b) = c (Hungerford 511-512). Page 5 CASE 1: Starting with 21, we would keep the 21 in its beginning position, and subtract 2 from every other number, showing us that there is an injective map from n to (n – 2). To show that there is an inverse (showing an onto mapping), we would add 2 to the (n – 2) success permutation, and put the result after the 21 in the n success permutation. Therefore, it is surjective; hence, the function is bijective. For example, for the trials with 6 cards, we have the permutation 214365. By ignoring the 21 (because we are now dealing with (n – 2) cards), and subtracting 2 from each other number, we get a permutation of 2143, a successful permutation for 4, or (n – 2) cards. Obviously, the same can be done in the reverse action. Adding 2 to 2143 (in the (n – 2) case) to get 4365, and putting it on the end of the 21 case for n, we get the successful result of 214365. CASE 2: By not starting with 21 (i.e., starting with 23, 24, … , 2n), we would now keep the 1 in the same position, and then subtract 1 from each other number, showing there is an injective map from n to (n – 1). To show that there is an inverse (showing onto mapping again), we would now add 1 to the (n – 1) success permutation, leaving the 1 in its original position, and put the result after the 2 in the n success permutation. Therefore, it is surjective; hence, the function is bijective. For example, for the trial with 6 cards, we have the permutation 261345. If we subtract 1 from each number, leaving 1 in its original position, we would get 51234, a successful permutation for 5, or (n – 1) cards. Conversely, if we take the successful permutation 51234 for 5 cards and add 1 to Page 6 each number except 1, we will get 61345; when we put in for the second through sixth positions, beginning with 2, we get 261345, or a successful permutation for 6 cards. Theorem (NBJ Theorem): With n cards, the number of successes with 2 not in the right position equals the number of successes with k not in the right position, where k is an integer from 1 to n, and not equal to 2. Proof: CASE 3: In the successful permutation where k is not in the second position, we would simply switch 2 and k to get a new, successful permutation. Conversely, if we switch k and 2 in a successful permutation, we would again get a successful permutation. Hence, there is a one-to-one and onto correspondence; therefore, it is bijective. For example, in the successful permutation of 24153 within the 5 card permutations with k = 3, we could switch 2 with 3 and still get a successful permutation of 34152. If we want to show its inverse, we could just switch the 3 and the 2 in our new permutation to make 34152 become 24153 again. This is also a successful permutation. By using our definition of a success, we know that 3 cannot be in the right position from injectivity, and we know that 2 cannot be in the right position from surjectivity. Therefore, when we switch back and forth as we are doing, we will still not get any numbers in the correct position. However, in the case where k is in the second position (strictly dealing with permutations beginning with 2), this switching will not be allowed. For this example, we need to do something different. Page 7 CASE 4: If k is exchanged with the first digit and creates a failure, we must: switch the first position to the k-th position, move k to the 1st position, move the digit in the k-th position into the 2nd position, and leave the other numbers in there original position. This creates a new, successful permutation. Conversely, to show that there exists an inverse, we move the k-th position to the 1st position, the 2nd position to the k-th position, and the digit k to the 2nd position. Now, we have injectivity and surjectivity; hence, the function is a bijective map. Let us see an example. Take the case with 5 cards with the successful permutation, 24513. Let k = 4, and let 1 be in the k-th position (i.e., the k = 4th position). Going through our motions, we move the 1st position (the 2) to the k-th position (or 4th position); we move k = 4 to the 1st position; we move the number in the k-th position (1) to the 2nd position, and leave the 5 and 3 in the same positions. By doing this, we get a new, successful permutation, 41523. Essentially, showing the inverse is true means to change the order around. So, if we are dealing with the successful permutation, 41523, we: move the number in the k-th position (2) to the 1st position, move the digit in the 2nd position (1) to the k-th position, move the digit k = 4 to the 2nd position, and leave the rest in place. We then get the successful permutation, 24513. Since each case is bijective (i.e., do not overlap and include every successful permutation only once), we now know that all subsets of n cards are also bijective. Furthermore, the number of successes are equal for every subset (except the 1------subset, where it is 0). Then, if bn = successes in each subset, we have (n – 1)bn + 0 as the Page 8 total successes for the n-th card, and 0 = successes of the 1 subset. We have now shown how this pattern can be derived. From this pattern, we can compute the remaining probabilities of success for cards 7 through 10. These turn out to be: Cards: 7 Probability: 1854 / 5040 8 14833 / 40320 9 133496 / 362880 10 1334961 / 3628800 If one looks closely at the values of these probabilities, one will see that the values oscillate above and below the value e^-1. Therefore, we needed to show that the probability values for the cards converge to e^-1. To do this, we must examine the Maclaurin series expansion of e^x (where the Maclaurin series is a special case of a Taylor series). By definition, this is: e^x = (x^n / n!), from n = 0 to infinity (Thomas 680). If we substitute x = -1, we get: e^-1 = (-1^n / n!), from n = 0 to infinity. This gives us: (1 – 1) + 1 / 2 – 1 / 6 + 1 / 24 – 1 / 120 + 1 / 720 – 1 / 5040 + 1 / 40320 – 1 / 362880 + 1 / 3628800 … Page 9 These are the first 10 elements of the Maclaurin series, which directly coincide with the probabilities we found for each card numbering 1 though 10. But, to show that this process continues to infinity, we need to use the inductive procedure. INDUCTIVE PROOF We will let an = the number of successes of the n-th card. We will also let an-1 = the number of successes for (n – 1) cards. The probability of an is: p(an) = an / n! (Wade 13). We know from our 1 – 1 proof that an = (n – 1)bn-1. So from this we can say that an+1 = n(bn). We also know from our 1 – 1 proof that bn = an + an-1. By substitution: an+1 = n(an + an-1). So by induction, we will need to show that if a0 = 1 and a1 = 0, and assuming the case of ak is true, that the case of ak+1 / (k + 1)! = ((ak + ak-1)k) / (k + 1)! works. 1a) As we defined an, if there are no cards to lay down, there is only one way to lay zero cards, hence it is always a success and thus a0 = 1, since zero cards will never have any cards in their correct positions. 1b) Similarly for the case with one card (the 1), there is never a possibility of success, and hence a1 = 0. Page 11 This implies that if we had an infinite amount of cards, the total probability for success would be congruent to this Maclaurin series expansion. This means that the total probability for success would equal e^-1, and our proof is complete. We would like to explore other interesting topics surrounding this project though. The first is the amount of error present by using only 10 elements of the Taylor expansion, instead of infinitely many. We will then compare it to the error percentage we have found earlier. To do this, we use the remainder function for infinite series. Since x is less than 0, we use the function: | Rn (x) | < | x |^(n + 1) / (n + 1)! With x = -1, we have: So, = | Rn (-1) | < 1 / 11! = 2.505 x 10^-8 (Thomas 679) | Rn (-1) | < | -1 |^(n + 1) / (n + 1)! 2.505 x 10^-8 / e^-1 = 6.81 x 10^-8. This implies that we have a (6.81 x 10^-6)% error by truncating the Maclaurin series to only 10 elements. The percent error computed from our trials that we found earlier was 0.838%. This tells us that 2000 trials were sufficient, yet not precise. Therefore, this trial process allowed us to form a notion of the probability to which it converges, but a proof was necessary. This is what was previously shown. Page 12 Another interesting thing that we saw along the way relates e to the probability of getting 2, 3, 4, and even 5 and 6 cards in the correct positions! Here are our results: 2 cards in the correct position 267/1500 = 0.178… Hmmm… 1/e^2 = 0.135… 3 cards in the correct position 97/1500 = .064666… 1/e^3 = 0.0497… 4 cards in the correct position 28/1500 = 0.018666… 1/e^4 = 0.0183… 5 cards in the correct position 1/1500 = 6.6…x 10^-4 1/e^5 = 6.7…x10^-3 6 cards in the correct position 1/1500 = 6.6…x 10^-4 1/e^6 = 2.47…x10^-3 While these number do not match up exactly, it is just one thought of the number to which the probability of getting more than 1 card in the correct position may converge. We understand that an illogical correlation between these numbers exists, but it was an area of interest that we wished to touch upon. This just got us thinking more about these mystifying classical numbers. Still, an unsettling feeling remains… Why does e show up in this problem? We will probably never fully understand this question or the manifolds of the universe; what things are true—how and why are they true? One thing is certain—humans seem to seek truth, including answers to these types of questions. This brings up ideas way beyond the context of this class: ideas surrounding philosophy (the love of knowledge, from a Latin derivation: philo—love, sophia—knowledge), ideas about a Creator who used order in his plan, as well as what mathematics is. We wish not to argue these things, but it is a possible platform for many of the similarities we see with mathematics throughout nature. Page 13 “I do not believe that God plays dice with the universe.” –Albert Einstein In this way, we may begin to see some order to the universe through mathematics. For this reason, mathematics is arguably the “universal language” on this planet. Furthermore, it may be the language of the universe because it is able to tell us some very important truths (see the movie Contact). At the same time, this is all just theory—but after all, are not the physical sciences merely theories? As students and cunning mathematicians, we have explored many things about math, including the fact that e and appear all over the place within the realm of mathematics. We have defined them as “classical numbers”; they are a way for us to understand patterns of the world. The possibility of divine order is what we see with reason and intuitive logic; it is the things that we understand through “functions” like ex, as well as numbers such as e and . This is all a part of the infinite complexities that are all around us that we do not fully understand. Through this project, for example, we have found some patterns, and they all point to e as their end. Perhaps it relates to some ideas about infinity. Our probability of success, 1 / e, comes from the function ex, where x = -1. Let us take a look at the derivative of ex, where x is a Complex number: f(x) = ex f’(x) = ex f’’(x) = ex : : f(n)(x) = ex Page 14 In other words, the infinite derivative of ex is still the same function, ex; it does not go away. If there is an ultimate order to the universe, it seems that there must be infinitely many complexities for which functions such as ex are used and do not go away. Then, the idea of infinity connects us to many problems of mathematics in the physical, as well as abstract, world. We cannot explain them, but they are there. And it is interesting talking about them! The truth is that there exist (infinitely?) many applications through the order of mathematics, like our found probability. Meanwhile, as to exactly why e shows up with the probability of our card trials, we can only guess that there is an underlying order to many, many things that we have only begun to explore and understand. There is no simple answer. However, exploring truths of the world is one way to motivate mathematics and classical numbers such as e in the classroom. We found it very fascinating that many interesting places exist in which classical numbers show up. For instance, it has been shown that the “face” on Mars has dimensions proportional to “e”! The rows of pines on a pineapple represent the numbers in the Fibonacci sequence, while the average distance from a secondary branch and the trunk of a tree compared to the distance between a tertiary branch and its primary branch is (1 + sqrt 5) / 2, or the Golden Ratio. This ratio also appears in the human body. The ratio of the lengths between the joints of the arm and hand follows this pattern as well. These are just interesting side-notes of places where classical numbers may appear outside of the classroom. This problem of knowing where and how to look is just one Page 15 aspect of what we needed to do to complete this project involving the probability of a success for 10 cards. As one can see, this was an extremely engaging topic that uses many aspects of mathematics to solve. It was exciting to see how this enigmatic and mysterious number, e, has once again found its way into our math class. Only this time, it was in a manner and place that none of us had expected.