Useful Algorithm Implementations

  • Breadth-First-Search
  • Depth-First-Search
  • Fast Dijkstra
  • Prim with O(n^2) find-min
  • Prim (fast with a Priority Queue)
  • Floyd-Warshall
  • Bellman-Ford
  • Max-Flow(Ford-Fulkerson)
  • Infinite Knapsack(coin problem)
  • 0_1 Knapsack(party problem)
  • Knuth Morris Pratt (KMP string searching algorithm)
  • Fast Trie Implementation
  • Knapsack Type MOD problem
  • Fast Convex Hull
  • Computes the maximum order of an element in the Symmetric group Sn
  • Extended Euclidean Algorithm
  • Chinese Remainder Theorem
  • Prime Sieve/ Euler Totient function Sieve
  • Perfect Power Test
  • Miller_Rabin Primality Testing
  • Random Factored Number in { 1, 2, ..... M}
  • Classification of Finite Abelian Groups
  • Expression-parsing-with stacks
  • Expression-parsing-with trees
  • Fast Multiplication of Large Integers using the Fast Fourier Transform(tested to 10^6 digit operands)
  • Complete and efficient Big Integer class(with Fourier Transforms)