Berkeley CSUA MOTD:Entry 49714
Berkeley CSUA MOTD
 
WIKI | FAQ | Tech FAQ
http://csua.com/feed/
2025/05/27 [General] UID:1000 Activity:popular
5/27    

2008/4/10-16 [Uncategorized] UID:49714 Activity:nil
4/11    Need a super easy primer URL to learn combination vs. permutation.
        Better if it's meant for kids. Thanks.          -lib art major
        \_ Combination cares about grouping, not order.  Permution includes
           order.  You can convert the number of permutations to combinations
           just by dividing by duplicate group counting due to
           order-sensitivity.
        \_ How about:
           http://preview.tinyurl.com/yo2fwa [math is fun]
Cache (3727 bytes)
preview.tinyurl.com/yo2fwa -> www.mathsisfun.com/combinatorics/combinations-permutations.html
"My fruit salad is a combination of apples, grapes and bananas" We don't care what order the fruits are in, they could also be "bananas, grapes and apples" or "grapes, apples and bananas", its the same fruit salad. Position" Permutations There are basically two types of permutation: 1 Repetition is Allowed: such as the lock above. If you have n things to choose from, and you choose r of them, then the permutations are: n n ... After choosing, say, number "14" you can't choose it again. So, your first choice would have 16 possibilites, and your next choice would then have 15 possibilities, then 14, 13, etc. where n is the number of things to choose from, and you choose r of them (No repetition, order matters) Examples: Our "order of 3 out of 16 pool balls example" would be: 16! Combinations There are also two types of combinations (remember the order does not matter now): 1 Repetition is Allowed: such as coins in your pocket (5,5,5,10,10) 2 No Repetition: such as lottery numbers (2,14,15,27,30,33) 1 Combinations with Repetition Actually, these are the hardest to explain, so I will come back to this later. The numbers are drawn one at a time, and if you have the lucky numbers (no matter what order) you win! The easiest way to explain it is to: * assume that the order does matter (ie permutations), * then alter it so the order does not matter. Going back to our pool ball example, let us say that you just want to know which 3 pool balls were chosen, not the order. We already know that 3 out of 16 gave us 3360 permutations. But many of those will be the same to us now, because we don't care what order. These are the possibilites: Order does matter Order doesn't matter 1 2 3 1 3 2 2 1 3 2 3 1 3 1 2 3 2 1 1 2 3 So, the permutations will have 6 times as many possibilites. In fact there is an easy way to work out how many ways "1 2 3" could be placed in order, and we have already talked about it. Let us say there are five flavors of icecream: banana, chocolate, lemon, strawberry and vanilla. Example selections would be * {c, c, c} (3 scoops of chocolate) * {b, l, v} (one each of banana, lemon and vanilla) * {b, v, v} (one of banana, two of vanilla) (And just to be clear: There are n=5 things to choose from, and you choose r=3 of them. Think about the ice cream being in containers, you could say "skip the first, then 3 scoops, then skip the next 3 containers" and you will end up with 3 scoops of chocolate! So, it is like you are ordering a robot to get your ice cream, but it doesn't change anything, you still get what you want. OK, so instead of worrying about different flavors, we have a simpler problem to solve: "how many different ways can you arrange arrows and circles" Notice that there are always 3 circles (3 scoops of ice cream) and 4 arrows (you need to move 4 times to go from the 1st to 5th container). So (being general here) there are r + (n-1) positions, and we want to choose r of them to have circles. This is like saying "we have r + (n-1) pool balls and want to choose r of them". In other words it is now like the pool balls problem, but with slightly changed numbers. where n is the number of things to choose from, and you choose r of them (Repetition allowed, order doesn't matter) Interestingly, we could have looked at the arrows instead of the circles, and we would have then been saying "we have r + (n-1) positions and want to choose (n-1) of them to have arrows", and the answer would be the same ... But knowing how these formulas work is only half the battle. Figuring out how to interpret a real world situation can be quite hard. But at least now you know how to calculate all 4 variations of "Order does/does not matter" and "Repeats are/are not allowed".