Skip to content

Commit b51c7ce

Browse files
committed
Improve documentation
- docstring formatting - full reference - add gif to /docs
1 parent 297348f commit b51c7ce

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

docs/pagedMerge_130_130.gif

786 KB
Loading

src/SortingAlgorithms.jl

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,14 +69,16 @@ the input is merged interleaved from both sides, which increases performance
6969
for random data.
7070
7171
Characteristics:
72-
- *stable* does preserve the ordering of elements which
72+
- *stable*: does preserve the ordering of elements which
7373
compare equal (e.g. "a" and "A" in a sort of letters which
7474
ignores case).
75-
- *O(√n)* auxilary memory usage.
76-
- *`O(n log n)` garuanteed runtime*.
75+
- *`O(√n)`* auxilary memory usage.
76+
- *`O(n log n)`* garuanteed runtime.
7777
7878
## References
79-
- https://link.springer.com/chapter/10.1007/BFb0016253
79+
- Dvořák, S., Ďurian, B. (1986). Towards an efficient merging. In: Gruska, J., Rovan, B., Wiedermann,
80+
J. (eds) Mathematical Foundations of Computer Science 1986. MFCS 1986. Lecture Notes in Computer Science, vol 233.
81+
Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0016253
8082
- https://max-arbuzov.blogspot.com/2021/10/merge-sort-with-osqrtn-auxiliary-memory.html
8183
"""
8284
const PagedMergeSort = maybe_optimize(PagedMergeSortAlg())
@@ -88,14 +90,16 @@ Multithreaded version of PagedMergeSort using Threads.nthreads-times the auxilar
8890
Uses multithreaded recursion (not multithreaded merging), so the maximum speedup is
8991
limited to O(log n)
9092
Characteristics:
91-
- *stable* does preserve the ordering of elements which
93+
- *stable*: does preserve the ordering of elements which
9294
compare equal (e.g. "a" and "A" in a sort of letters which
9395
ignores case).
94-
- *O(√n)* auxilary memory usage.
95-
- *`O(n log n)` garuanteed runtime*.
96+
- *`O(√n)`* auxilary memory usage.
97+
- *`O(n log n)`* garuanteed runtime.
9698
9799
## References
98-
- https://link.springer.com/chapter/10.1007/BFb0016253
100+
- Dvořák, S., Ďurian, B. (1986). Towards an efficient merging. In: Gruska, J., Rovan, B., Wiedermann,
101+
J. (eds) Mathematical Foundations of Computer Science 1986. MFCS 1986. Lecture Notes in Computer Science, vol 233.
102+
Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0016253
99103
- https://max-arbuzov.blogspot.com/2021/10/merge-sort-with-osqrtn-auxiliary-memory.html
100104
- https://en.wikipedia.org/wiki/Merge_sort#Merge_sort_with_parallel_recursion
101105
"""

0 commit comments

Comments
 (0)