Jan-31-2022, 02:16 AM
I defined symbols via Sympy and I created an array. Then when I want to give a value to the variable, the variable still stay as variable.
a, b, c, d = sympy.symbols('a b c d') error_mat=np.array([[a+d,b-c*1j],[b+c*1j,a-d]]) error_mat.shapeThen, after I found the correct values for my variables, I simply say that:
a=0.9685 b=0.0315 print(error_mat) #error_mat.subs(a, 0.9685) #error_mat.subs(b, 0.0315)But my matrix is still:
[[a + d b - 1.0*I*c] [b + 1.0*I*c a - d]]How can I update the variables?