Algorithmic Efficiency - Speed

Speed

The absolute speed of an algorithm for a given input can simply be measured as the duration of execution (or clock time) and the results can be averaged over several executions to eliminate possible random effects. Most modern processors operate in a multi-processing and multi-programming environment so consideration must be made for parallel processes occurring on the same physical machine, eliminating these as far as possible. For superscalar processors, the speed of a given algorithm can sometimes be improved through instruction-level parallelism within a single processor (but, for optimal results, the algorithm may require some adaptation to this environment to gain significant advantage ('speedup'), becoming, in effect, an entirely different algorithm). A relative measure of an algorithm's performance can sometimes be gained from the total instruction path length, which can be determined by a run time Instruction Set Simulator (where available).

An estimate of the speed of an algorithm can be determined in various ways. The most common method uses time complexity to determine the Big-O of an algorithm. See Run-time analysis for estimating how fast a particular algorithm may be according to its type (example: lookup unsorted list, lookup sorted list etc.) and in terms of scalability—its dependence on 'size of input', processor power and other factors.

Read more about this topic:  Algorithmic Efficiency

Famous quotes containing the word speed:

    Spig Wead: I’ve been thinking what a heel I’ve been about you and about my own kids. I don’t know, when I do something, I go all the way. Living. Gambling. Flying. I tap myself out. I guess that’s the way I want it to be. Maybe even the way I am.
    Minne Wead: Star-spangled Spig. Damn the martinis, full speed ahead and don’t give up the ship.
    Frank Fenton, William Wister Haines, co-scenarist, and John Ford. Spig Wead (John Wayne)

    The terror of the atom age is not the violence of the new power but the speed of man’s adjustment to it—the speed of his acceptance.
    —E.B. (Elwyn Brooks)

    No speed of wind or water rushing by
    But you have speed far greater.
    Robert Frost (1874–1963)