
Also there are no auxiliary arithmetic operations with indices. Our algorithm operates, in the worst case, with at most n log z element comparisons, n log z element moves, and O() auxiliary storage. In this paper, a new in-place sorting algorithm that reduces, simultaneously, the number of comparisons, element moves, and required auxiliary storage will be presented.

This algorithm is of theoretical interest, as the first comparisons-based sorting algorithm to break the bound of (n log for the number of moves. This algorithm uses n log n + O(n log comparisons, O() auxiliary storage, and only O(n log n/log log element moves. The k-way variant has been generalized to a (log n/log log -way in-place merge sort. Here, k denotes an arbitrarily large, but fixed, integer constant, and ε>0 an arbitrarily small, but fixed, real constant. Inplace variants of a with at most n log n + O( comparisons, O() auxiliary storage, and ε n log n + O( moves are presented, instead of merging only blocks, k sorted blocks are merged together at the same time. The heap sort was the first inplace sorting algorithm with time complexity bounded by O(n log in the worst case with O() storage requirements but only performs n log n + O( element moves.

However, the algorithm performs O(n ) element moves, which makes it very slow, especially as n increases. The binary-search version of insert sort requires log n!+n comparisons, and only O() index variables of log n bits each, for pointing to the input array.

Hanan Ahmed-Hosni Mahmoud is with the Information Technology Department, College of Computer and Information Sciences, King Saud University, Riyadh, Saudi-Arabia on leave from the department of Computer and System Engineering, Faculty of Engineering, University of Alexandria ( Nadia Al-Ghreimil, is with the Information Technology Department, College of Computer and Information Sciences, King Saud University, Riyadh, Saudi-Arabia (phone/fax: +9-9, auxiliary storage are of great importance. In-place sorting algorithms, performing O(n log comparisons and, O() Manuscript received September, 00. In-place algorithms play an important role, because they maximize the size of data that can be processed in the main memory without input/output operations. However, the merge sort is not an in-place algorithm, it needs an additional n-element array for sorting n elements. The merge sort Algorithm performs very closely to the optimum, with n log n comparisons. The lower bound for element moves is n log n. Comparison-based algorithms perform, in the average case, at least log n! n log n n log e n log n.n comparisons to sort an array of n elements. INTRODUCTION ORTING is one of the most fundamental problems in the S field of computer science. Keywords Auxiliary storage sorting, in-place sorting, sorting. Finally, the analysis of time and space complexity, and required number of moves are presented, along with the auxiliary storage requirements of the proposed algorithm. Experimental results also show that it outperforms other in-place sorting algorithms. Besides these theoretical achievements of this algorithm, it is of practical interest, because of its simplicity. Further, no auxiliary arithmetic operations with indices are required. The algorithm performs, in the worst case, for an array of size n, an O(n log z) element comparisons and O(n log z) element moves.

The first phase requires linear time, while, in the second phase, elements of each segment are sorted inplace in the order of z log (z), where z is the size of the segment, and O() auxiliary storage. The algorithm comprises two phases rearranging the input unsorted array in place, resulting segments that are ordered relative to each other but whose elements are yet to be sorted. In this paper, a novel in-place sorting algorithm is presented. Such algorithms maximize the size of data that can be processed in main memory without input/output operations. 1 A Novel In-Place Sorting Algorithm with O(n log z) Comparisons and O(n log z) Moves Hanan Ahmed-Hosni Mahmoud, and Nadia Al-Ghreimil Abstract In-place sorting algorithms play an important role in many fields such as very large database systems, data warehouses, data mining, etc.
