@Test
public void testAdjustDegree() {

    assertCoefficientsEquals(new double[]{A, B, C}, valueOf(A, B, C).adjustDegree());
    assertCoefficientsEquals(new double[]{A, B}, valueOf(A, B, 0).adjustDegree());
    assertCoefficientsEquals(new double[]{0}, valueOf(0).adjustDegree());
    assertCoefficientsEquals(new double[]{A}, valueOf(A, EPS).adjustDegree());
    assertCoefficientsEquals(new double[]{A, EPS * 2}, valueOf(A, EPS * 2).adjustDegree());
    assertCoefficientsEquals(new double[]{A, 666 + EPS}, valueOf(A, 666 + EPS).adjustDegree());
}