Added some linear algebra functions, not sure if we'll need them.