Question: how to multiply M[1] which is [0,1,1,1,1] with Matrix([[x0], [x1], [x2], [x3], [x4]])

M := Matrix([[0,1,1,1,1],[1,0,1,1,1],[1,1,0,1,1],[1,1,1,0,1],[1,1,1,1,0]]);

how to multiply M[1] which is [0,1,1,1,1] with Matrix([[x0], [x1], [x2], [x3], [x4]])
to become [0,x1,x2,x3,x4]

may not use Matrix([[x0], [x1], [x2], [x3], [x4]])

just want to use first element as x0 when it is not 0

second element as x1, etc

Please Wait...