[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Slow Time Test in IDL 5.4
David Fanning (firstname.lastname@example.org) writes:
> Before JD goes crazy trying to analyze slow Time_Test2
> values for IDL 5.4, let me alert you that a change to
> the IDL library routine FACTORIAL has made that routine
> *significantly* slower. So much so, that Time_Test2 runs
> about 10 times slower on PCs running IDL 5.4 than it does
> running earlier versions. :-(
> RSI is working on the problem, but for the time being
> you may want to copy the IDL 5.3.1 factorial.pro over
> into your IDL 5.4 lib subdirectory. Having done this,
> we find the Time_Test2 to be noticeably faster in IDL 5.4
> than in IDL 5.3.1.
I got myself all muddled up last week trying to
get about 10 things done at the same time. Then, I
went to Europe before I could straighten the whole
thing out. Let me see if I can put this right.
The problem was not with Time_Test2 as it happened.
The problem was with the IDL 5.4 FACTORIAL routine.
I made the inexcusable mistake of only personally
checking half my facts instead of all of them before
I posted. Sorry for any problems this caused.
Anyway, here is what I think I know about FACTORIAL
routine. The routine was first optimized for vector
input. So the original 5.3 routine was faster for scalar
values, but the IDL 5.4 routine was faster for
vector values. The IDL 5.4 routine has now been
fixed and made faster for BOTH scalar and vector
input. You can get the new routine from RSI, or
you can get it from my web page as soon as I get
an article written about it. (Soon, I hope.)
And, as I understand it, the IDL 5.3 FACTORIAL
routine had some problems with non-integer input (e.g.
print, factorial(5.1)). This has also been fixed
in the IDL 5.4 routine.
Unfortunately, the IDL 5.4 routine takes advantage of
the new WHERE keywords, so can't be run in anything
but IDL 5.4, so a direct comparison of the routines
is not possible.
Again, sorry for the confusion. :-(
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: email@example.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155