Collection of various algorithms in mathematics, machine learning, computer science and physics implemented in Python for educational purposes.
The repository is a collection of open-source implementation of a variety of algorithms implemented in Python and licensed under Apache-2.0 License. The algorithms span a variety of topics from computer science, mathematics and statistics, data science, machine learning, engineering, etc. The implementations and the associated documentation are meant to provide a learning resource for educators and students. Hence, one may find more than one implementation for the same objective but using a different algorithm strategies and optimizations.
- Bubble Sort
- Recursive Bubble Sort
- Insertion Sort
- Recursive Insertion Sort
- Binary Insertion Sort
- Selection Sort
- Shell Sort
- Heap Sort
- Merge Sort
- Iterative Merge Sort
- Merge Sort for Linked Lists
- Merge Sort for Doubly Linked List
- 3-way Merge Sort
- Quick Sort
- Iterative Quick Sort
- QuickSort on Singly Linked List
- QuickSort on Doubly Linked List
- 3-Way QuickSort
- Counting Sort
- Radix Sort
- Bucket Sort
- Brick Sort
- Gnome Sort
- Stooge Sort
- Tag Sort
- Tree Sort
- Cartesian Tree Sort
- Pancake Sort
- Bitonic Sort
- Strand Sort
- Cocktail Sort
- Cycle Sort
- Pigeonhole Sort
- Comb Sort
- TimSort
- Bogo Sort
- Sleep Sort
- Linear Search
- Linear Search with Sentinel
- Binary Search
- Ubiquitous Binary Search
- Interpolation Search
- Exponential Search
- Sublist Search
- Jump Search
- Fibonacci Search
- Dijkstra’s Algorithm
- Bellman–Ford Algorithm
- Floyd Warshall Algorithm
- Klee’s Algorithm
- Minimum lines to cover all points
- Triangular Matchstick Number
- Find if two rectangles overlap
- Number of rectangles in N*M grid
- Area of a Circular Sector
- Arc length from given Angle
- Circumference of a circle
- Fibonacci Numbers
- Fibonacci Numbers (DP)
- Fibonacci Numbers (Optimized)
- Fibonacci Numbers (Space Optimized)
- Fibonacci Numbers with Matrix
- Fibonacci Numbers (Analytical)
- Prime Factores
- Sieve of Eratosthenes
- Sieve of Eratosthenes (Optimized)
- Sieve of Sundaram
- Sieve of Atkin
- Greatest Common Divisor
- Least Common Multiple
- Factorial
- Trinomial Triangle
- Leibniz Harmonic Triangle
- Hosoya’s Triangle
- Find Perimeter of a triangle
- Triangular Numbers
- Pascal’s Triangle
- Find x and y satisfying ax + by = n
- Number of non-negative integral solutions of a + b + c = n
- Find smallest values of x and y such that ax – by = 0
- Discriminant Value
- Dot Product of two vectors
- Cross Product of two vectors
- Iterated Logarithm
- Correlation Coefficient
- Muller Method
- Roots of Unity
- Roots of quadratic equation
- Square root of an integer
- Pythagorean Triplets
- Taylor Approximation of Exponential
- Euclidean Distance
- Standardized Euclidean Distance
- Squared Euclidean Distance
- Cosine Distance
- Canberra Distance
- Braycurtis Distance
- Chebyshev Distance
- Cityblock Distance
- Correlation Distance
- Mahalanobis Distance
- Minkowski Distance
- Weighted Minkowski Distance
- Kulsinski Distance
- Jaccard Distance
- Hamming Distance
- Dice Distance