Re: Secret Rabbit Code : New release imminent




Sorry for the delay in responding. Busy, busy, busy.

robert bristow-johnson wrote:

On Mar 12, 6:11 am, Erik de Castro Lopo <er...@xxxxxxxxxxxxx> wrote:
I found experimentally that for the code I already had, I got
better results for non-power-of-two values. Multiples of three
were not much better so I went for prime numbers.

hmmmm, i'm trying to get my head around this. you're saying that if
you increase the number of phases from 491 to 512 (MORE phases, not
less), that for an arbitrary sample rate ratio, it sounds *better*
using the slightly fewer phases.

To my tin ear they sound pretty much identical, but the 491 phase
converter has a measurably lower noise floor than the 512 phase
converter.

and it sounds better because the
number of phases is a prime number? somebody's gonna need to explain
to me how that works. i don't know why the primeness or compositeness
of the number of fractional delays per input sampling period, why it's
better for that number to be prime or bad for it to be highly
composite (like a power of 2).

In my implementation I use a double precision float to calculate the
next sample position and a fixed point number (12 fractional bit and
the rest integer) for indexing into the FIR coefficient table.

The indexing is done with an offset and increment (both fixed point
numbers) so that the Nth index is calculated using:

index = offset + N * increment

well, multiplication is cheap nowadays. it's mutliplying by 491 vs.
shifting left 9 bits (for 512) which is nowadays about the same amount
of trouble.

Exactly.

can you give me a hint, either regarding the spectrum or some hand-
waving psycho-acoustic argument for why upsampling by a factor that is
a prime number is better than some other integer of about the same
size?

I didn't pursue it, but I suspect that errors caused by the inaccuracy
of the fixed point arithmetic is more correlated when there are 2^N
phases as opposed to a prime number.

Erik
--
-----------------------------------------------------------------
Erik de Castro Lopo
-----------------------------------------------------------------
"Within C++, there is a much smaller and cleaner language struggling
to get out." -- Bjarne Stroustrup
.



Relevant Pages


Loading