#Complexity Analysis
[TOC]
##Big-O Notation
This operation means "order of" and is used to describe the general behaviour of an algorithm.
We can calculate the complexity of an algorithm by many delimeters. One common way is to count the number of in terms your input, and the complexity will be the greatest power of 'n' in that equasion.
##Synbols of Complexity
Ο - The "order of" operator, defines worst case complexity. Θ - Defines the general average complexity. Ω - Defines best-case complexity.
##Properties of Big-O
- If f(n) = O(g(n)) and g(n) is O(h(n)) then f(n) = O(h(n)).
- If f(n) = O(h(n))) and g(n) = O(h(n)) then f(n) + g(n) is O(h(n)).
- ank = O(nk).
- nk = O(nk+j) for any j > 0.
- If f(n) = c.g(n) then f(n) = O(g(n)).
- logan = O(logbn) for any a,b >1
- logan is O(log2n) for any positive a ≠1.
Regan Koopmans, 2016