This post is not intended as a full explanation of ring modulation, amplitude modulation, or frequency modulation synthesis. The intent is to discuss how to implement various forms of modulation synthesis in Max/MSP.
Ring modulation is the easiest form of modulation synthesis to implement in Max/MSP. You simply multiply the outputs of two oscillators together. The problem is that ring modulation offers no control of spectrum (timbre) over time. Reducing the amplitude of one oscillator simply reduces the overall amplitude output, not the amplitude of the modulator alone.
AM synthesis is similar to ring modulation, but the modulating oscillator is offset to have an amplitude between 0. and 1. This offset allows for dynamic control of the spectrum over time by controlling the amplitude of the modulating oscillator. In Max, you can subtract the modulator amplitude from 1. and add the result to the output of the modulator. An example of this process is demonstrated in MSP Tutorial 9: Amplitude Modulation. The tutorial patcher uses an expr object, but you can also use <!- 1.> for the same effect. The latter way can also be applied to an audio-rate amplitude <!-~ 1.>.
Again, to achieve the offset:
- Modulator oscillator output is multiplied by modulator amplitude (in decimal format).
- Modulator amplitude in subtracted from 1. and added to result of modulator oscillator x modulator amplitude. (offset)
- Output of modulator plus offset is multiplied by output of carrier oscillator.
MSP Tutorial 11: Frequency Modulation provides the basis for our discussion of frequency modulation. The basics of FM synthesis are the M:C frequency ratio (modulator-to-carrier), or harmonicity ratio; and the modulation index. Remember that integer harmonicity relationships give harmonic sounding tones; non-integer relationships give inharmonic tones. The modulation index relates to the number of pairs of frequency sidebands produced by the modulation.
In the tutorial, the math is happening in the simpleFM~ subpatcher (details later). The carrier frequency is multiplied by the harmonicity ratio to obtain the modulator frequency. The modulator frequency multiplied by the modulation index value provides the actual modulation index (actually produces a matching number of sidebands as the function calls for). The output of the mod index times mod frequency is multiplied (amplitude scaling) by the output of the mod oscillator, and then that output is added to the carrier frequency to obtain the frequency modulation.
Summary of FM:
- Modulator frequency is obtained by multiplying the carrier frequency by the harmonicity ratio.
- Index is obtained by multiplying the index number (or function) by the modulating frequency.
- The output of the mod index operation amplitude scales the output of the mod oscillator (multiply).
- The output of the scaled modulator oscillator is added to the carrier frequency input.