View Single Post
  #22 (permalink)  
Old 13-February-2008, 09:16 PM
HenrikOlsen's Avatar
HenrikOlsen HenrikOlsen is offline
Order of Kilopi
 
Join Date: Sep 2003
Location: Denmark 55.6773° N 12.3610° E
Posts: 8,766
Send a message via MSN to HenrikOlsen Send a message via Yahoo to HenrikOlsen
Default

Quote:
Originally Posted by mike alexander View Post
(I preface this with the warning that I can never keep the formulas for permutations, subluxations and combinations straight. Although I approve of using factorials in formulae as a way of making math more exciting.)

I think using a pair of dice as illustration is a different problem, since there are six ways to get a total of 7. But that is not the question here.

My example: a and b are running and six people vote. The final tally has to be one of the following:

a b
6 0
5 1
4 2
3 3
2 4
1 5
0 6

There are 7 possible vote totals, of which 1 is a tie. Probability of a tie is 1/7.
With 6 votes cast for two different candidates, you have 26 possible elections.
Of these, there are 6!/((6-n)!n!) ways to get n votes.

a b #of ways to get this
6 0 1 aaaaaa
5 1 6 aaaaab aaaaba aaabaa aabaaaa abaaaa baaaaa
4 2 15 aaaabb aaabab aaabba aabaab aababa aabbaa abaaab abaaba ababaa abbaaa baaaab baaaba baabaa babaaa bbaaaa
3 3 20 aaabbb aababb aabbab aabbba abaabb ababab ababba abbaab abbaba abbbaa repeat with a's and b's swapped to get the rest
2 4 15 bbbbaa bbbaba bbbaab bbabba bbabab bbaabb babbba babbab bababb baabbb abbbba abbbab abbabb ababbb aabbbb
1 5 6 bbbbba bbbbab bbbabb bbabbb babbbb abbbbb
0 6 1 bbbbbb

so given no voter bias, the chances are ~1.5% for one candidate to get all votes, ~9.5% for one to get all but one vote, 23.4% for one to get all but 2, and a whopping 31.25% or almost 1/3 change to get a tie.
__________________
‘To those who regard “crime fiction” as some sacred icon which must follow a rigid formula, I will always be the man who writes 18-syllable haiku.’
Andrew Vachss, Autobiographical essay
Trying to make sense of computers, The Error Log.
Reply With Quote