Comparison based sorting complexities
Hey everyone, was just re-reading the decision tree proof for the Omega(n log n) lower bound for comparison sorting and had a random thought.
The standard proof assumes all distinct elements, so you get n! leaves, which gives you the log2(n!) >= n log2(n) - n log2(e) bound.
But what happens if we drop the distinctness constraint and assume a multiset with a known multiplicity vector <k_1, k_2, ... k_m> where the sum of k_i = n? The number of distinct permutations drops to the multinomial coefficient: n! / (k_1! * k_2! * …* k_m!).
Has anyone seen a tight lower bound for online algorithms that adapt to this dynamically *without* knowing the multiplicities ahead of time? Entropy-coded heaps kinda do this, but I'm looking for a pure information-theoretic proof for the competitive ratio. Standard textbooks always seem to skip the multiset edge case and it's bugging me lol.