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

Home » Public Forums » archive » Re: limits of 'invert'
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
Re: limits of 'invert' [message #46329] Thu, 17 November 2005 00:38
Paolo Grigis is currently offline  Paolo Grigis
Messages: 171
Registered: December 2003
Senior Member
queiny wrote:
> Thank Lajos and Ken! I do need to review the basic concepts.
You don't even need to buy expensive books, check out:

http://www.library.cornell.edu/nr/bookcpdf.html

it's all there in pdf format!

Ciao,
Paolo

>
> This group provide much more help than just IDL..
>
Re: limits of 'invert' [message #46338 is a reply to message #46329] Wed, 16 November 2005 12:16 Go to previous message
queiny is currently offline  queiny
Messages: 15
Registered: November 2005
Junior Member
Thank Lajos and Ken! I do need to review the basic concepts.

This group provide much more help than just IDL..
Re: limits of 'invert' [message #46340 is a reply to message #46338] Wed, 16 November 2005 11:07 Go to previous message
K. Bowman is currently offline  K. Bowman
Messages: 330
Registered: May 2000
Senior Member
In article <1132162119.050786.109730@g47g2000cwa.googlegroups.com>,
"queiny" <queiny98@yahoo.com> wrote:

> Dear IDL & Maths experts:
>
> Is there a limit for the 'invert' or 'la_invert', program to calculate
> the inversion of a square matrix, provided by IDL?
>
> When my matrix is 150x150, 'invert' return immediatelly, but when it is
> '15000x15000', 'invert' runs for more than a day. I am wondering
> whether it is in some infinite loop, or it simply needs that long.
>
> What is the reasonable upper limit that 'invert' or 'la_inver' can
> operate?
>
> Thanks,
>
> Q

Matrix inversion is an O(n^3) operation, so the second case should require
~100^3 times as long as the first, that is, ~10^6 times as long. (There are
~10^5 seconds/day.)

Also, storing a 15000 x 15000 array requires ~900 MB, so you may very well be
swapping to disk, which will slow things down by another couple of orders of
magnitude.

I suggest that you consult a good introductory numerical analysis book.

Cheers, Ken Bowman
Re: limits of 'invert' [message #46345 is a reply to message #46340] Wed, 16 November 2005 10:01 Go to previous message
Foldy Lajos is currently offline  Foldy Lajos
Messages: 268
Registered: October 2001
Senior Member
Hi,

as an example, run time for simple matrix multiplication is proportional
to n^3. For your sizes, this would give a factor of 10^6. A 150x150 array
can reside in the CPU cache, so add another 10 for the big array => 10^7.
If "immediate" = 0.1 s, then 10^7 * 0.1 s is about two weeks.

And if you run out of physical memory, swapping to disk can add another
factor of 100 :-(

regards,
lajos


On Wed, 16 Nov 2005, queiny wrote:

> Dear IDL & Maths experts:
>
> Is there a limit for the 'invert' or 'la_invert', program to calculate
> the inversion of a square matrix, provided by IDL?
>
> When my matrix is 150x150, 'invert' return immediatelly, but when it is
> '15000x15000', 'invert' runs for more than a day. I am wondering
> whether it is in some infinite loop, or it simply needs that long.
>
> What is the reasonable upper limit that 'invert' or 'la_inver' can
> operate?
>
> Thanks,
>
> Q
>
>
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IDLgrPolygon -TEXTURE_MAP question
Next Topic: lunch envi function in 'batch mode'

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

Current Time: Wed Oct 08 19:24:36 PDT 2025

Total time taken to generate the page: 0.00637 seconds