A quick introduction to FM Synthesis
Frequency Modulation (FM) synthesis is a process for creating a wide range of sounds by modulating (changing over time) the frequency of an oscillator using another oscillator.
A "carrier" oscillator is wired so it can be heard, and then a second "modulator" oscillator is wired to the frequency control of the carrier. When the modulator oscillator is at a slow speed and intensity, this creates an effect usually called "vibrato" - but when the modulator is oscillating fast, in the audible range (20hz to 20,000hz), it's called FM synthesis.
As the image above suggests, the resulting frequency modulated wave is much more complex than either the carrier oscillator, the modulator oscillator, or the two simply mixed together and heard.
If your browser supports WebAudio, you can use the tool below to explore a simple FM setup - one carrier and one modulator. If you're not hearing sound, check that your phone isn't on silent.
Modulator Oscillator Frequency:
Modulation Amount:
Using this basic idea we can create extremely complex FM synthesis setups, that generate an almost infinite range of sounds. But if we want the sounds to evolve over time, we need to add envelopes, to change the oscillators level or amount of modulation.
Below is another web audio example of a simple two oscillator FM system, just like the last example - but this time with a triggerable attack-release envelope controlling the level of the modulator oscillator:
Modulator Oscillator Frequency:
Modulator Envelope:
Modulator Level Envelope Attack:
Modulator Level Envelope Release:
With carriers, modulators, and envelopes, accounted for all that's left is to scale up. That means using more oscillators, wired together in complex networks of modulators and carriers - usually called "algorithms". The Yamaha DX7, the instrument that popularized FM synthesis, had six oscillators that could all be used as modulators OR carriers, and they could be arranaged into 32 different algorithm.
I don't have the space here to build out a full six-operator FM synth - but if you want to dive into the deep end of FM synthesis, Matt Montag has build an amazing in-browser DX7 emulation: http://mmontag.github.io/dx7-synth-js/.
Thanks for exploring! This tool has been built by Crows Electromusic. We hand-make electronic musical instruments in Vancouver, Canada. We will be releasing an instrument that uses FM soon - subscribe to our email list below if you'd like to be notified when it's available!