[SciPy-user] How to calculate minors.

A. M. Archibald peridot.faceted at gmail.com
Tue Oct 10 16:14:07 CDT 2006

On 10/10/06, Armando Serrano Lombillo <arserlom at gmail.com> wrote:
> Hello, is there any way to easily calculate minors of matrixes with
> scipy/numpy.
> For example if we have matrix a:
> [[1 2 3]
>  [4 5 6]
>  [7 8 9]]
> then minor(a,0) should be the same as det([[5,6],[8,9]]) and minor (a,1)
> should be the same as det([[1,3],[7,9]]).
> Armando.

You can always you fancy indexing to chop out the row and column you
are not interested in and take the determinant (with appropriate

Maybe a bit complicated, but if you want a single minor it's good
enough to implement minor() in pure python.

A. M. Archibald

More information about the SciPy-user mailing list