Path: utzoo!utgpu!watmath!clyde!att!rutgers!deimos!uxc!uxc.cso.uiuc.edu!uxg.cso.uiuc.edu!uicsrd.csrd.uiuc.edu!jaxon From: jaxon@uicsrd.csrd.uiuc.edu Newsgroups: comp.lang.apl Subject: Re: Visualization of arrays Message-ID: <49700008@uicsrd.csrd.uiuc.edu> Date: 8 Feb 89 20:28:00 GMT References: <121@infbsgr.infbs> Lines: 23 Nf-ID: #R:infbsgr.infbs:121:uicsrd.csrd.uiuc.edu:49700008:000:1188 Nf-From: uicsrd.csrd.uiuc.edu!jaxon Feb 8 14:28:00 1989 The default display of rank 4 arrays isn't particularly good. I prefer enclosing them along the last two dimensions before they are displayed. I find the resulting display (a 2D array of 2D arrays) lets me compute the index of an element visually, and lets me notice adjacency along the leading axes more easily. In expressions I seldom 'use' more than 3 axes, the rest are just carried along through the pervasive functions or others derived from the Each operator. To visualize those expressions, I generally enclose either the axes I'm working on, or the complementary set. In every APL I've known, arrays are stored in row-major order. On most high performance equipment, the innermost loops should access items along the trailing dimensions, so I also try to keep data that are used together adjacent along some trailing axis. If you are doing Reductions or Scans, however, you might want to test the relative performance of different reduction axes. This storage order is the "opposite" of Fortran, so where you might prefer pre-multiplication inner products in F77, you will want to convert to post-multiplication for APL. regards Greg Jaxon (jaxon@uicsrd.uiuc.edu)