Since this is a logarithmic scale, the 12th roots of 2 are uniformly spaced on the interval. This strictly geometric scale was advocated by Bach and others in the 18th century to enable smooth modulation from one key to the next in the course of a single composition. It might have been more descriptively named the logarithmic scale. They were originally defined by the Roman Catholic Church as part of the singing of the psalms. Of all these seven modes, only two survive today, the Ionian and Aeolian, which we call the major and minor scales.
More sophisticated melodies make use of all seven of the major tones in the chosen key.
Furthermore, a composer sometimes calls for a note that is not even in the chosen key. This song won the Academy Award for Best Original Song, presumably because the Academy members were appreciative of the fact that the melody invokes eleven of the twelve tones in the full well-tempered scale.