2

I have three set of matrix and I am required to produce the desired output. The problem is I didn't know the operation to solve the matrix. The matrix:

a= [[1]
    [1]
    [0]
    [0]]

b= [[ 1. ]
   [-0.5  ]
   [-0.8660254]
   [ 0. ]]

c= [[ 1]
   [-1]
   [ 0]
   [ 0]]

Using the three matrix, I need to produce the result of

d=[[ 1]
   [0.5]
   [0.86]
   [0]]

So what is a?b?c?=d. I hope anyone may help me. Thank you.

2 Answers 2

2

Use this code to get the desired result. First, convert the lists to arrays and then perform the following operation.

a= np.array([[1],[1],[0],[0]])

b= np.array([[ 1. ],[-0.5  ],[-0.8660254],[ 0. ]])

c= np.array([[ 1],[-1],[ 0],[ 0]])

d=np.array([[ 1],[0.5],[0.86], [0]])

a-b+c

array([[1.       ],
       [0.5      ],
       [0.8660254],
       [0.       ]])
Sign up to request clarification or add additional context in comments.

Comments

1

The answer is simply: a - b + c = d

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.