Propellerhead Forum The 15 kHz test

#1
2003-11-03, 16:16
The 15 kHz test

The 15 kHz test revisited.
==========================

Peter is back so we have now had the brainpower in place to dig into the 15 kHz test discussed last week on this message board.

For those who missed the action and don't care to browse away a few pages in the thread list, here's a recoup: It was discovered that a 15 kHz since sine wave sample rendered to disk by Reason would result in not a perfect copy of the original sample, but a sample with a 1.5 second interval of alternating amplitude. Since our DSP guru was away, no one here at PropellerheadQ could explain why this happened. Now we know.

Here's what happens:
When a sampler plays a sample back at nominal pitch it should produce a perfect copy of the original sample. Nominal pitch means that the sample is being played back at root key and the same playback frequency as is was sampled with, with no pitch alterations in the sampler and no master tune change in the playback application.

Whenever you play a sample back at a different pitch than nominal pitch, all samplers use pitch algorithm to change the playback speed and hence the pitch of the sample. The quality of the sound depends on what kind of pitch algorithm the sampler uses.

Now, what we have discovered is that the way Reason plays it's samples means that even at nominal pitch, Reason will still use it's pitch algorithm to play the sample. The effect can be seen in the 15 kHz test. The measured periodicity cycle is 65536 samples, which means that the offset is one bit, or 1/65536 of the pitch range. The result is a pitch offset of 0.7 hz at nominal pitch (all over the frequency spectrum). This may sound alarming, but to put it in perspective, a trained ear have problems detecting a frequency shift of less than 10hz around 900 hz, the human ear's most responsive frequency.

As shown in the 15kHz test, the wave exported from Reason isn't a perfect copy of the source material. There's no alternating amplitude, it only looks that way in the waveform display. What it is is a slightly pitched sample. At 15 kHz it's pitched about 0.0046666%.

Even at 70 hz, the offset is only one cent.

Remember that this only happens when playing a sample at nominal pitch. For this to happen, the following conditions must apply:
* The sample must not have a tune setting other than 0
* The sample must be played at root key only
* The sample must not be played with any pitch bend or pitch envelope.
* The master tune setting must be 0.

If any of the above conditions isn't met, the pitch algorithm is used to pitch the sample and that means it isn't played at nominal pitch.

An idea that has figured in the discussions about the 15 kHz test is that Reason would have some kind of cpu-saving trick for playing back samples. That's not true. In fact, Reason uses a pitch algorithm very similar to that found in Emu samplers (known for their great sound).

We are not sure if the pitch offset at nominal pitch is a real world problem or not. Changing it in future releases would be easy if required. This has not been discussed yet.

Below you will find examples of how the pitch algorithms work in a few popular software samplers. First, we see the original 15 khz wave. Next up is Reason's wave pitched down 1 cent. Next the same sampled pitched up one cent by Halion and last, the same sample pitched down one cent by EXS24mkII.

As shown in the examples all samplers do things to samples when they are played at different pitches. The one cent pitch change that we did here is about 100 times the pitch offset at nominal pitch in Reason. The measurements below doesn't tell the whole truth about pitch algorithm accuracy, but it does show that Reason's interpolation filter has a very good frequency response.

Summary: Reason uses it's pitch algorithm even when playing samples at nominal pitch. The result is a 0.7 hz pitch offset (only when at nominal pitch). Contrary to last week's discussion, there is no compression or anything happening that causes an alternating amplitude. It's just a pitch offset. We haven't decided if we think this is a problem in the real world or not. It's easy to get alarmed by things like this, simply because they are measurable, but if you check your musical instruments you will most likely find that most of them has far greater pitch offsets than Reason 0.7 hz at nominal pitch. In conclusion, we don't think this is a big problem, if it's a problem at all.