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

Home » Public Forums » archive » Re: endless loop problem
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: endless loop problem [message #68959 is a reply to message #68953] Sun, 06 December 2009 17:20 Go to previous messageGo to previous message
Wasit.Weather is currently offline  Wasit.Weather
Messages: 62
Registered: February 2008
Member
On Dec 6, 5:52 pm, David Fanning <n...@dfanning.com> wrote:
> pp writes:
>
> .
>
>> L does not change because you are calculating the same thing over and
>> over again. L only depends on EC[0] and EC[1], and neither changes
>> when you go through the loop. So if L does not happen to be
>> <1.2840277, the loop will never end.
>
> And it is not likely that it will *ever* be 1.2840277!
>
>   http://www.dfanning.com//math_tips/sky_is_falling.html
>
> Cheers,
>
> David
>
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming:http://www.dfanning.com/
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

I should have given more explanations on this. L changes over each
iteration. There is no problem. I missed one letter, here is the
corrected one.
;E1 = Unit vector, known
; Z is known matrix
REPEAT BEGIN
EC = Z##E1
L = sqrt(EC[0]+EC[1])
E1 = EC/L
print,L
;Keep going until nothing is moved.
ENDREP UNTIL L LT 1.2840277

I am struggling to find eigenvalues and eigenvectors manually, instead
of IDL routines.

I think it might be a problem as David pointed out. But there should
be a value less than or greater than that value, right?
Thanks
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Why doesn't IDL know the borders of Kazakhstan?
Next Topic: ASSOC vs SHMMAP vs POINT_LUNs vs READ_BINARY?

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

Current Time: Sat Oct 11 08:31:46 PDT 2025

Total time taken to generate the page: 0.16457 seconds