polynomials with three terms