Fixed up matrices.  Added Coord and Rect types.  Fixed up other parts of the code.  More to come.