[sdiy] Henry, 256 Bw limited!

Antti Huovilainen ajhuovil at cc.hut.fi
Sun Dec 27 18:44:19 CET 2009


On Sun, 27 Dec 2009, karl dalen wrote:

>> Grant Richter <grichter at asapnet.net>
>> It has always puzzled me, but the number of bytes in the
>> waveform is involved in the tone color.
>
> I assume that the more bits you insert the smother/mellow it will sound 
> up to a certain point of bits. And as pointed out a square wave of any 
> bit width sound the same but every other wave does not.

It sort of works like that, but not exactly.
A simplified explanation is that an abrupt transition in level, as happens 
for every sample when the wacetable oscillator has no interpolation, has a 
spectrum that falls off at 6dB/oct asymptotically. This falloff starts at 
the inverse of the transition repetition rate (this would frequency * 
wavetable length / 2 = nyquist frequency).

Below that point, the spectrum is determined by the wavetable contents. 
This way you can have both very sharp sounding waveforms (square, 
sawtooth), and also mellow sounding (sine) when the filter cutoff is below 
the nyquist frequency.

As there is no interpolation, the spectrum detail gets mirrored above 
nyquist (you can work out the maths, but it's generally not worth it). 
Take simple 8 sample waveform as example: The harmonics are a1, a2, a3 and 
a4. The resulting spectrum is then a1, a2, a3, a4, a4, a3, a2, a1, a1, a2, 
a3, a4, a4, a3 ...

Superimposed on that mirrored spectrum is the 6dB/oct falloff rate. There 
is also some additional falloff near multiples of nyquist due to the 
step-like "interpolation" (the official term is zero order hold). The 
effect on sound is minor when the waveform is long as ear is not very good 
at determining exact spectrum shape at high frequencies.


Now for the real reason some wavetable synths sound so gritty:
PPG waveforms were simply miscalculated. If you take normal 128 entry 8 
bit sine, it really sounds quite clean as long as filter removes the 
mirrored harmonics. PPG sine on the other hand evens looks gritty when 
the wavetable contents are viewed. This is either due to a bug in the 
software they used to calculate the wavetable contents or deliberate 
design decision. I'm betting on "happy accident".

Antti

"No boom today. Boom tomorrow. There's always a boom tomorrow"
   -- Lt. Cmdr. Ivanova



More information about the Synth-diy mailing list