Dumb
Make matrix values static members, move functions to *d versions of files