An algorithm for merging heaps (Q797280): Difference between revisions

From MaRDI portal
RedirectionBot (talk | contribs)
Changed an Item
Set OpenAlex properties.
 
(One intermediate revision by one other user not shown)
Property / MaRDI profile type
 
Property / MaRDI profile type: MaRDI publication profile / rank
 
Normal rank
Property / full work available at URL
 
Property / full work available at URL: https://doi.org/10.1007/bf00264229 / rank
 
Normal rank
Property / OpenAlex ID
 
Property / OpenAlex ID: W2518525525 / rank
 
Normal rank

Latest revision as of 08:47, 30 July 2024

scientific article
Language Label Description Also known as
English
An algorithm for merging heaps
scientific article

    Statements

    An algorithm for merging heaps (English)
    0 references
    0 references
    0 references
    1985
    0 references
    We present an algorithm to merge priority queues organized as heaps. The worst case number of comparisons required to merge two heaps of sizes k and n is \(O(\log(n)*\log(k)).\) The algorithm requires \(O(k+\log(n)*\log(k))\) data movements if heaps are implemented using arrays and \(O(\log(n)*\log(k))\) for a pointer-based implementation. Previous algorithms require either \(O(n+K)\) data movements and comparisons, or \(O(k*\log(\log(n+k)))\) comparisons and \(O(k*\log(n+k))\) data movements. The algorithm presented in this paper improves on the previous algorithms for the case when \(k>\log(n)\).
    0 references
    merging
    0 references
    priority queues
    0 references
    heaps
    0 references

    Identifiers