Question: 1.4 [2 pt] Impliment the function ThreeVec that takes in three 3 dimentional vectors each represented as an array, creates a matrix from stacking the

1.4 [2 pt] Impliment the function ThreeVec that
1.4 [2 pt] Impliment the function ThreeVec that takes in three 3 dimentional vectors each represented as an array, creates a matrix from stacking the arrays vertically (each array is a row in a matrix), and returns a list in which: . the first element is the rank of the matrix, . the second element is the rank of its transpose, . the third element is its determinant, . the fourth element is the inverse if its inverse exists and is the string "no inverse" if it does not exist. In [43]: I def ThreeVec (v1, v2, v3) : #YOUR CODE HERE #raise NotImplementedError( ) In [44]: I v1=np. array ([10, 4.4, 13]) v2=np. array ( [ -5, -3.1, 4]) v3=np. array ( [15, 5.7, 30]) assert (ThreeVec (v1, v2, v3) [0:2] == [2, 2]), "Problem 1.4, Your function does not compute the example correctly." assert (np. isclose(ThreeVec (v1, v2, v3) [2], 0)), "Problem 1.4, Your function does not compute the example correctly." assert(ThreeVec (v1, v2, v3) [3] == "no inverse"), "Problem 1.4, Your function does not compute the example correctly."

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 Mathematics Questions!