Adding More Array Operations
Two-dimensional matrices are special in science and technology. Unlike vectors alone, two-dimensional matrix equations are powerful to describe most processes that surround us (including infection diffusion in social networks). Unlike three- and higher-dimensional arrays, they’re still easy to visualize and comprehend. Not surprisingly, APL provides special support for two-dimensional arrays.
Let’s revisit the reduction explained. In the case of a vector, the reduction function op/A applies the function op to all elements. In the case of a matrix, there are two ways to reduce: row-wise and column-wise. Unless the matrix is symmetric, the outcomes will differ, and they will differ even more in a three-or-more-dimensional ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access