17.4 Permanent of a Matrix

  • Permanent( mat ) F

    returns the permanent of the matrix mat. The permanent is defined by åp Î Symm(n)Õi = 1nmat[i][ip].

    Note the similarity of the definition of the permanent to the definition of the determinant (see DeterminantMat). In fact the only difference is the missing sign of the permutation. However the permanent is quite unlike the determinant, for example it is not multilinear or alternating. It has however important combinatorial properties.

    gap> Permanent( [[0,1,1,1],
    >      [1,0,1,1],
    >      [1,1,0,1],
    >      [1,1,1,0]] );
    9  # inefficient way to compute `NrDerangements([1..4])'
    gap> Permanent( [[1,1,0,1,0,0,0],
    >      [0,1,1,0,1,0,0],
    >      [0,0,1,1,0,1,0],
    >      [0,0,0,1,1,0,1],
    >      [1,0,0,0,1,1,0],
    >      [0,1,0,0,0,1,1],
    >      [1,0,1,0,0,0,1]] );
    24  # 24 permutations fit the projective plane of order 2 
    

    [Top] [Previous] [Up] [Index]

    GAP 4 manual
    February 2000