- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

A soft heap is defined as a variation on the simple heap data structure that consists of constant amortized time for 5 types of operations. This is obtained by carefully "corrupting" (increasing) the keys of maximum a certain number of values in the heap. The constant time operations are −

**create(s)**− Create a new soft heap s**insert(s, y)**− Insert an element y into a soft heap s**meld(s, s' )**of two soft heaps s and s′ into one, destroying both**delete(s, y)**− Delete an element y from a soft heap s**findmin(s)**− Get the element with least key in the soft heap s- Other heaps such as Fibonacci heaps achieve most of these bounds without any corruption, but cannot provide a constant-time bound on the critical delete operation. The amount of corruption can be controlled by the choice of a parameter ε, but the lower this is set, the more time insertions require (O(log 1/ε) for an error rate of ε).
- More precisely, the guarantee offered by the soft heap is the following: for a fixed value ε between 0 and 1/2, at any point in time there will be maximum ε*m corrupted keys in the heap, where m is the number of elements inserted or corrupted W. We can’t guarantee that only a fixed percentage of the keys
*currently*in the heap are corrupted or increased: in an unwanted sequence of insertions and deletions, it can happen that all elements in the heap will have increased or corrupted keys. In same case, there is no guarantee that in a sequence of elements extracted from the heap*with findmin*and delete, only a fixed percentage will have corrupted or increased keys: in an unlucky scenario only corrupted or increased elements are extracted from the heap. - In spite of their limitations and unpredictable nature, soft heaps are useful for designing of deterministic Algorithms. They were implemented to obtain the best complexity to date for determining a minimum spanning tree. They can also be implemented to simply build an optimal selection Algorithm, and near-sorting Algorithms, which are Algorithms that set every element near its final position, a situation in which insertion sort is fast.

- Related Questions & Answers
- Pairing Heaps
- Min-Max Heaps
- Variations of Pairing Heaps
- Symmetric Min-Max Heaps
- Adaptive Properties of Pairing Heaps
- Binomial Heaps in Data Structure
- Fibonacci Heaps in Data Structure
- Interval Heaps in Data Structure
- Hard and Soft Decision Decoding
- The Power of Soft Skills!!
- Meldable Priority Queues and Skew Heaps
- Inserting an Element in Interval Heaps
- How to improve your soft skills?
- Difference between AI and Soft Computing
- Merge two binary Max Heaps using C++.

Advertisements