The Bubble Sort Curve

Lines That Connect
Apr 21, 2024
3 notes
3 Notes in this Video

Bubble Sort: Iterative Adjacent Comparison

BubbleSort SortingAlgorithms AlgorithmVisualization ComputerScience

Bubble sort, a simple sorting algorithm visualized through vertical bars, creates distinctive curved shapes during execution despite being inefficient compared to quicksort or mergesort.

Bubble Sort's Parabolic Curve

GeometricCurves AlgorithmVisualization ParabolicFunctions BubbleSort

The mysterious curve formed by bubble sort’s unsorted region resolves to a parabola, specifically the function h(x,t) describing bar height at position x and time t.

Iteration Boundaries in Bubble Sort Progress

AlgorithmAnalysis ProgressMetrics TimeNormalization BubbleSort

Analyzing bubble sort requires establishing conventions for aspect ratio (1×1 unit square) and time normalization (t ∈ [0,1] where t=0 is unsorted, t=1 is sorted).