How do I solve the determinant of this matrix using python? there are how solve using the word x in python?
p = np.array([[x, 1],
[1, x]])
How do I solve the determinant of this matrix using python? there are how solve using the word x in python?
p = np.array([[x, 1],
[1, x]])
The numpy.linalg.det() function calculates the determinant of the input matrix.
Example:
import numpy as np
a = np.array([[1,2], [3,4]])
print np.linalg.det(a)