Let @@@@ = {R<subscrpt>1</subscrpt>,R<subscrpt>2</subscrpt>,…,R<subscrpt>M</subscrpt>} be an ordered set of M elements where R<subscrpt>i</subscrpt> < R<subscrpt>j</subscrpt> whenever i < j. Let π be the set of permutations of @@@@. We consider the problem of randomly generating the elements of π according to a distribution G(π). Various algorithms including those due to Durstenfeld [D2, K1] and Moses <italic>et al</italic> [M1] are available for the case when the distribution G(π) is a uniform distribution (i.e., where all the elements of π are generated with equal probability). In this paper we consider the case when the distribution G(π) is not necessarily uniform. We present a strategy for specifying the distribution G(π) and propose a technique for generating the elements of the π according to the distribution G(π). Applications of the technique to generate “almost sorted lists” and in the Travelling Salesman Problem have been presented. Finally, simulation results have been included which demonstrate the power of the Random Permutation Generation (RPG) technique.
[1]
Sheldon M. Ross,et al.
Stochastic Processes
,
1982
.
[2]
Edsger W. Dijkstra,et al.
Smoothsort, an Alternative for Sorting In Situ
,
1982,
Sci. Comput. Program..
[3]
Curtis R. Cook,et al.
Best sorting algorithm for nearly sorted lists
,
1980,
CACM.
[4]
W. Worlton,et al.
The Art of Computer Programming
,
1968
.
[5]
J. M. S. Simões-Pereira,et al.
Algorithm 235: Random permutation
,
1964,
Commun. ACM.
[6]
R. V. Oakford,et al.
Tables of Random Permutations
,
1963
.
[7]
D. Knuth.
The art of computer programming: sorting and searching (volume 3)
,
1973
.