MathGroup Archive 1999

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Permutations & Computer capacity

  • To: mathgroup at smc.vnet.net
  • Subject: [mg16962] Re: Permutations & Computer capacity
  • From: "David Bailey" <dave-bailey at freeuk.com>
  • Date: Thu, 8 Apr 1999 02:32:52 -0400
  • References: <7ec4ji$alq@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

Actually, even for Permuations[Range[9]] the computer memory is going to get
quite full - just holding the answer!The ByteCount of a 9-element list is
200 and 9!>300,000.. The n=10 case is overwhelmingly large. Also, without a
semicolon the frontend would have choked on the output if you had managed to
generate it.

David Bailey

Francisco Gutierrez wrote in message <7ec4ji$alq at smc.vnet.net>...
>
>I developed a notebook to evaluate the Shapley value (votation power) of
>a list of parties in a committee.  A list to be evaluated looks like:
>{{partyA, 5}, {partyB, 8}...{partyn, X}}
>
>Everything works ok but...disgracefully producing the Shapley value implies
>working with permutations.  This means making n! evaluations (n the length
>of the list).
>
>And when I have a list of more than 8-9 parties, the program gets stuck.
>Now, 9! is not such a big number.
>
>I thought that perhaps my programming was not efficient enough, so I made
>the following try:
>Range[12]
>Permutations[%]
>After a couple of minutes, I got the answer "Exiting-out of memory"
>I have a Pentium II with 128 RAM, 4 free gigas in hard disk and a 300 and
>something processor (my platform is windows 95).
>
>Is there something wrong with my computer? Is there a way to overcome this
>limitation?
>
>Many thanks
>
>Francisco Gutierrez
>
>




  • Prev by Date: Re: Eigenvalue Problem
  • Next by Date: Need help about how to bring image to clipboard?
  • Previous by thread: Re: Permutations & Computer capacity
  • Next by thread: Re: Permutations & Computer capacity