next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
TensorComplexes :: hyperdeterminant

hyperdeterminant -- computes the hyperdeterminant of a boundary format tensor

Synopsis

Description

This constructs the hyperdeterminant of a tensor of boundary format, where we say that a a×b1×…×bn has boundary format if

a-∑i=1n (bi-1)=1.

We construct the hyperdeterminant as the determinant of a certain square matrix derived from f. The hyperdeterminant function outputs the hyperdeterminant itself, whereas the hyperdeterminantMatrix function outputs the matrix used to compute the hyperdeterminant. (For background on computing hyperdeterminants, see Section 14.3 of the book “Discriminants, resultants, and multidimensional determinants ” by Gelfand-Kapranov-Zelevinsky.)

The following constructs the generic hyperdetermiant of format 3×2×2, which is a polynomial of degree 6 consisting of 66 monomials.

i1 : f=flattenedGenericTensor({3,2,2},QQ);

                                                                                                                4                                                                                                          3
o1 : Matrix (QQ[x     , x     , x     , x     , x     , x     , x     , x     , x     , x     , x     , x     ])  <--- (QQ[x     , x     , x     , x     , x     , x     , x     , x     , x     , x     , x     , x     ])
                 0,0,0   0,0,1   0,1,0   0,1,1   1,0,0   1,0,1   1,1,0   1,1,1   2,0,0   2,0,1   2,1,0   2,1,1              0,0,0   0,0,1   0,1,0   0,1,1   1,0,0   1,0,1   1,1,0   1,1,1   2,0,0   2,0,1   2,1,0   2,1,1
i2 : S=ring f;
i3 : h=hyperdeterminant f;
i4 : degree h

o4 = {6}

o4 : List
i5 : #terms h

o5 = 66

Caveat

There is bug involving the graded structure of the output. Namely, the code assumes that all entries of f have degree 1, and gives the wrong graded structure if this is not the case. If ring f is not graded, then the code gives an error.

See also

Ways to use hyperdeterminant :