Question: Whats wrong with the code? I keep getting assertion error 4 . 3 [ 2 p t What 2 2 matrix, with integer entries, has
Whats wrong with the code? I keep getting assertion error
What matrix, with integer entries, has and as eigenvalues with eigenvectors and respectively? Store it in the variable matrixanswer.
Hint: Put variables for entries in a array write out the equations that must be satisfied, and solve for the entires.
In : import numpy as np
array
vals, vecslinalg
if npiscomplexvals any:
vals vals.real
if npiscomplexvecs any:
vecs vecs real
vals
vecs
avecs
vals
matrixanswer nparray
print matrixanswer
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
