This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.


Permanent of a matrix

MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.

MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.




linalg::permanent(A) computes the permanent of the square matrix A.

The component ring of the matrix A must be a commutative ring, i.e., a domain of category Cat::CommutativeRing.


Example 1

We compute the permanent of the following matrix:

delete a11, a12, a21, a22:
A := matrix([[a11, a12], [a21, a22]])

which gives us the general formula for the permanent of an arbitrary 2 ×2 matrix:


Example 2

The permanent of a matrix can be computed over arbitrary commutative rings. Let us create a random matrix defined over the ring 6, the integers modulo 6:

B := linalg::randomMatrix(5, 5, Dom::IntegerMod(6))

The permanent of this matrix is:


Its determinant is:




A square matrix of a domain of category Cat::Matrix

Return Values

Element of the component ring of A.


The permanent of an n×n matrix A = (ai, j)1 ≤ in, 1 ≤ jn is defined similary as the determinant of A, only the signs of the permutations do not enter the definition:


(Sn is the symmetric group of all permutations of {1, …, n}.)

In contrast to the computation of the determinant, the computation of the permanent takes time O(n2 2n).

See Also

MuPAD Functions

Was this topic helpful?