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

Home » Public Forums » archive » Re: very simple Index question~~~help~~~
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: very simple Index question~~~help~~~ [message #62544 is a reply to message #62543] Mon, 15 September 2008 20:56 Go to previous messageGo to previous message
xiao zhang is currently offline  xiao zhang
Messages: 81
Registered: June 2008
Member
On Sep 15, 10:49 pm, David Fanning <n...@dfanning.com> wrote:
> xiao writes:
>> I have a very simple question , I have an 178*300 array, I want to
>> read it line by line like this :
>
>> print,diff(53399)
>> print,diff(178*299+177) ;178*299+177=53399
>
>> for i=0,177 do begin
>> diff2(i)= diff(178*299+i)
>> endfor
>
>> Why it always remind me that it out of range in the second print
>> statement. I mean 178*299+177 s exactly equal to 53399.
>
> IDL arrays are indexed starting from 0 and not 1. If you
> get to 53399, you have exceeded the bounds of the array,
> which go from index 0 to 53398.
>
> 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 think it is over floating.......How can I solve this?
TNX
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: IDL is giving me a syntax error out of nowhere
Next Topic: Exporting iPlot graphics to EPS files in vector format?

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

Current Time: Fri Oct 10 11:39:12 PDT 2025

Total time taken to generate the page: 0.72011 seconds