Turn more readable and fix transposed matrix