Sorting Using Complete Subintervals and the Maximum Number of Runs in a Randomly Evolving Sequence

被引:3
作者
Janson, Svante [1 ]
机构
[1] Uppsala Univ, Dept Math, SE-75106 Uppsala, Sweden
关键词
sorting algorithm; runs; priority queues; sock-sorting; evolution of random strings; Brownian motion; BROWNIAN-MOTION; LIST STRUCTURES; MEAN PATH; SIZE;
D O I
10.1007/s00026-009-0007-z
中图分类号
O29 [应用数学];
学科分类号
070104 ;
摘要
We study the space requirements of a sorting algorithm where only items that at the end will be adjacent are kept together. This is equivalent to the following combinatorial problem: Consider a string of fixed length n that starts as a string of 0's, and then evolves by changing each 0 to 1, with the n changes done in random order. What is the maximal number of runs of 1's? We give asymptotic results for the distribution and mean. It turns out that, as in many problems involving a maximum, the maximum is asymptotically normal, with fluctuations of order n (1/2), and to the first order well approximated by the number of runs at the instance when the expectation is maximized, in this case when half the elements have changed to 1; there is also a second order term of order n (1/3). We also treat some variations, including priority queues and sock-sorting. The proofs use methods originally developed for random graphs.
引用
收藏
页码:417 / 447
页数:31
相关论文
共 25 条
[1]  
AFHALLSTROM G, 1952, ANN ACAD SCI FE AIMP
[2]  
[Anonymous], 2005, Probability: A Graduate Course
[3]   BROWNIAN-MOTION AND A SHARPLY CURVED BOUNDARY [J].
BARBOUR, AD .
ADVANCES IN APPLIED PROBABILITY, 1981, 13 (04) :736-750
[4]  
BARBOUR AD, 1975, J ROY STAT SOC B MET, V37, P459
[5]  
Billingsley P., 1968, CONVERGENCE PROBABIL
[6]  
Daniels H., 1974, ADV APPL PROBAB, V6, P607, DOI DOI 10.2307/1426182
[7]   THE MAXIMUM OF A GAUSSIAN PROCESS WHOSE MEAN PATH HAS A MAXIMUM, WITH AN APPLICATION TO THE STRENGTH OF BUNDLES OF FIBERS [J].
DANIELS, HE .
ADVANCES IN APPLIED PROBABILITY, 1989, 21 (02) :315-333
[8]   THE MAXIMUM OF A RANDOM-WALK WHOSE MEAN PATH HAS A MAXIMUM [J].
DANIELS, HE ;
SKYRME, THR .
ADVANCES IN APPLIED PROBABILITY, 1985, 17 (01) :85-99
[9]   THE ANALYSIS OF SIMPLE LIST STRUCTURES [J].
FLAJOLET, P ;
PUECH, C ;
VUILLEMIN, J .
INFORMATION SCIENCES, 1986, 38 (02) :121-146
[10]  
Flajolet P, 1980, J ALGORITHMS, V1, P111