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

Home » Public Forums » archive » 1D array problem for butterworth.pro
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
1D array problem for butterworth.pro [message #92534] Tue, 05 January 2016 23:18 Go to next message
kagoldberg is currently offline  kagoldberg
Messages: 26
Registered: November 2012
Junior Member
I stumbled across a major problem with calculating 1D butter worth filters in IDL 8.5. (This bug was not in IDL 8.3. I don't know about 8.4.)

When you ask for 1D output, butterworth.pro extracts a 1D vector from the dist(x) function, which is a 2 dimensional, square array. As you might guess, as the array size gets large, IDL has to calculate a 2D dist() result with N^2 points! IDL 8.3 did not do this.

It brought my computer to its knees a few times before I was able to isolate it, and replace the built-in butterworth.pro with my own kludge.

Instead of (dist(x))[*,0], they should have used dist(x,1) and... problem solved.
Re: 1D array problem for butterworth.pro [message #92536 is a reply to message #92534] Wed, 06 January 2016 09:42 Go to previous messageGo to next message
chris_torrence@NOSPAM is currently offline  chris_torrence@NOSPAM
Messages: 528
Registered: March 2007
Senior Member
On Wednesday, January 6, 2016 at 12:18:17 AM UTC-7, kagol...@lbl.gov wrote:
> I stumbled across a major problem with calculating 1D butter worth filters in IDL 8.5. (This bug was not in IDL 8.3. I don't know about 8.4.)
>
> When you ask for 1D output, butterworth.pro extracts a 1D vector from the dist(x) function, which is a 2 dimensional, square array. As you might guess, as the array size gets large, IDL has to calculate a 2D dist() result with N^2 points! IDL 8.3 did not do this.
>
> It brought my computer to its knees a few times before I was able to isolate it, and replace the built-in butterworth.pro with my own kludge.
>
> Instead of (dist(x))[*,0], they should have used dist(x,1) and... problem solved.

Thanks for reporting this! I've gone ahead and fixed the code and it should be in the next release.
Cheers,
Chris
Re: 1D array problem for butterworth.pro [message #92550 is a reply to message #92536] Mon, 11 January 2016 09:10 Go to previous message
Ken G is currently offline  Ken G
Messages: 14
Registered: September 2006
Junior Member
Thanks!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: scientific image
Next Topic: help using IMAGE.pro and COLORBAR in IDL

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

Current Time: Wed Oct 08 15:47:12 PDT 2025

Total time taken to generate the page: 0.00507 seconds