摘要
针对少量记录排序的应用,对直接选择排序算法进行了挖掘,通过增加记忆功能,使算法性能得到明显提高。改进后的算法在大量记录排序时,较原算法的速度提高1倍以上;在少量记录排序时,是基于比较和移位的排序算法中总体表现最佳的;并且对原序列的有序程度很敏感,原序列相对有序时,速度能大幅度提高。结果表明:该算法很适合少量记录排序、部分排序、较有序记录的排序,以及与快速排序算法的混合使用。
This paper discusses an improved algorithm based on selection sorting, which employs stacks to remember previous compared information. This algorithm takes half of the original time in mass records. As for a small quantity of records, this algorithm is the best on the whole among all the sorting algorithms based on comparison and shift. Moreover, it is sensitive to the ordered degree of the original sort. When the original sort is con^paratively in order, the speed is relatively high. The result shows that this sorting algorithm is quite fit for a small quantity of sorting, portion sorting, comparatively ordered sequence sorting and the combination with quick sort algorithms.
出处
《苏州科技学院学报(自然科学版)》
CAS
2007年第2期70-73,共4页
Journal of Suzhou University of Science and Technology (Natural Science Edition)
基金
苏州科技学院科研基金指导性项目(DZ0603)
关键词
排序算法
选择排序
比较
时间复杂度
sorting algorithm
selection sort
comparison
time complexity