Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #87030
| From | Gene Heskett <gheskett@wdtv.com> |
|---|---|
| Subject | Re: Speeding up permutations generation |
| Date | 2015-03-06 11:14 -0500 |
| References | <CADgpKWb=q2=YEJSS1yRkgzF37nO5BNRnywm+zhcwF-MAOr6MdA@mail.gmail.com> <201503060532.03842.gheskett@wdtv.com> <54F98DFA.4090503@davea.name> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.115.1425658456.21433.python-list@python.org> (permalink) |
On Friday 06 March 2015 06:22:34 Dave Angel wrote: > On 03/06/2015 05:32 AM, Gene Heskett wrote: > > On Friday 06 March 2015 03:24:48 Abhiram R wrote: > >>> A list of 100 elements has approximately 9.33 x 10**157 > >>> permutations. If you could somehow generate one permutation every > >>> yoctosecond, exhausting them would still take more than a hundred > >>> orders of magnitude longer than the age of the universe. > >>> -- > >>> https://mail.python.org/mailman/listinfo/python-list > >> > >> True that :D I may have exaggerated on the number. Let's consider > >> something more practically manageable => 50 elements with a 50! > >> permutation. > >> Is there a solution now? > > > > Yes, but its now only 8.881784197e+84 elements so it is still not a > > practical target. Doing all elements of a matrix is generally equ > > to n!, and 50 raised to the 50th power is still a number that will > > probably use up this suns remaining lifetime doing it in assembly. > > Sorry, but 50! is not even close to 50**50. The latter is 85 digits > as you say, but 50! is "only" 64. > > > 30414093201713378043612608166064768844377641568960512000000000000L What utility output that as an L ? But you are right, new wheezy install with TBE desktop and kcalc has been played with. I used the wrong button. It seems every new and streamlined version is progressively stripped of some function I have formerly found useful, Grrrrrr. Not related to this, but now the binary bit display has been excised. Handier than bottled beer when checking/designing address decoders. > Still an enormous number of course, so an exhaustive visit to all > those permutations is still impossible on a conventional computer. +5 > > -- > DaveA Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) Genes Web page <http://geneslinuxbox.net:6309/gene>
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: Speeding up permutations generation Gene Heskett <gheskett@wdtv.com> - 2015-03-06 11:14 -0500
csiph-web