Three-in-One Sorting Algorithm (original) (raw)

Performance Evaluation of Three Quick-sorting Algorithms on Single and Multi-core Machines.

Ditse Journals of Pure and Applied Sciences (DUJOPAS), 2018

Multi-core processor is an improvement over the Single-core processor architecture and represents the latest developments in microprocessor technology. Performance evaluation of algorithms can be carried out on a computer with different number of processing cores with a view to establish the level of their performances. This research paper carried out performance evaluation studies on three different Sorting algorithms namely: QuickSort-Sequential, QuickSort-ParallelNaive, and QuickSort-ForkJoin on a Single-core and Multi-core processors to determine which of the algorithms has better execution time, and to show the effect of Multi-processor machines on their performances. System.nanotime() benchmark suits was used to measure the performances of these three algorithms. The overall running time of these algorithms were reported and compared. Results showed that the running time of QuickSort-ForkJoin is about 46.62% faster than QuickSort-Sequential, and 31.20% faster than QuickSort-ParallelNaive. Therefore, QuickSort-ForkJoin algorithm exhibits better performance probably due to its divide and conquer approach. Work stealing action is also another reason for this good performance when measured on both single and Multi-core processor. It was also discovered that increase in a number of processing cores in a machine significantly improves the performances of these algorithms.

An Efficient Optimized Sorting Technique Using Combination of Other Techniques

2020

The problem of sorting is a problem that arises frequently in computer programming and though which is need to be resolved. Many different sorting algorithms have been developed and improved to make sorting optimized and fast. As a measure of performance mainly the average number of operations or the average execution times of these algorithms have been compared. There is no one sorting method that is best for every situation. Some of the factors to be considered in choosing a sorting algorithm include the size of the list to be sorted, the programming effort, the number of words of main memory available,the size of disk or tape units, the extent to which the list is already ordered, and the distribution of values.

Comparative Analysis of Comparison and Non Comparison based Sorting Algorithms

International Journal of Computer Applications, 2020

Sorting is one of the most important task in many computer applications. Efficiency becomes a big problem when the sorting involves a large amounts of data. There are a lot of sorting algorithms with different implementations. Some of them sort data by comparison while others don't. The main aim of this thesis is to evaluate the comparison and noncomparison based algorithms in terms of execution time and memory consumption. Five main algorithms were selected for evaluation. Out of these five, three were comparison based algorithms (quick, bubble and merge) while the remaining two were non-comparison based (radix and counting). After conducting an experiment using array of different data sizes (ranging from 1000 to 35000), it was realized that the comparison based algorithms were less efficient than the noncomparison ones. Among the comparison algorithms, bubble sort had the highest time complexity due to the swapping nature of the algorithm. It never stops execution until the largest element is bubbled to the right of the array in every iteration. Despite this disadvantage, it was realized that it is memory efficient since it does not create new memory in every iteration. It relies on a single memory for the swapping array operation. The quick sort algorithm uses a reasonable amount of time to execute, but has a poor memory utilization due to the creation of numerous sub arrays to complete the sorting process. Among the comparison based algorithms, merge sort was far better than both quick and bubble. On the average, merge sort utilized 32.261 seconds to sort all the arrays used in the experiment while quick and bubble utilized 41.05 and 165.11 seconds respectively. The merge algorithm recorded an average memory consumption of 5.5MB for all the experiment while quick and bubble recorded 650.792MB and 4.54MB respectively. Even though the merge sort is better than both quick and bubble, it cannot be compared to the non-comparison based algorithms since they perform far better than the comparison based ones. When the two groups were evaluated against execution time, the comparison based algorithms recorded an average score of 476.757 seconds while the non-comparison obtained 17.849 seconds. With respect to the memory utilization, the non-comparison based algorithms obtained 27.12MB while the comparison ones obtained 1321.681MB. This clearly reveals the efficiency of the non-comparison based algorithms over the comparison ones in terms of execution time and memory utilization.

Comparative Analysis of five Sorting Algorithms on the basis of Best Case, Average Case, and Worst Case

Sorting is one of the fundamental issues in computer science. Sorting problem gain more popularity, as efficient sorting is more important to optimize other algorithms e.g. searching algorithms. A number of sorting algorithms has been proposed with different constraints e.g. number of iterations (inner loop, outer loop), complexity, and CPU consuming problem. This paper presents a comparison of different sorting algorithms (Sort, Optimized Sort, Selection Sort, Quick Sort, and Merge Sort) with different data sets (small data, medium data, and large data), with Best Case, Average Case, and worst case constraint. All six algorithms are analyzed, implemented, tested, compared and concluded that which algorithm is best for small, average, and large data sets, with all three constraints (best case, average case, and worst case).

A COMPARATIVE ANALYSIS OF SORTING ALGORITHMS WITH FOCUS ON MERGE SORT

In our thesis work, we try to find out the efficiency of several sorting algorithms and generate a comparative report according to performance, based on experimental data size and data order for all algorithm. To do this we have researched, analyzed about 9 different types of well-known sorting algorithms. We convert the algorithms to programmable code, compile and run with different set of data. We keep the sorting algorithm‟s description as it is. We give focus on, how the algorithms work, considering their total operation count (assignment count, comparison count) and complexity based on our same data set for all algorithm. We write programming code for each sorting algorithm in C programming language. In our investigation, we have also worked with big and small data for different cases (ordered, preordered, random, disordered) and put their result in different tables. We show the increasing ratio to compare the result. we also show the data in graphical chart for view comparative report in same window. We mark their efficiency with point and ranked them. At last we discussed their result of efficiency in a single table. We modify the merge sort and try to make an improved tri-merge sorting algorithm that is more efficient than merge sort. Theoretically if we divide and conquer with higher number its result is better, some paper exists on it, but to manage the algorithm, there cost lot of operations count. Like, if we consider quadratic divide-conquer, its manage complexly is huge than binary divide-conquer that why we generally use binary merge. We found tri-merge is theoretically and practically true based on investigation data set. Tri-merge take some more compare operation for manage and sort when data remain 1 or 2 at last stage, whereas binary merge don‟t need such compare. But for big data size tri-merge gain lot of operation count that give significant result that declare tri-merge is more efficient than merge sort algorithm. We also experiment with penta-merge algorithm which give more better result but algorithm and implementation is too complex. We shall try to define the tri-merge algorithm so that it can be used to implement in any programming language. It will help students, researchers to use the algorithm, as like we got the various algorithm structure over the internet.

Technology a Comparative Study of Sorting Algorithm Based on Their Time Complexity

2015

The interest is to develop the fastest sorting algorithm and also efficient in all respect , has become one of the challenges of this century, resulting in many algorithm available to the individual, which needs to sort the list of different data. Presently, we have large number of data, we require some sorting techniques that can sort these data as quick as possible and also gives great efficiency with respect to space as well as time. In this paper, we will discuss some of the sorting algorithms and compare their time complexities for the list of data.

Sorting Algorithms – A Comparative Study

Sorting is nothing but alphabetizing, categorizing, arranging or putting items in an ordered sequence. It is a key fundamental operation in the field of computer science. It is of extreme importance because it adds usefulness to data. In this papers, we have compared five important sorting algorithms (Bubble, Quick, Selection, Insertion and Merge). We have developed a program in C# and experimented with the input values 1-150, 1-300 and 1-950. The performance and efficiency of these algorithms in terms of CPU time consumption has been recorded and presented in tabular and graphical form.

Comparison of Efficiency Data Sorting Algorithms Based on Execution Time

International Journal of Scientific Research in Computer Science, Engineering and Information Technology, 2023

In today's era, the development of information technology is increasingly rapid. This is because human life is currently very dependent on the needs of information technology. This can be proven by the number of human interactions with various gadgets, such as laptops, cellphones, computers, and so on. The development of information technology has made IT activists such as companies and programmers compete in making good applications. One of the most basic things that are mastered in making an application is making algorithms. Currently, there are many types of algorithms. One of them is the data sorting algorithm. In this study, we will try to examine 3 data sorting algorithms, namely Insertion Sort, Quick Sort, and Merge Sort. These three algorithms will be used to sort random data ranging from 1000 to 20,000 data. The three algorithms will be compared in terms of execution time. The results show that the Insertion Sort algorithm is a data sorting algorithm that has the fastest execution time compared to other algorithms, while the Merge Sort algorithm is the most time consuming algorithm compared to other algorithms.

A New Approach To Sorting: Min-Max Sorting Algorithm

2013

Many algorithms are available for sorting the unordered elements. Most important of them are Bubble sort, Heap sort, Insertion sort and Quick sort. This paper presents the new algorithm for sorting the elements which is based on minimum and maximum elements of the array which results in placing the elements at appropriate position. This will reduce the number of passes in which the sorting takes place. We will examine this sorting technique and compare with the other available sorting algorithms in terms of complexity, memory and other factors.