Harmonic Content and Distortion Character

Adam Greer

The design of Hysteris came from experiments with unconventional distortion mechanisms, specifically hysteretic switching and op-amp saturation.  My goal when designing this pedal was to have a harmonically rich sound that could vary from a more conventional overdriven sound to gated, harsh tones that sound like dying electronics.  To achieve this I settled on the aforementioned clipping mechanisms to provide rich harmonic character that can be shifted by blending and filtering each mechanism in parallel.  This leads to a semi-controllable harmonic balance that shifts with playing dynamics.  The switching mode tends to introduce stronger even-order content, whereas the op-amp saturation branch has a more classic third-harmonic-dominant sound.

To provide some background, it helps to briefly look at conventional distortion mechanisms in guitar pedals, the mechanisms used in Hysteris, and how their harmonic content differs.  The first clipping mechanism is commonly known as soft diode clipping, where a pair of antiparallel diodes is placed in the feedback path of an amplifier circuit.  This causes the effective gain of the stage to decrease as the signal increases, gradually flattening the waveform.  The other conventional, diode-based distortion mechanism is hard diode clipping.  In this topology, the diode pair is placed after the amplification stage, where it limits the waveform more abruptly once the signal approaches the diode’s forward voltage.  This produces a sharper transition.  In my pedal, I used op-amp saturation and hysteretic switching.  Op-amp saturation has similar dynamics to soft clipping, but its exact behavior also depends on characteristics such as slew rate, frequency response, output swing, and recovery from saturation.  Hysteretic switching is closer to hard clipping but has a different character.  Hysteretic switching is a state-dependent mechanism that changes the gain of the amplifier based on the signal level and the switching thresholds of the circuit.  It is essentially an amplifier with memory of the signal that switches the gain higher or lower depending on the signal level and relevant switching thresholds.  The abrupt transitions that occur when the circuit changes state contribute strongly to the harmonic content.

Harmonic content is a major contributor to the tone of a pedal.  The following table shows the harmonic relationships between the fundamental and various harmonics:

Harmonic Ratio Approx. musical interval
H1 1:1 Fundamental
H2 2:1 Octave
H3 3:1 Octave + perfect fifth
H4 4:1 Two octaves
H5 5:1 Two octaves + major third
H6 6:1 Two octaves + perfect fifth
H7 7:1 Two octaves + flat minor seventh
H8 8:1 Three octaves
H9 9:1 Three octaves + major second
H10 10:1 Three octaves + major third

The harmonic content of a pedal changes the character of the distortion.  A pedal dominated by H2 will sound noticeably different from a pedal dominated by H3 even if they have the same measured total harmonic distortion.  In general, low-order even harmonics tend to be perceived as warmer because their musical relationships emphasize octave relationships and more consonant intervals, whereas odd harmonics can sound more aggressive, especially as higher-order harmonics like H7 and H9 become more prominent.  

For this writeup, I created some example audio and graphs using Python to demonstrate the effects of the various harmonics on the perceived character of the pedal.  I also used some idealized models of the various clipping mechanisms to demonstrate their character.  All audio examples have been peak-normalized and were generated at the same fundamental for consistency.

For the first set of examples, I generated a sine wave at 220 Hz and then mixed in various harmonics to adjust the character of the signal.  This first example is a pure sine tone for reference.

Figure 1: Pure Sine 220 Hz

Pure Sine 220 Hz

The next examples are an even-heavy signal and an odd-heavy signal.  

Figure 2: Even-heavy 220 Hz

Figure 3: Odd-heavy 220 Hz

Even Heavy 220 Hz
Odd Heavy 220 Hz

Listening to the examples, the even-heavy signal sounds more consonant.  This is similar to the sound of an overdriven amplifier where the distortion stays warmer and less aggressive.  The odd-heavy signal has more dissonant relationships in the harmonics and sounds somewhat harsher.  This is more like a distortion pedal where an aggressive tone is the goal.  The next examples specifically introduce only the second and third harmonics to isolate their effect on the tone.

Figure 4: H2 Dominant 220 Hz

H2 Dominant 220 Hz

Figure 5: H3 Dominant 220 Hz

H3 Dominant 220 Hz

The difference in character is still there but isn't as pronounced as the full even-heavy and odd-heavy signals.  In this case, the H2 signal still feels rounder and more mellow than the H3 signal, but the H3 signal isn’t as dissonant as the odd-heavy signal with even more high-order content.  This is useful because if we can control the higher-order content, we can control the perceived aggressiveness of the sound, which becomes even more useful when that shift can be controlled by playing dynamics rather than knob position alone.

Let’s examine the various clipping models and how their harmonic content varies.  For this comparison, I represented the op-amp saturation and soft diode clipping using the same smooth model in order to keep the discussion simple.  These examples were generated with the fundamental frequency at 110 Hz.  I may explore their differences further in a future writeup.

In this graph we can see that the harmonic content of the three clipping models varies significantly.  For more detail, let’s look at the resulting waveforms from each model.

Figure 6: Waveform Comparison of 3 Clipping Models + Unprocessed Sine

The differences in waveform shape make the source of those spectral differences easier to see. 

First, we will talk about the least aggressive mechanism on the list, soft clipping.

Soft Clipping

This clipping sounds fairly warm and round due to its reduced higher-order harmonic content.  The symmetric soft-clipping model is predominantly odd-order but tends to contain less energy above the fifth harmonic than the other models.

Hard Clipping

Next is hard clipping.  This clipping has a richer character and sounds slightly harsher than the soft-clipped signal.  The symmetric hard-clipping model is also predominantly odd-order, but contains higher-order content that introduces dissonant intervals not present in the soft-clipping model.

Hysteretic Switching

Finally, we have the hysteretic switching model.  This distortion has a much more buzzy, almost synth-like quality to it.  This is due to the presence of both even and odd harmonics at fairly high levels through H20.  This introduces several intervals that were not present in the odd-dominant signals and helps reinforce the octave relationships in the overtones.

These examples leave out asymmetric clipping for simplicity's sake. In general, asymmetric clipping tends to create more even-order harmonic content than symmetric clipping.

Figure 7: THD vs Input Level for 3 Clipping Models

The above graph compares the total harmonic distortion with the input level.  Hard and soft clipping have relatively simple relationships, where more input causes more distortion in a fairly predictable manner.  The hysteretic switch is more complicated.  As the signal approaches the switching thresholds, THD rises sharply.  However, as the input rises further beyond the thresholds, THD begins to decrease.  Referencing the previous harmonic-content plot, we can see that the soft- and hard-clipping models are predominantly odd-order, while the hysteretic switching mechanism contains much stronger even-order content.  Combining these behaviors allows the harmonic balance to shift with playing dynamics when the smooth op-amp saturation branch is mixed with the hysteretic switching branch.  The resulting system can move from low distortion at softer playing levels, to a rich mixture of even- and odd-order harmonics at moderate levels, and finally toward a more odd-dominant character as the input signal rises further.

Distortion is more than a measure of how much the resulting waveform differs from the input; the mechanism generating that distortion has a major effect on its harmonic content and perceived character.  Soft clipping, hard clipping, and hysteretic switching each shape the waveform differently and therefore produce a unique harmonic balance.  In Hysteris, combining smooth op-amp saturation with state-dependent hysteretic switching allows that balance to shift with playing dynamics instead of remaining fixed to control settings.  The dynamic change in harmonic character is one of the main ideas behind the design of the pedal.  A future writeup will look more closely at measured behavior from the actual circuit.

Previous
Previous

Characterizing Hysteris - Gain, Harmonics, and non-linear control.