Emmanuel Amiot, Discrete Fourier Transform and Bach’s Good Temperament
Example 4. A program for computing MSS