# Stable in situ sorting and minimum data movement

@article{Munro1990StableIS, title={Stable in situ sorting and minimum data movement}, author={J. Ian Munro and Venkatesh Raman and Jeffrey S. Salowe}, journal={BIT}, year={1990}, volume={30}, pages={220-234} }

In this paper, we describe an algorithm to stably sort an array ofn elements using only a linear number of data movements and constant extra space, albeit in quadratic time. It was not known previously whether such an algorithm existed. When the input contains only a constant number of distinct values, we present a sequence ofin situ stable sorting algorithms makingO(n lg(k+1)n+kn) comparisons (lg(K) means lg iteratedk times and lg* the number of times the logarithm must be taken to give a…

## 16 Citations

### Fast Sorting In-Place Sorting with O(n) Data

- Computer ScienceFSTTCS
- 1991

A new algorithm is developed for the problem that performs only O(n1+e) comparisons (0<e<1 is any fixed constant) in the worst case and this bound on the number of comparisons matches (asymptotically) the best known bound for the same problem with the stability constraint dropped.

### Fast stable in-place sorting withO(n) data moves

- Computer ScienceAlgorithmica
- 2005

A new algorithm is developed for the problem that performs onlyO(n1+ε) comparisons (0<ε<1 is any fixed constant) in the worst case and this bound on the number of comparisons matches (asymptotically) the best known bound for the same problem with the stability constraint dropped.

### Stable minimum space partitioning in linear time

- Computer ScienceBIT
- 1992

This work shows that by a modification of their method the stable0–1 sorting is possible inO(n) time andO(1) extra space and yields a stable minimum space quicksort, which sorts multisets in asymptotically optimal time with high probability.

### Sorting multisets stably in minimum space

- Computer ScienceActa Informatica
- 2005

This paper presents an aminimum space algorithm that sortsstably a multiset in asymptoticallyOptimal worst-case time and develops linear-time in-place algorithms for the following problems, which have interest of their own.

### Selection and Sorting in the “Restore” Model

- Computer ScienceACM Trans. Algorithms
- 2018

The classical selection and sorting problems in a model where the initial permutation of the input has to be restored after completing the computation is considered, which is more relaxed than a read-only memory where the input elements are not allowed to be moved within the input array.

### Solving Geometric Problems in Space-Conscious Models

- Computer Science
- 2009

This thesis designs efficient algorithms in space-conscious models of in-place algorithms, multi-pass algorithms, read-only algorithms, and stream-sort algorithms,and the focus is on fundamental geometric problems, such as 2D convex hulls, 3D conveX Hulls, Voronoi diagrams and nearest neighbor queries, Klee’s measure problem, and low-dimensional linear programming.

### Space-efficient algorithms for computing the convex hull of a simple polygonal line in linear time

- Computer Science, MathematicsComput. Geom.
- 2006

### Space-E.cient Algorithms for Computing the Convex Hull of a Simple Polygonal Line in Linear Time

- Computer Science, MathematicsLATIN
- 2004

It turns out that the problem is as hard as stable partition, and a simple self-contained solution is presented that uses O(log n) space and how to improve it to O(1) space with the same techniques used for stable partition is indicated.

### Constant-Working-Space Algorithms for Image Processing

- Computer ScienceETVC
- 2008

This chapter shows how a number of important fundamental problems can be solved in a highly constrained situation when an input image is given as read-only memory.

## References

SHOWING 1-10 OF 13 REFERENCES

### Sorting with Minimum Data Movement (Preliminary Draft)

- Computer ScienceWADS
- 1989

An in-place algorithm is developed that sorts n distinct elements using linear data movements and making O(n lg n) comparisons on the average, and improves on the existing worst case algorithms that makelinear data movements.

### Stable Sorting and Merging with Optimal Space and Time Bounds

- Computer ScienceSIAM J. Comput.
- 1977

This work introduces two algorithms for stable merging and stable sorting of files. The algorithms have optimal worst case time bounds, the merge is linear and the sort is of order $n \log n$. Extra…

### Quicksort Without a Stack

- Computer ScienceMFCS
- 1986

This work introduces a simple nonrecursive version of Quicksort, which requires only a constant, O(1) additional space because the unsorted subsets are searched instead of stacking their boundaries as in the standard quicksort.

### A generalized, one-way, stackless quicksort

- Computer ScienceBIT
- 1987

This note generalizes the one-way, stackless quicksort of Huang and Knuth to work for any type of sort key. It thus proves that quicksort can run with minimal space inO(N logN) average time.

### The Art of Computer Programming

- Engineering, Physics
- 1968

The arrangement of this invention provides a strong vibration free hold-down mechanism while avoiding a large pressure drop to the flow of coolant fluid.