Term Rewriting System R: [x, l, y] rev(nil) -> nil rev(cons(x, l)) -> cons(rev1(x, l), rev2(x, l)) rev1(0, nil) -> 0 rev1(s(x), nil) -> s(x) rev1(x, cons(y, l)) -> rev1(y, l) rev2(x, nil) -> nil rev2(x, cons(y, l)) -> rev(cons(x, rev2(y, l))) Termination of R to be shown. This program has no overlaps, so it is sufficient to show innermost termination. R contains the following Dependency Pairs: REV1(x, cons(y, l)) -> REV1(y, l) REV(cons(x, l)) -> REV1(x, l) REV(cons(x, l)) -> REV2(x, l) REV2(x, cons(y, l)) -> REV(cons(x, rev2(y, l))) REV2(x, cons(y, l)) -> REV2(y, l) Furthermore, R contains two SCCs. SCC1: REV1(x, cons(y, l)) -> REV1(y, l) Removing rules from R by ordering and analyzing Dependency Pairs, Usable Rules, and Usable Equations. This is possible by using the following (C_E-compatible) Polynomial ordering. Polynomial interpretation: POL(REV1(x_1, x_2)) = 1 + x_1 + x_2 POL(cons(x_1, x_2)) = 1 + x_1 + x_2 The following Dependency Pairs can be deleted: REV1(x, cons(y, l)) -> REV1(y, l) This transformation is resulting in no new subcycles. SCC2: REV2(x, cons(y, l)) -> REV2(y, l) REV2(x, cons(y, l)) -> REV(cons(x, rev2(y, l))) REV(cons(x, l)) -> REV2(x, l) By using a polynomial ordering, at least one Dependency Pair of this SCC can be strictly oriented. Additionally, the following rules can be oriented: rev2(x, cons(y, l)) -> rev(cons(x, rev2(y, l))) rev2(x, nil) -> nil rev(nil) -> nil rev(cons(x, l)) -> cons(rev1(x, l), rev2(x, l)) Used ordering: Polynomial ordering with Polynomial interpretation: POL(nil) = 0 POL(s(x_1)) = 0 POL(rev2(x_1, x_2)) = x_2 POL(REV(x_1)) = x_1 POL(rev1(x_1, x_2)) = 0 POL(rev(x_1)) = x_1 POL(REV2(x_1, x_2)) = x_2 POL(0) = 0 POL(cons(x_1, x_2)) = 1 + x_2 resulting in no subcycles. Termination of R successfully shown. Duration: 0.711 seconds.