working SVM Matrix