Hi. How can someone create list of indexes of 3d table (N x M x K)?
I have written this simple code: ind3d =: 3 : 0 'n m k' =. y p0 =. k&| p1 =. (m&|)@:<.@:(%&k) p2 =. <.@:(%&(m*k)) (p2 , p1 , p0)"0 (i. (n*m*k)) ) but it's very very slow. Does any tacit solution for this problem exist? Another question is how to fill the table with values depending on indexes of cell? For example, F[i,j,k] = (i * j) - (i * k) + (j * k). ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm