Heapsort

E459516

Heapsort is a comparison-based sorting algorithm that uses a binary heap data structure to sort elements in-place with O(n log n) time complexity and O(1) auxiliary space.

All labels observed (2)

Label Occurrences
Floyd’s algorithm for heap construction 1
Heapsort canonical 1

How this entity was disambiguated

Statements (46)

Predicate Object
instanceOf comparison-based algorithm ⓘ
in-place algorithm ⓘ
sorting algorithm ⓘ
averageCasePerformanceComparedToQuicksort often slower in practice ⓘ
basedOn binary tree ⓘ
heap data structure ⓘ
cacheFriendliness moderate ⓘ
canBeImplementedIteratively true ⓘ
canBeImplementedRecursively true ⓘ
category comparison sort ⓘ
selection-based sort ⓘ
extractionPerElementTime O(log n) ⓘ
hasPhase heap construction ⓘ
repeated extraction ⓘ
heapConstructionTime O(n) ⓘ
introducedBy J. W. J. Williams ⓘ
isComparisonSort true ⓘ
isInPlace true ⓘ
isStable false ⓘ
numberOfComparisonsWorstCase O(n log n) ⓘ
numberOfSwapsWorstCase O(n log n) ⓘ
outputOrderForMaxHeap ascending ⓘ
outputOrderForMinHeap descending ⓘ
primaryOperation heapify ⓘ
sift-down ⓘ
relatedAlgorithm Mergesort ⓘ
linked to: Merge sort

Quicksort ⓘ
Selection sort ⓘ
relatedDataStructure binary heap ⓘ
requiresRandomAccess true ⓘ
sortingOrderSupport ascending ⓘ
descending ⓘ
spaceComplexityAuxiliary O(1) ⓘ
suitableForLinkedLists false ⓘ
supportsOnlineSorting false ⓘ
supportsRandomAccessArray true ⓘ
timeComplexityWorstCase O(n log n) ⓘ
typicalImplementationLanguageFeature arrays ⓘ
usedIn systems where worst-case guarantees are important ⓘ
usesDataStructure binary heap ⓘ
usesHeapProperty max-heap ⓘ
min-heap ⓘ
worksOn array of comparable elements ⓘ
array of keys ⓘ
worstCasePerformanceComparedToQuicksort better or equal ⓘ
yearIntroduced 1964 ⓘ

How these facts were elicited

Referenced by (2)

Full triples — surface form annotated when it differs from this entity's canonical label.

Quicksort → comparedWith → Heapsort ⓘ
Robert W. Floyd → notableWork → Floyd’s algorithm for heap construction ⓘ
subject linked to: Robert W Floyd
linked to: Heapsort