Question: Write a function called mat vec() that takes as input a square matrix and a vector of compatible dimensions, and returns the resulting product vector.

Write a function called mat vec() that takes as input a square matrix and a vector of compatible dimensions, and returns the resulting product vector. That is, if the input are an n n matrix A and an n1 vector x, then mat vec(A,x)= Ax. Test your function on small matrices and vectors that you can check by hand. When you are satisfied, move on to parts (b) and (c). Additionally, print out your code for this function and include it with your assignment.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!