[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: origin of the index syntax
From: |
Francesco Potorti` |
Subject: |
Re: origin of the index syntax |
Date: |
Tue, 28 Jun 2005 17:48:56 +0200 |
>>>> does anyone know where the index expression syntax used
>>>> in Octave comes from? Is the Matlab people who invented it?
>>>> Or else it is older?
>>>> Was it just the evolution of something in common usage?
David Bateman:
>>> I believe the syntax was developed at the time when octave-forge
>>> was being setup, and its category index was also being setup.
Bill Denney:
>> I'm not sure, but I think that Francesco is referring to the
>> index like a(5). I don't have an answer, but I think that's
>> the quesiton.
Yes. I mean the syntax for matrix indices, the one that defines what is
a number, in ainterval, an array. I would like to use it in a program of
mine and would like to know what is its proper name.
Ted Harding:
>Some languages distinguish between a function call like fname(...)
>and reference to an indexed variable like vname[...] by different
>syntax. C is such a language, and originated in 1972 (though it
>evolved from languages going back to the early 60s).
Thank you for the interesting excursus on the history of the (..) and
[..] syntaxes, but that's not what I meant :-)
I meant to ask this: If I want to take a slice of a multidimensional
array, I can express it as [1:10, 3, 0.1, [3 6], :]. Is there a common
name for this kind of syntax?
--
Francesco Potortì (ricercatore) Voice: +39 050 315 3058 (op.2111)
ISTI - Area della ricerca CNR Fax: +39 050 313 8091
via G. Moruzzi 1, I-56124 Pisa Email: address@hidden
Web: http://fly.isti.cnr.it/ Key: fly.isti.cnr.it/public.key
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------