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

Home » Public Forums » archive » Re: I need a bit of help....Convol and functions
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: I need a bit of help....Convol and functions [message #50395 is a reply to message #50394] Tue, 03 October 2006 13:42 Go to previous messageGo to previous message
D.Kochman@gmail.com is currently offline  D.Kochman@gmail.com
Messages: 7
Registered: October 2006
Junior Member
Hey you guys, once again thanks for the help. I'm still having fun
learning IDL. ;)

So heres my next problem is finding out how this was implemented so I
can replicate the procedure in order to do my own convolution. Pretty
much what this following function is is a multiple convolution. It
inputs a system response file (confun) which is 1024 data points.


FUNCTION func, P, X=x, Y=y, ERR=err, CONFUN=confun, $
funcvals=f,binsizefactor=bsf

fshift=floor(-P(4)/bsf)
rshift=-P(4)/bsf-fshift
fconfun=shift(confun,-fshift)
sconfun=(1-rshift)*fconfun+rshift*SHIFT(fconfun,-1)
sumex=P(0)*exp( -X / P(1) )+P(2)*exp( -X / P(3) )+P(7)*exp( -X / P(8) )
blank=dblarr(1024)
consum = convol([blank,sumex],sconfun,total(sconfun),CENTER=0)
consumex=consum[1024:*]
scatter= P(6)*sconfun
f=P(5)+consumex+scatter
err=sqrt(f)
return,(y-f)/(err)
end

So my big question is what is going on in convol? If I'm guessing
correctly it seems like this is creating an array [blank,sumex] in
essence to force an array upon sumex - but its a function. Are
specific data points being used in sumex (ie x=0->1024)? I thought
convol only took two parameters, which would mean sconfun would be the
kernel, but I can't see that thats an array either? What is then the
purpose of total(sconfun)?

I've managed to figure out just about everything else in this program
from the creation of the datastructures, and the widgets and so on.
That stuff is easy - and easily changable. I'm kind of lost with this
one.

-Dave
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Low pass filter - Problem with kernel
Next Topic: I need a bit of help....Convol and functions

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

Current Time: Mon Dec 01 14:09:09 PST 2025

Total time taken to generate the page: 0.00232 seconds