Minor fixes
Beginning of linear matrix representation - needs more development