first class shell
commiting cause I have to leave soon.
added unit testing and one test. changed matrix reprsentation to 1D array.