Comparison sorts

Introsort

Introsort or introspective sort is a hybrid sorting algorithm that provides both fast average performance and (asymptotically) optimal worst-case performance. It begins with quicksort, it switches to heapsort when the recursion depth exceeds a level based on (the logarithm of) the number of elements being sorted and it switches to insertion sort when the number of elements is below some threshold. This combines the good parts of the three algorithms, with practical performance comparable to quicksort on typical data sets and worst-case O(n log n) runtime due to the heap sort. Since the three algorithms it uses are comparison sorts, it is also a comparison sort. Introsort was invented by David Musser in , in which he also introduced introselect, a hybrid selection algorithm based on quickselect (a variant of quicksort), which falls back to median of medians and thus provides worst-case linear complexity, which is optimal. Both algorithms were introduced with the purpose of providing generic algorithms for the C++ Standard Library which had both fast average performance and optimal worst-case performance, thus allowing the performance requirements to be tightened. Introsort is in place and not stable. (Wikipedia).

Video thumbnail

Outtakes

Yes. I make mistakes ... rarely. http://www.flippingphysics.com

From playlist Miscellaneous

Video thumbnail

Learning to use the one to one property to solve an exponential equation

👉 Learn how to solve exponential equations. An exponential equation is an equation in which a variable occurs as an exponent. To solve an exponential equation, we isolate the exponential part of the equation. Then we take the log of both sides. Note that the base of the log should correspo

From playlist Solve Exponential Equations without a Calculator

Video thumbnail

Using the inverse of an exponential equation to find the logarithm

👉 Learn how to convert an exponential equation to a logarithmic equation. This is very important to learn because it not only helps us explain the definition of a logarithm but how it is related to the exponential function. Knowing how to convert between the different forms will help us i

From playlist Logarithmic and Exponential Form | Learn About

Video thumbnail

Using one to one property with different bases to solve an exponential equation

👉 Learn how to solve exponential equations. An exponential equation is an equation in which a variable occurs as an exponent. To solve an exponential equation, we isolate the exponential part of the equation. Then we take the log of both sides. Note that the base of the log should correspo

From playlist Solve Exponential Equations without a Calculator

Video thumbnail

Learn how to get the same bases to solve an exponential equation

👉 Learn how to solve exponential equations. An exponential equation is an equation in which a variable occurs as an exponent. To solve an exponential equation, we isolate the exponential part of the equation. Then we take the log of both sides. Note that the base of the log should correspo

From playlist Solve Exponential Equations without a Calculator

Video thumbnail

Linear Transformations: Onto

Linear Algebra: Continuing with function properties of linear transformations, we recall the definition of an onto function and give a rule for onto linear transformations.

From playlist MathDoctorBob: Linear Algebra I: From Linear Equations to Eigenspaces | CosmoLearning.org Mathematics

Video thumbnail

Adding Vectors Geometrically: Dynamic Illustration

Link: https://www.geogebra.org/m/tsBer5An

From playlist Trigonometry: Dynamic Interactives!

Related pages

Adaptive sort | Sorting algorithm | Insertion sort | Logarithm | Median of medians | Heapsort | LLVM | Quickselect | Quicksort | Sort (C++) | GAP (computer algebra system) | Double-ended queue | Shellsort | Comparison sort | Selection algorithm | In-place algorithm | Standard Template Library | Hybrid algorithm | Introselect | Boost (C++ libraries)