Everything about Library sort
Sorting algorithm
Library sort or gapped insertion sort is a sorting algorithm that uses an insertion sort, but with gaps in the array to accelerate subsequent insertions. The name comes from an analogy:Suppose a librarian were to store their books alphabetically on a long shelf, starting with the As at the left end, and continuing to the right along the shelf with no spaces between the books until the end of the Zs. If the librarian acquired a new book that belongs to the B section, once they find the correct space in the B section, they will have to move every book over, from the middle of the Bs all the way down to the Zs in order to make room for the new book. This is an insertion sort. However, if they were to leave a space after every letter, as long as there was still space after B, they would only have to move a few books to make room for the new one. This is the basic principle of the Library Sort. Wikipedia →
🧭 Start here: a 6-step reading path
- Read the overview: Library sortA 5-minute orientation
- Pick up a classic book: The Titan's CurseThe most-reprinted book on the subject
- Read the landmark paper: The physical map of the whole E. coli chromosome: Application of a new strategy for rapid analysis and sorting of a large genomic libraryCited 1,394 times
- Go sideways: Insertion sortA closely related topic
- Go sideways: Sorting algorithmA closely related topic
📖 Definitions
Noun A form of insertion sort that leaves gaps between elements to accelerate subsequent insertions.
🗂️ The subject at a glance
🏆 Landmark papers (most cited)
The physical map of the whole E. coli chromosome: Application of a new strategy for rapid analysis and sorting of a large genomic library
If you build it, will they sort it? Compost collection in the academic library learning commons
Building a new sort function for a C library
Occ‐U‐Sort Kit: Educational and Career Guidance Through the Library
Starting a Library from Scratch….Again (Well, Sort of)
Performance comparison analysis library communication cluster system using merge sort
📚 Books worth reading
The Titan's CurseRick Riordan · 2007
The Last OlympianRick Riordan · 2008
The Story of Little Black SamboHelen Bannerman · 1900
The wonders of the invisible worldCotton Mather, Increase Mather · 1692
WonderR. J. Palacio · 2001
LuckyAlice Sebold · 1999
Wizard At LargeTerry Brooks · 1988
Alice in rapture, sort ofPhyllis Reynolds Naylor · 1989
Ranked by number of editions on Open Library, a rough measure of how lasting a book is.
🔗 Related topics
- Insertion sort Insertion sort is a simple sorting algorithm that builds the final sorted array (or list) one item at a time by comparisons. It is much less efficient…
- Sorting algorithm In computer science, a sorting algorithm is an algorithm that puts elements of a list into an order. The most frequently used orders are numerical order…
- Approximate membership query filter Approximate membership query filters (hereafter, AMQ filters) comprise a group of space-efficient probabilistic data structures that support approximate…
- Binary heap A binary heap is a heap data structure that takes the form of a binary tree. Binary heaps are a common way of implementing priority queues. The binary…
- List-labeling problem In computer science, the list-labeling problem involves maintaining a totally ordered set S supporting the following operations: insert(X), which inserts…
- Quicksort Quicksort is an efficient, general-purpose sorting algorithm. Quicksort was developed by British computer scientist Tony Hoare in 1959 and published in…
- Merge-insertion sort In computer science, merge-insertion sort or the Ford–Johnson algorithm is a comparison sorting algorithm published in 1959 by L. R. Ford Jr. and Selmer…
- Samplesort Samplesort is a sorting algorithm that is a divide and conquer algorithm often used in parallel processing systems. Conventional divide and conquer sorting…