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.

#2
2003-11-03, 16:32
 blank Join Date: Jan 2000 Posts: 620
Yup... and

It should perhaps be added that this is what happens at *16/44*. If I understood the issue correctly, it has to do with "rounding" and at this particular bit- and samplerate a number that should be a perfect zero comes out as zero plus 1/65536.

I would conclude that at 24 bits, the (however miniscule at 16 bits) effect is virtually immeasurable, or even non-existent if the rounding calculation results in the last bit being a zero rather than a one. Right?

/Fred
#3
2003-11-03, 16:46
Not really...

it doesn't have to do with sample resolution, but with pitch resolution, and that's always 16-bit.

/tage

:It should perhaps be added that this is what happens at *16/44*. If I understood the issue correctly, it has to do with "rounding" and at this particular bit- and samplerate a number that should be a perfect zero comes out as zero plus 1/65536.
:
:I would conclude that at 24 bits, the (however miniscule at 16 bits) effect is virtually immeasurable, or even non-existent if the rounding calculation results in the last bit being a zero rather than a one. Right?
:
:/Fred
#4
2003-11-03, 16:52
 blank Join Date: Jan 2000 Posts: 620
Re: Not really...

: it doesn't have to do with sample resolution, but with pitch resolution, and that's always 16-bit.

Ah, OK, my bad. I assumed internal pitch was 32-bit (like all stuff in that domain) and that the pitch thingy observed in the test happened later, somewhere closer to the "exit".

/Fred
#5
2003-11-03, 16:45
 jbratteson Join Date: Nov 2002 Posts: 0
How am I going to write my new song, "15 Killa Hurtz"? : )

: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.
:
:
#6
2003-11-03, 16:47
Re: How am I going to write my new song, "15 Killa Hurtz"? : )

Just listening to the damn tone hurts my ears :-)

/tage
#7
2003-11-03, 17:05
 arothman Join Date: Nov 2001 Posts: 41
The real question is, of course...

:How come you get to post images at the bottom of your message and we only get to post them at the top?!?! I demand an explanation!

Thanks for getting to the bottom of this Tage... we appreciate it!

Drew
#1 @ ElectronicScene.com
#8
2003-11-03, 17:12
I knew someone would notice that...

...and It's just because I created this board and I know it's inner workings.

<span style="font-size: 48px; font-weight: bolder"> I Can Control It! Muaahhahahaha!</span>

/Tage

::How come you get to post images at the bottom of your message and we only get to post them at the top?!?! I demand an explanation!
:
:Thanks for getting to the bottom of this Tage... we appreciate it!
:
rew
#9
2003-11-03, 17:17
 arothman Join Date: Nov 2001 Posts: 41
GASP!!!

And you get to use span tags too?! HE'S GONE MAD WITH POWER!!! Someone must stop him!!!

Drew
#10
2003-11-03, 20:31
 Meffy Join Date: Nov 2002 Posts: 571
Re: GASP!!!

:And you get to use span tags too?! HE'S GONE MAD WITH POWER!!! Someone must stop him!!!

Golly. I thought all the Props were Swedish, not span-ish.

Mef

 Thread Tools Display Modes Hybrid Mode

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is Off Forum Rules

All times are GMT +2. The time now is 12:30.