For the general definition, suppose

*p*(*x*) =*x*^{n}+*a*_{n-1}*x*^{n-1}+ ... +*a*_{1}*x*+*a*_{0}

1a_{n-1}a_{n-2}. . .a_{0}0 . . . 0 0 1a_{n-1}a_{n-2}. . .a_{0}0 . . 0 0 0 1a_{n-1}a_{n-2}. . .a_{0}0 . 0 . . . . . . . . . . . . . . 0 0 0 0 0 1a_{n-1}a_{n-2}. . .a_{0}n(n-1)a_{\n-1}(n-2)a_{n-2}. . 1a_{1}0 0 . . . 0 0n(n-1)a_{n-1}(n-2)a_{n-2}. . 1a_{1}0 0 . . 0 0 0n(n-1)a_{n-1}(n-2)a_{n-2}. . 1a_{1}0 0 . 0 . . . . . . . . . . . . . . 0 0 0 0 0n(n-1)a_{n-1}a_{n-2}. . 1a_{1}0 0 0 0 0 0 0n(n-1)a_{n-1}a_{n-2}. . 1a_{1}

In the case *n*=4, this discriminant looks like this:

The discriminant of *p*(*x*) is thus equal to the resultant of *p*(*x*) and *p*'(*x*).

One can show that, up to sign, the discriminant is equal to

- Π
_{i<j}(*r*_{i}-*r*_{j})^{2}

*p*(*x*) = (*x*-*r*_{1}) (*x*-*r*_{2}) ... (*x*-*r*_{n})

In order to compute discriminants, one does not evaluate the above determinant each time for different coefficient, but instead one evaluates it only once for general coefficients to get an easy-to-use formula. For instance, the discriminant of a polynomial of third degree is *a*_{1}^{2}*a*_{2}^{2} - 4*a*_{0}*a*_{2}^{3} -4*a*_{1}^{3} + 18 *a*_{0}*a*_{1}*a*_{2} - 27*a*_{0}^{2}.

The discriminant can be defined for polynomials over arbitrary fields, in exactly the same fashion as above. The product formula involving the roots *r*_{i} remains valid; the roots have to be taken in some splitting field of the polynomial.