home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / theory / 2837 < prev    next >
Encoding:
Internet Message Format  |  1993-01-08  |  1.2 KB

  1. Xref: sparky comp.theory:2837 sci.crypt:6557 sci.math:17866 rec.puzzles:8295
  2. Path: sparky!uunet!usna!math3!mdm
  3. From: mdm@math3.sma.usna.navy.mil (Mark D. Meyerson -- math  FACULTY <mdm@sma.usna.navy.mil>)
  4. Newsgroups: comp.theory,sci.crypt,sci.math,rec.puzzles
  5. Subject: Re: Looking for random permutation generation algorithms
  6. Message-ID: <2614@usna.NAVY.MIL>
  7. Date: 8 Jan 93 21:33:46 GMT
  8. References: <1993Jan6.014749.15323@ee.ubc.ca> <1993Jan7.165939.11149@cs.cornell.edu> <2607@usna.NAVY.MIL> <1993Jan8.163909.20820@cs.cornell.edu>
  9. Sender: news@usna.NAVY.MIL
  10. Reply-To: mdm@math3.sma.usna.navy.mil (Mark D. Meyerson -- math  FACULTY <mdm@sma.usna.navy.mil>)
  11. Followup-To: comp.theory
  12. Lines: 13
  13.  
  14. In article <1993Jan8.163909.20820@cs.cornell.edu>, karr@cs.cornell.edu
  15. (David Karr) writes:
  16. |> This is really the major omission from the algorithm.  I had meant
  17. |> to compute both k mod b *and* k div b.  k mod b is used to index the
  18. |> array for the current selection; k div b is then copied to k for the
  19. |> next round.
  20. |> 
  21.  
  22. I agree now.  This seems to be equivalent to the 
  23. straightforward but perhaps harder to code recursive
  24. method.  I've coded and checked Karr's algorithm
  25. for N=1 to 6.
  26.      Mark D. Meyerson
  27.