Comments
Loading Dream Comments...
You must be logged in to write a comment - Log In
With matrix multiplication, we take two identically-shaped matrices (tables of numbers), and select each row in turn from the left-hand one, multiplying it by each column in turn from the right-hand one. Then we sum those values, giving a cell in the output. (This is called a "dot product"). We repeat this for each row in the LHS and each column in the RHS. This gives a whole matrix of result values. Basically, what your GPU on your graphics card does, to get all the perspective and texture/lighting rendering :) ::SHE+ILA:: denotes this operation by "+.*" (from APL), and if you use 4x4 "homogeneous" matrices with X,Y,Z coordinates in the first three positions and 1's the fourth position you can do both rotations and translations (moves) in the same step. Multiply your "object view", and your "world view" and your "projection" matrices, and hey you have a cheap-and-cheerful CAD package (like KDS5000, one I did in 1981). You can also do logical operations, such as /\.\/ where you form the logical AND of a set of logical ORs, or \/./\ where you form the logical OR of a set of logical ANDs (I remember doing this at college, but I currently forget the details, lol). Or you can correlate tables of strings with /\.$= which char-wise compares two text tables and then requires the AND of the matches (i.e. all entries must match). Oh, it only really works with ALUOPs, not FBIops (which see), so you can't say something like "insert dot extract", lol. But you can go beyond rank two matrices, and you can consider A+.*B as equivalent to +/A*B for rank two matrices (and similarly for other ALUOPs such as $= or \/). And so on :)