# Is the Schroeder Allpass implementation in Freeverb incorrect?

I've been looking into the venerable Freeverb and I see that CCRMA state that it uses 4 Shroeder Allpass filters in series, but when I look at the source code I see:

inline float allpass::process(float input)
{
float output;
float bufout;

bufout = buffer[bufidx];
undenormalise(bufout);

output = -input + bufout;
buffer[bufidx] = input + (bufout*feedback);

if(++bufidx>=bufsize) bufidx = 0;

return output;
}


To me, this doesn't equate to the standard Shroeder Allpass, but instead something like this:

But it should look like this (from CCRMA):

Am I overlooking something here, or is CCRMA incorrect?

You're right that the freeverb "allpass" implementation actually isn't a perfect allpass filter. The implemented filter has a transfer function

$$H(z)=\frac{(1+\alpha)z^{-N}-1}{1-\alpha z^{-N}}\tag{1}$$

The only case for which $$(1)$$ actually is a (scaled) allpass filter occurs if $$\alpha$$ satisfies

$$\alpha(1+\alpha)=1\tag{2}$$

i.e., $$\alpha=(\sqrt{5}-1)/2\approx 0.62$$.

The fact that the freeverb filter only approximates an allpass filter is also mentioned here.

• Thank you! I've looked at that Freeverb page all morning and didn't see the page with that info. Much appreciated. I think I have to assume that the design was intentional. I wonder what the rationale for this unusual choice was? Jun 21 at 12:25
• @kippertoffee: You're welcome! As for your last question, I honestly don't have a clue ... Jun 21 at 12:43
• Manfred Schroeder's original paper on reverb is still a good read: aes.org/e-lib/browse.cfm?elib=343 . His original approach used allpass and comb filters and the freeverb implementation seems to by a hybrid of both. (No idea if that's intentional). Jun 21 at 13:05