By combining binary search and insertion sort, a sorting method for small input size
-
Bhawnesh Kumar
Abstract
Insertion sort, one of the popular sorting methods having average time complexity O(n2), is based on the decrease and conquer strategy. We insert elements one by one in the sorted part and decrease the size of the unsorted portion, instead of a simple comparison method for insertion of elements in the sorted portion if we apply the binary search approach to locate the appropriate position for the inserting element in the sorted part. This will reduce the number of key comparisons; the only problem with this approach is to shift the elements one place to its right which are greater than A[i]. But the convergence of this approach toward the result is fast than the simple insertion sort. As far as time complexity is concerned both have almost similar performance, but when the cost of comparison is high this method is well suited.
Abstract
Insertion sort, one of the popular sorting methods having average time complexity O(n2), is based on the decrease and conquer strategy. We insert elements one by one in the sorted part and decrease the size of the unsorted portion, instead of a simple comparison method for insertion of elements in the sorted portion if we apply the binary search approach to locate the appropriate position for the inserting element in the sorted part. This will reduce the number of key comparisons; the only problem with this approach is to shift the elements one place to its right which are greater than A[i]. But the convergence of this approach toward the result is fast than the simple insertion sort. As far as time complexity is concerned both have almost similar performance, but when the cost of comparison is high this method is well suited.
Kapitel in diesem Buch
- Frontmatter I
- Preface V
- Contents VII
- Machine learning-enabled techniques for speech categorization 1
- Comprehensive study of cybersecurity issues and challenges 21
- An energy-efficient FPGA-based implementation of AES algorithm using HSTL IO standards for new digital age technologies 41
- A comparative study on security issues and clustering of wireless sensor networks 55
- Heuristic approach and its application to solve NP-complete traveling salesman problem 69
- Assessment of fake news detection from machine learning and deep learning techniques 87
- Spam mail detection various machine learning methods and their comparisons 119
- Cybersecurity threats in modern digital world 137
- Mechanism to protect the physical boundary of organization where the private and public networks encounter 149
- By combining binary search and insertion sort, a sorting method for small input size 167
- Index 179
Kapitel in diesem Buch
- Frontmatter I
- Preface V
- Contents VII
- Machine learning-enabled techniques for speech categorization 1
- Comprehensive study of cybersecurity issues and challenges 21
- An energy-efficient FPGA-based implementation of AES algorithm using HSTL IO standards for new digital age technologies 41
- A comparative study on security issues and clustering of wireless sensor networks 55
- Heuristic approach and its application to solve NP-complete traveling salesman problem 69
- Assessment of fake news detection from machine learning and deep learning techniques 87
- Spam mail detection various machine learning methods and their comparisons 119
- Cybersecurity threats in modern digital world 137
- Mechanism to protect the physical boundary of organization where the private and public networks encounter 149
- By combining binary search and insertion sort, a sorting method for small input size 167
- Index 179