I have run the below code in Python to generate minor of a matrix but am not getting the desired output.
import numpy as np
m=np.array([(0,3,-1),(-1,11,-1),(2,-1,10)])
def getMatrixMinor(m,i,j):
return [row[:j] + row[j+1:] for row in (m[:i]+m[i+1:])]
getMatrixMinor(m,0,0)
If someone could pls suggest the corrections.