Search for a tool
Cofactor Matrix

Tool to compute a Cofactor matrix: a mathematical matrix composed of the determinants of its sub-matrices (also called minors).

Results

Cofactor Matrix -

Tag(s) : Matrix

Share
Share
dCode and more

dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!


Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!


Feedback and suggestions are welcome so that dCode offers the best 'Cofactor Matrix' tool for free! Thank you!

Cofactor Matrix

Matrix Cofactor Calculator

Loading...
(if this message do not disappear, try to refresh this page)


Answers to Questions (FAQ)

What is the matrix of cofactors? (Definition)

The cofactor matrix of a square matrix $ M = [a_{i,j}] $ is noted $ Cof(M) $. It is the matrix of the cofactors, i.e. the minors weighted by a factor $ (-1)^{i+j} $.

How to calculate the matrix of cofactors?

For each item in the matrix, compute the determinant of the sub-matrix $ SM $ associated. The determinant is noted $ \text{Det}(SM) $ or $ | SM | $ and is also called minor. To calculate $ Cof(M) $ multiply each minor by a $ -1 $ factor according to the position in the matrix.

$$ Cof_{i,j} = (-1)^{i+j} \text{Det}(SM_i) $$

Calculation of a 2x2 cofactor matrix:

$$ M = \begin{bmatrix} a & b \\ c & d \end{bmatrix} $$

$$ M = \begin{bmatrix} a & b \\ c & d \end{bmatrix} $$

$$ Cof(M) = \begin{bmatrix} d & -c \\ -b & a \end{bmatrix} $$

Example: $$ M = \begin{bmatrix} 1 & 2 \\ 3 & 4 \end{bmatrix} \Rightarrow Cof(M) = \begin{bmatrix} 4 & -3 \\ -2 & 1 \end{bmatrix} $$

Calculation of a 3x3 cofactor matrix:

$$ M = \begin{bmatrix} a & b & c \\d & e & f \\ g & h & i \end{bmatrix} $$

$$ Cof(M) = \begin{bmatrix} + \begin{vmatrix} e & f \\ h & i \end{vmatrix} & -\begin{vmatrix} d & f \\ g & i \end{vmatrix} & +\begin{vmatrix} d & e \\ g & h \end{vmatrix} \\ & & \\ -\begin{vmatrix} b & c \\ h & i \end{vmatrix} & +\begin{vmatrix} a & c \\ g & i \end{vmatrix} & -\begin{vmatrix} a & b \\ g & h \end{vmatrix} \\ & & \\ +\begin{vmatrix} b & c \\ e & f \end{vmatrix} & -\begin{vmatrix} a & c \\ d & f \end{vmatrix} & +\begin{vmatrix} a & b \\ d & e \end{vmatrix} \end{bmatrix} $$

The transpose of the cofactor matrix (comatrix) is the adjoint matrix.

What are the properties of the cofactor matrix?

Most of the properties of the cofactor matrix actually concern its transpose, the transpose of the matrix of the cofactors is called adjugate matrix.

$$ A({}^t{{\rm com} A}) = ({}^t{{\rm com} A})A =\det{A} \times I_n $$

$$ A^{-1}=\frac1{\det A} \, {}^t{{\rm com} A} $$

What is the cofactor of a matrix?

A cofactor is calculated from the minor of the submatrix.

$$ Cof_{i,j} = (-1)^{i+j} \text{Det}(SM_i) $$

Source code

dCode retains ownership of the "Cofactor Matrix" source code. Any algorithm for the "Cofactor Matrix" algorithm, applet or snippet or script (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, breaker, translator), or any "Cofactor Matrix" functions (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) or any database download or API access for "Cofactor Matrix" or any other element are not public (except explicit open source licence like Creative Commons). Same with the download for offline use on PC, mobile, tablet, iPhone or Android app.
Reminder: dCode is an educational and teaching resource, accessible online for free and for everyone.

Cite dCode

The content of the page "Cofactor Matrix" and its results may be freely copied and reused, including for commercial purposes, provided that dCode.fr is cited as the source. Exporting the results is free and can be done simply by clicking on the export icons ⤓ (.csv or .txt format) or ⧉ (copy and paste).
To cite dCode.fr on another website, use the link: https://www.dcode.fr/cofactor-matrix
In a scientific article or book, the recommended bibliographic citation is: Cofactor Matrix on dCode.fr [online website], retrieved on 2025-04-16, https://www.dcode.fr/cofactor-matrix

Need Help ?

Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!

Questions / Comments

Feedback and suggestions are welcome so that dCode offers the best 'Cofactor Matrix' tool for free! Thank you!


https://www.dcode.fr/cofactor-matrix
© 2025 dCode — The ultimate collection of tools for games, math, and puzzles.
 
Feedback