I wonder whether with relatively simple music, ie few instruments the predominantly second harmonic distortion isn't too bad and perhaps in the case of brass instruments with their odd harmonics can actually mellow their sound a bit
That's exactly what PMA said.
Play a big orchestra with a big choir and it will not be nice anymore.
Only on a full-scale signal. As others have said, you cannot create a given level of 2nd on its own from an arbitrary signal. You basically have two choices:udok said:Use Octave or Matlab:
This adds -46 dB 2nd order distortion:
x = wavread('input.wav');
y = x + 0.01*x.*x;
wavwrite(y, 48e3, 16, 'output.wav');
1. use a quadratic term (as above) which gives you level-dependent 2nd and nothing else
2. use some version of half-wave rectification to generate a fixed proportion of 2nd together with fixed proportions of higher orders too.
A simple circuit like what I use for a headphone amp makes nice circa 0.06% H2. It works with any SS low THD amp to give music some euphonic H2.
xrk971 Pocket Class A Headamp GB
There is also a variant where you can adjust relative H2 and H3. In above circuit varying R4 changes relative H2 to certain extent by changing bias current.
xrk971 Pocket Class A Headamp GB

There is also a variant where you can adjust relative H2 and H3. In above circuit varying R4 changes relative H2 to certain extent by changing bias current.
Last edited:
Only on a full-scale signal. As others have said, you cannot create a given level of 2nd on its own from an arbitrary signal. You basically have two choices:
1. use a quadratic term (as above) which gives you level-dependent 2nd and nothing else
2. use some version of half-wave rectification to generate a fixed proportion of 2nd together with fixed proportions of higher orders too.
It's not perfect and it rather complicates things, but you could make a compressor with (near-)infinite compression ratio and multiply the original signal with the sum of a constant and the compressed signal.
Yes, that would work for a constant signal. As soon as it varies (music varies!) you need to think about compression time constants.
People often talk about distortion as though it is just something added to the signal, like noise. It is not; it is something generated from the signal so it varies as the signal varies. How it varies depends on the type of distortion and how it is generated. Adding 0.5% 2nd to a music signal is not easy, yet people often ask for something like this.
People often talk about distortion as though it is just something added to the signal, like noise. It is not; it is something generated from the signal so it varies as the signal varies. How it varies depends on the type of distortion and how it is generated. Adding 0.5% 2nd to a music signal is not easy, yet people often ask for something like this.
Since the 2nd H is double the frequency ie one octave up couldn't you just run the signal through a side chain pitch shifter set to +1oct and then mix it back in with the original at any level you want?
Yes, that would work for a constant signal. As soon as it varies (music varies!) you need to think about compression time constants.
Indeed, that's why it is not perfect. The shorter the time constants, the better it follows the envelope of the signal, but the more higher-order distortion you get because the compressor itself will distort. You can use higher-order compressor loop filtering and/or dead zones to reduce that. But that's all pretty standard in compressor design.
Since the 2nd H is double the frequency ie one octave up couldn't you just run the signal through a side chain pitch shifter set to +1oct and then mix it back in with the original at any level you want?
Yes, that should work as well. How do these pitch shifters work? Are there any non-idealities?
The H2 generator PCBoards given out at Burning Amp 2018, and discussed in Nelson Pass's article on firstwatt.com, have about 1% H2 (-40 dB). The circuit simulation in #43 has about 0.01% H2 (-80 dB), which is not nearly enough to achieve Pass's objectives.
_
In practice, with some tweaks to setpoints or because two 9v Li-ion batteries run closer to 15.5v, the H2 is closer to -60dB, which IMO, is the ideal value as -40dB is a bit too much for my taste. The -60dB is not something that gets in the way of the music, but simply makes it sound better, more “musical” and exciting.

The -60dB is not something that gets in the way of the music, but simply makes it sound better, more “musical” and exciting.
In Pavel's thread Can you tell original file from tube amp record? - test I queried whether H2 was musical due to the music we listen to largely not being harmonic, have you any comments?
Yes, that should work as well. How do these pitch shifters work? Are there any non-idealities?
I was thinking digitally there wouldn't/shouldn't be too many irregularities.
Might even be possible in audacity which I think was mentioned earlier.
Octave guitar pedals do it as well and are analogue but I have no real idea of how they work beyond the wiki page where it says they use a full wave rectifier and diodes.
The idea was that this way you get nothing but 2nd harmonic and you can dial in how much.
With a full-wave rectifier you get all even harmonics, not just the second.
A digital version probably does a running DFT, doubles all frequencies and transforms it back. The trick is to get the results of the inverse DFTs to combine into one smooth waveform without weird echoes.
At least GoldWave has a pitch shifter that works like that. I haven't used it for a couple of years, but if I remember well, you always have to experiment with the DFT size and overlap until you get the best sound.
A digital version probably does a running DFT, doubles all frequencies and transforms it back. The trick is to get the results of the inverse DFTs to combine into one smooth waveform without weird echoes.
At least GoldWave has a pitch shifter that works like that. I haven't used it for a couple of years, but if I remember well, you always have to experiment with the DFT size and overlap until you get the best sound.
Last edited:
I have harmonizer with adjustable harmonics. Works great.
While adjusting bias, harmonics spectrum change. I have a hifi version( rca) and a pro version(XLR).
While adjusting bias, harmonics spectrum change. I have a hifi version( rca) and a pro version(XLR).
Attachments
Last edited:
- Status
- Not open for further replies.
- Home
- Source & Line
- Analog Line Level
- How do i create second harmonic distortion?