Adding Matrix class