| Josep M Comajuncosas wrote:
> Well I think the problem comes when one implements slightly unstable
> recursive filters. Believe it or not they´re necessary in the
> modelling of waveguide bores.
What filter types? reson, 1st order, 2nd order? What sorts of coefficients are needed - calculated
at i-time, k-time, or a-rate?
I wonder if higher numerical precision is absolutely essential for physical modelling. After all,
most of the CCRMA waveguide stuff was designed in NeXTSTEP to run on a Motorola 56XXX DSP, which has
24-bit integer precision only (although I think it uses 56-bit accumulation).
It is possible that some of this stuff that was designed for integer DSPs will work differently, or
not at all, in floating point. I recently implemented a Hal Chamberlin quadrature oscillator design
in C for Csound, based on a state-variable filter with infinite Q. Chamberlin described it as always
staying at the same amplitude, but when I ran it, there was a noticable drop in amplitude after 10
minutes. I think that this happened because the original design took advantage of the rounding off
of integer representation of the signal to achieve stability - the rounding off helped the unstable
filter design to achieve a steady state.
I have a suspicion that the answer to your problem is not simply changing floats to doubles in
various opcodes, but designing new opcodes from scratch that implement the behavior you are seeking.
Perhaps new filter types need to be created, that have built-in limiting to enable instability
without blowing up (this is the next step for the quadrature oscillator).
Sean Costello
P.S. You had mentioned buzz in your email; it is worth noting that the quadrature oscillator I
describe could be used to implement buzz without using table lookup. I will actually try converting
the relevant floats to double, just to see what happens. |