While considering O(log(N)) for time complexity, what is the base of log?
The joint best basis algorithm computes the jointly best bases given: the set of signals, an information cost function and a wavelet basis, see (Wickerhauser 1994) and (Coifman and Wickerhauser 1992).
The word algorithm is derived from the Old French word algorisme, which was the term for the Arabic numeral system. A logarithm is a quantity that represents the power to which the base or fixed number must be raised in order to produce a specific number.
– In complexity theory, they are used to measure input sizes, especially when the input is numeric and we want to count the number of digits. – In complexity theory, the complexity functions for algorithms that repeatedly split their input into two halves involve logs to the base 2.
In Computer Science, it's often base 2. This is because many divide and conquer algorithms that exhibit this kind of complexity are dividing the problem in two at each step. Binary search is a classic example.
All logarithms are related by some constant. (Hence the change-of-base formula). Because we generally disregard constants in complexity analysis, the base doesn't matter.
Usually, the base is considered to be 2, when deriving the algorithm. Consider a sort like merge sort. You can construct a tree out of it, and the tree has a height of log₂ n
, because each node has two branches.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With