Oleg Kobchenko <[EMAIL PROTECTED]> writes:
> 
> --- Terrence Brannon <[EMAIL PROTECTED]> wrote:
> 

> > 
> > But 3 $ 1 2 3 
> > has zero magnitude in the 2nd dimension, no? So it would seem to be 
> > equivalent 0 3 $ 1 2 3 but per the interpreter it is not.
> 
> It's not zero magnitude in higher dimension, it's _empty_ magnitude.
> Same as scalar has empty dimention, but itself represents one 

I like scalar myself but "atom" is the proper J terminology. I also like matrix 
much more than array. But why sweat the small stuff? :) And list? well that 
totally aggravates me. Vector is great. List is stepping on the toes of cons 
cells that that particular data structure.

> data location. Shape 3 is not (0,3) it's ('',3).

I see. Now, in terms of data storage:

an array of shape 1,3 can store 1 vector of magnitude 3 which can store 3 
"somethings". 

an array of shape '', 3 can store 3 somethings (it is a vector of magnitude 3).

but what about an array of shape 0,3? How can you index into that vector of 
magnitude 3 and get or store data? 



----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to