# Latest content was relocated to https://bintanvictor.wordpress.com. This old blog will be shutdown soon.

## Tuesday, October 14, 2014

### physical, intuitive feel for matrix shape - fingers on keyboards

Most matrices I have seen so far in real world (not that many actually) are either
- square matrices or
- column/row vectors

However it is good to develop a really quick and intuitive feel for matrix shape. When you are told there's some mystical 3x2 matrix,

- imagine a rectangle box
- on its left imagine a vertical keyboard
- on it put Left fingers, curling. 3 fingers only.
- Next, imagine a horizontal keyboard below (or above, if comfortable) the rectangle.
- put Right fingers there. 2 fingers only

For me, this gives a physical feel for the matrix size. Now let's try it on a column matrix of 11. The LHS vertical keyboard is long - 11 fingers. Bottom keyboard is very short -- 1 finger only. So it's 11x1

The goal is to connect the 3x2 (abstract) notation to the visual layout. To achieve that,
- I connect the notation to -- the hand gesture, then to -- the visual. Conversely,
- I connect the visual to -- the hand gesture, then to -- the notation
------------------------
Now consider matrix multiplication. Consider a 11x2. Note a 11x1 columnar matrix is more common, but it's harmless to get a more general feel.

An 11x2 * 2x9 gives a 11x9.

Finger-wise, the left 11 fingers on the LHS matrix stay glued; and the right 9 fingers on the RHS matrix stay glued. In other words,

The left hand fingers on the LHS matrix remain.
The right hand fingers on the RHS matrix remain.

Consider a 11x1 columnar matrix X, which is more common.

X * X' is like what we just showed -- 11x11 matrix matrix
X' * X is 1x11 multiplying 11x1 -- 1x1 tiny matrix