I find the APL/J general use of "arrays" and what they are to be simple, useful, and consistent. I agree with Ralph that calling a 1xN matrix a row vector and an Nx1 matrix a column vector is, at least, sloppy language.
As for zero dimensions, they are completely consistent and unremarkable. If you drop two rows from a 2x2 matrix, what is the resulting shape? If you drop two columns from a 2x2 matrix, what is the resulting shape? I believe Ken used to explain it more finely by asking this question in small steps, e.g. Q: If you start with a 3x3 table, then remove one row, what is the new shape of the table? (A: 2x3) Q: If you remove another row from the result of the preceding step, what is the new shape? (A: 1x3) Q: If you remove another row from the result of the preceding step, what is the new shape? (A: 0x3) On 10/7/07, Raul Miller <[EMAIL PROTECTED]> wrote: > > On 10/7/07, Ralph G Selfridge <[EMAIL PROTECTED]> wrote: > > We should be careful of using 'historic' reasons. Have you ever tried to > > convince a mathematican that matrix multiplication (+/ .*) can be on > other > > than rank 2? And some time ago I had an argument that there are no such > > things as a row vector or a column vector, a vector is a vector is a > > vector. Row and column vectors are just ways of talking about a matrix > with > > a 1 in its shape. > > I agree with your last sentence -- row vectors and column vectors are both > ways of expressing vectors using matrices. But that doesn't mean they > don't exist. > > Given a vector v > ,:v > produces the corresponding row vector and > ,.v > produces the corresponding column vector. > > I think it's often simpler to just work with vectors, but a mathematician > who wants to apply a proof about matrices to a vector might find > row or column vectors more suitable. > > -- > Raul > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > -- Devon McCormick, CFA ^me^ at acm. org is my preferred e-mail ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
