In music, imitation is the repetition of a melody in a polyphonic texture shortly after its first appearance in a different voice. The melody may vary through transposition, inversion, or otherwise, but retain its original character. The intervals and rhythms of an imitation may be exact or modified; imitation occurs at varying distances relative to the first occurrence, and phrases may begin with voices in imitation before they freely go their own ways.
Imitation helps provide unity to a composition.
When a phrase recurs exactly as before (except perhaps transposed), it is called strict imitation. A round is thus an example of strict imitation. Repetition is defined as the repetition of a phrase or melody often with variations in key, rhythm, and voice.
Different authors define imitation somewhat differently:
Real imitation[:] An imitation with no modifications except for the usual diatonic adjustment of half and whole steps. The exact transposition of a melody at different pitch levels.
Imitation[:] The repetition of a melody or melodic group in close succession, but in a different voice; the repetition of a melody at a different pitch level in a polyphonic texture.
Imitation[:] The restatement in close succession of melodic figures in different voices in polyphonic textures.
In counterpoint, imitation occurs in a second voice, usually at a different pitch. A short phrase treated imitatively is called an attacco.