Hi, I have a simple patch with a [click~] object connected to a [reson~] filter. I'd like to know how it is possible to convert the bandwith parameter of the filter to decay lenght (in milliseconds). In SuperCollider there is a particular version of the "resonz" filter called "ringz", here is the description: Ringz.ar(in, freq, decaytime, mul, add)
This is the same as Resonz, except that instead of a resonance parameter, the bandwidth is specified in a 60dB ring decay time.
My knowledge of filters is too little to be able to convert the between the two parameters by myself, any help appreciated!
thanks,
libero
Is what you are looking for a resonant comb filter? I.e. a delay line with a resonant frequency which "rings"? Check the archives for the "resonant comb filter series" thread. Me, Davide Morelli and Ian Smith-Heisters worked out a bunch of stuff there. I wouldn't know off-hand how to convert a band pass filter to a comb filter, though. I only how to do it with delay lines right now. Some Googling on filter theory could fix that pretty fast, though...
best, d.
Libero Mureddu wrote:
Hi, I have a simple patch with a [click~] object connected to a [reson~] filter. I'd like to know how it is possible to convert the bandwith parameter of the filter to decay lenght (in milliseconds). In SuperCollider there is a particular version of the "resonz" filter called "ringz", here is the description: Ringz.ar(in, freq, decaytime, mul, add)
Hi Derek, thanks for your help, but my problem is related with the answer given by Charles Henry. Thanks anyway! Libero
On Jan 22, 2008 7:43 PM, Derek Holzer derek@umatic.nl wrote:
Is what you are looking for a resonant comb filter? I.e. a delay line with a resonant frequency which "rings"? Check the archives for the "resonant comb filter series" thread. Me, Davide Morelli and Ian Smith-Heisters worked out a bunch of stuff there. I wouldn't know off-hand how to convert a band pass filter to a comb filter, though. I only how to do it with delay lines right now. Some Googling on filter theory could fix that pretty fast, though...
best, d.
Libero Mureddu wrote:
Hi, I have a simple patch with a [click~] object connected to a [reson~] filter. I'd like to know how it is possible to convert the bandwith parameter of the filter to decay lenght (in milliseconds). In SuperCollider there is a particular version of the "resonz" filter called "ringz", here is the description: Ringz.ar(in, freq, decaytime, mul, add)
-- derek holzer ::: http://www.umatic.nl ::: http://blog.myspace.com/macumbista ---Oblique Strategy # 117: "Make it more sensual"
It depends upon the order of the filter... by resonant filter, I assume you mean a two-pole bandpass filter. Here's the math for converting between bandwidth and exponential decay
Take a function, g(t)=1000^-(t/r) where r is the -60 dB ring time. I used a base of 1000, because a factor of 1000 = 60 dB
g(t)=e^-(t*ln(1000)/r)
Now we take a one-sided fourier transform of this function:
G(f)=integral(0, inf; e^(-2*pi*i*f*t)*e^-|t*ln(1000)/r|) G(f)=integral(0, inf; e^((-2*pi*i*f-ln(1000)/r)*t) G(f)=1/(-2*pi*i*f-ln(1000)/r) * e^((-2*pi*i*f-ln(1000)/r)*t), eval at t=0, t=inf
G(f)= - 1/(-2*pi*i*f-ln(1000)/r) G(f)=1/(2*pi*i*f+ln(1000)/r)
G(f)=r/ln(1000) / [2*pi*i*f*r/ln(1000) + 1]
now, it's just a simple matter of finding the -3 dB points to find bandwidth of this function and interpreting the result of this function...
|G(f)|^2=(r/ln(1000))^2 / [1 + (2*pi*f*r/ln(1000))^2]
0.5 = 1 / [1 + (2*pi*f*r/ln(1000))^2] (2*pi*f*r/ln(1000))^2 = 1
f = +/- ln(1000)/(2*pi*r) bandwidth bw= 2 * ln(1000)/(2*pi*r)
conversions: bw = ln(1000) / (pi*r) r = ln(1000) / (pi*bw) r is in seconds and bw is in Hz
Try out these relations and see if they work.
Chuck
On Jan 22, 2008 12:11 PM, Libero Mureddu libero.mureddu@gmail.com wrote:
Hi, I have a simple patch with a [click~] object connected to a [reson~] filter. I'd like to know how it is possible to convert the bandwith parameter of the filter to decay lenght (in milliseconds). In SuperCollider there is a particular version of the "resonz" filter called "ringz", here is the description: Ringz.ar(in, freq, decaytime, mul, add)
This is the same as Resonz, except that instead of a resonance parameter, the bandwidth is specified in a 60dB ring decay time.
My knowledge of filters is too little to be able to convert the between the two parameters by myself, any help appreciated!
thanks,
libero
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Hi Charles, thanks, this is exactly the solution I was looking for. Thanks a lot for the detailed math explanation too. ciao
Libero
On Jan 22, 2008 9:12 PM, Charles Henry czhenry@gmail.com wrote:
It depends upon the order of the filter... by resonant filter, I assume you mean a two-pole bandpass filter. Here's the math for converting between bandwidth and exponential decay
Take a function, g(t)=1000^-(t/r) where r is the -60 dB ring time. I used a base of 1000, because a factor of 1000 = 60 dB
g(t)=e^-(t*ln(1000)/r)
Now we take a one-sided fourier transform of this function:
G(f)=integral(0, inf; e^(-2*pi*i*f*t)*e^-|t*ln(1000)/r|) G(f)=integral(0, inf; e^((-2*pi*i*f-ln(1000)/r)*t) G(f)=1/(-2*pi*i*f-ln(1000)/r) * e^((-2*pi*i*f-ln(1000)/r)*t), eval at t=0, t=inf
G(f)= - 1/(-2*pi*i*f-ln(1000)/r) G(f)=1/(2*pi*i*f+ln(1000)/r)
G(f)=r/ln(1000) / [2*pi*i*f*r/ln(1000) + 1]
now, it's just a simple matter of finding the -3 dB points to find bandwidth of this function and interpreting the result of this function...
|G(f)|^2=(r/ln(1000))^2 / [1 + (2*pi*f*r/ln(1000))^2]
0.5 = 1 / [1 + (2*pi*f*r/ln(1000))^2] (2*pi*f*r/ln(1000))^2 = 1
f = +/- ln(1000)/(2*pi*r) bandwidth bw= 2 * ln(1000)/(2*pi*r)
conversions: bw = ln(1000) / (pi*r) r = ln(1000) / (pi*bw) r is in seconds and bw is in Hz
Try out these relations and see if they work.
Chuck
On Jan 22, 2008 12:11 PM, Libero Mureddu libero.mureddu@gmail.com wrote:
Hi, I have a simple patch with a [click~] object connected to a [reson~] filter. I'd like to know how it is possible to convert the bandwith parameter of the filter to decay lenght (in milliseconds). In SuperCollider there is a particular version of the "resonz" filter called "ringz", here is the description: Ringz.ar(in, freq, decaytime, mul, add)
This is the same as Resonz, except that instead of a resonance parameter, the bandwidth is specified in a 60dB ring decay time.
My knowledge of filters is too little to be able to convert the between the two parameters by myself, any help appreciated!
thanks,
libero
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list