comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Convolution of two equally sized arrays
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Convolution of two equally sized arrays [message #41964] Thu, 09 December 2004 15:03
Benjamin Hornberger is currently offline  Benjamin Hornberger
Messages: 258
Registered: March 2004
Senior Member
Hi all,

IDL's convol() function requires the kernel to be smaller than the
array. Any ideas why?

According to Brigham, "The Fast Fourier Transform", the discrete
convolution is defined as

y(k) = Sum(i=0,N-1) x(i) * h(k-i)

where both x(k) and h(k) are periodic functions with period N.

So I would think that if I have two equally gridded functions (two
arrays a and b of equal size), I can convolve them by

result = convol(a, b, /edge_wrap, center=0)

and interchanging a and b should give the same result. I hope I
understood the center keyword right.

But anyway, it doesn't work because IDL wants the kernel to be smaller
than the array. Do I have to write my own convolution function?

Any hints?

Thanks,
Benjamin
[Message index]
 
Read Message
Previous Topic: Re: grid plots
Next Topic: Re: Convolution of two equally sized arrays

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 22:10:09 PDT 2025

Total time taken to generate the page: 0.15973 seconds