[Pd] Complex audio signals

Piotr Majdak piotr at majdak.com
Tue Jun 20 15:10:40 CEST 2006


Chuckk Hubbard wrote:
> On 6/20/06, Chuckk Hubbard <badmuthahubbard at gmail.com> wrote:
> 
>> On 6/20/06, Piotr Majdak <piotr at majdak.com> wrote:
>> > > Another question: if I just ran rfft~ on a signal, and then ran ifft~
>> > > on the transform, would that create the same signal as a complex
>> > > signal?
>> >
>> > Using [rfft~] you can process real signals only...
>>
>> I meant like:
>> [readsf~] (for instance)
>> |
>> [rfft~]
>> |      |
>> [ifft~]  [num\ [num\
>> |   |     |         |
>> [czero~]
>> |
>> [dac~]
>>
>> I suppose I could just try it and see if it works...

You transform the signal from [readsf~] to the frequency domain (it's complex 
now), then transform it back to the time domain (now it's real again and 
identical to the signal from [readsf~]). Why do you do that?

According to the help patch, [czero~] does: y[n] = x[n] - a[n] * x[n-1].
To get a consistent filtering with [czero~] the imaginary part of the result 
should be zero (the real part can be the input for [dac~], as you did it), which 
means, that a[n] must be conj(x[n]), or in this case the imag(a)=0. Of course, 
you can use a chain of [czero~]s, where the intermediate results are complex. 
However, after the last [czero~], the result should be real.

To play with [czero~], try the [pd test] subpatch in the help file of [czero~].

> It doesn't.  Nor does:
> [osc~]
> |
> [rfft~] [sig~ 0]
> |        |
> [ifft~]
> 

Can you tell me, what are you trying to do? You know, this patch works (no 
errors), but I don't know how to interpret the resulting signals...

br, Piotr



-- 
Piotr Majdak
Institut für Schallforschung
Österreichische Akademie der Wissenschaften
Reichsratsstr. 17
A-1010 Wien
Tel.: +43-1-4277-29511
Fax: +43-1-4277-9296
E-Mail: piotr at majdak.com
WWW: http://www.kfs.oeaw.ac.at






More information about the Pd-list mailing list