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

Home » Public Forums » archive » Loop through arrays with different names
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Loop through arrays with different names [message #55088] Wed, 01 August 2007 17:04 Go to previous message
hazel is currently offline  hazel
Messages: 5
Registered: July 2007
Junior Member
Hello,

I have a really simple problem that always happens when I starting
trying to use strings..

I want to loop through a series of arrays, each with a slightly
different name (det1arr(n,3), det2arr(n,3), det3arr(n,3)..etc..) and
subject each to the same function:

a quick outline is:

for j=1,8 do begin

for i=0, n-1 do begin

vx=det1arr(i, 0) ; where the 1 is effectively the value of 'j'
vy=det1arr(i, 1)
vz=det1arr(i, 2)

result(i,j)=some_function(vx, vy, vz)

endfor

So can I do something like: vx=det+j+arr(i,0)? (Only that clearly
won't work)? There must be a way? Otherwise I can reload all my
different arrays into one array I realise and just loop through that.

I'm sure it's something painfully simple and for that I apologise, but
it is the end of the day (for me anyway),

Thanks,

Hazel
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Routine for Converting DN to Radiance to Temperature
Next Topic: Another HDF File Question

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

Current Time: Wed Oct 08 17:23:51 PDT 2025

Total time taken to generate the page: 0.00362 seconds