Counting sort initialization of the output array, each take time. Therefore, the time for the whole algorithm is the sum of the times for these steps, . Because it uses arrays of length and , the total space usage of the algorithm is also . For problem instances in which the maximum key value is significantly smaller than the number of items, counting sort can be highly space-efficient, as the only storage it uses other than its input and output arrays is the Count array which uses space . If each item to be sorted is itself an integer, and used as
Integer relation algorithm is an integer relation between any two real numbers "x" and "x". The algorithm generates successive terms of the continued fraction expansion of "x"/"x"; if there is an integer relation between the numbers then their ratio is rational and the algorithm eventually terminates. Integer relation algorithms have numerous applications. The first application is to determine whether a given real number "x" is likely to be algebraic, by searching for an integer relation between a set of powers of "x" {1, "x", "x", ..., "x"}. The second application is to search for an integer relation between a real number "x" and