Counting Inversions Adaptively
arXiv:1503.01192
Abstract
We give a simple and efficient algorithm for adaptively counting inversions in a sequence of integers. Our algorithm runs in time in the word-RAM model of computation, where is the number of inversions.
5 pages