17.01.2013 Views

musicdsp.org source code archive - WSInf

musicdsp.org source code archive - WSInf

musicdsp.org source code archive - WSInf

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

egin<br />

skn:=0;<br />

skn1:=0;<br />

skn2:=0;<br />

temp1:=2*PI*frequency/samplerate;<br />

temp2:=Cos(temp1);<br />

for i:=0 to Length(Buffer) do<br />

begin<br />

Skn2 = Skn1;<br />

Skn1 = Skn;<br />

Skn = 2*temp2*Skn1 - Skn2 + Buffer[i];<br />

end;<br />

Result:=(Skn - exp(-temp1)*Skn1);<br />

end;<br />

Maybe someone can use it...<br />

Christian<br />

from : GPOLAT51@YAHOO.COM<br />

comment : HI . I NEED DSP C62X CODE FOR DTMF DETECTÝON WÝTH GOERTZEL. ÝF YOU HAVE SEND ÝT GPOLAT51@YAHOO.COM<br />

TAHANKSSS..<br />

from : kevin@subatomicglue.com<br />

comment : why's the 2*cos(2*PI*frequency/samplerate) in that inner loop? It's all constants... I'd precompute this outside the for loop.<br />

also. use the float version of cos and exp... cosf expf... that way you're not wasting time converting and using the more expensive functions.<br />

from : net_day2004@hotmail.com<br />

comment : if anyone please can help me, i need a c++ <strong>code</strong> about the fft.the <strong>code</strong> should input and array of N rows and 1 column, all set to 1, and<br />

also it should input the length of fft(interval from f1 to f2) and output the results.<br />

thank you,<br />

i would appreciate your help,<br />

bassem

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!