Term Rewriting System R: [X, Y, Z, X1, X2] first(0, X) -> nil first(s(X), cons(Y, Z)) -> cons(Y, n__first(X, activate(Z))) first(X1, X2) -> n__first(X1, X2) from(X) -> cons(X, n__from(n__s(X))) from(X) -> n__from(X) s(X) -> n__s(X) activate(n__first(X1, X2)) -> first(activate(X1), activate(X2)) activate(n__from(X)) -> from(activate(X)) activate(n__s(X)) -> s(activate(X)) activate(X) -> X Termination of R to be shown. R contains the following Dependency Pairs: ACTIVATE(n__s(X)) -> S(activate(X)) ACTIVATE(n__s(X)) -> ACTIVATE(X) ACTIVATE(n__first(X1, X2)) -> FIRST(activate(X1), activate(X2)) ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X1) ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X2) ACTIVATE(n__from(X)) -> FROM(activate(X)) ACTIVATE(n__from(X)) -> ACTIVATE(X) FIRST(s(X), cons(Y, Z)) -> ACTIVATE(Z) Furthermore, R contains one SCC. SCC1: ACTIVATE(n__from(X)) -> ACTIVATE(X) ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X2) ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X1) FIRST(s(X), cons(Y, Z)) -> ACTIVATE(Z) ACTIVATE(n__first(X1, X2)) -> FIRST(activate(X1), activate(X2)) ACTIVATE(n__s(X)) -> ACTIVATE(X) By using a polynomial ordering, at least one Dependency Pair of this SCC can be strictly oriented. Additionally, the following rules can be oriented: first(X1, X2) -> n__first(X1, X2) first(0, X) -> nil first(s(X), cons(Y, Z)) -> cons(Y, n__first(X, activate(Z))) activate(n__s(X)) -> s(activate(X)) activate(n__first(X1, X2)) -> first(activate(X1), activate(X2)) activate(X) -> X activate(n__from(X)) -> from(activate(X)) s(X) -> n__s(X) from(X) -> cons(X, n__from(n__s(X))) from(X) -> n__from(X) Used ordering: Polynomial ordering with Polynomial interpretation: POL(n__first(x_1, x_2)) = x_1 + x_2 POL(first(x_1, x_2)) = x_1 + x_2 POL(n__from(x_1)) = 1 + x_1 POL(nil) = 0 POL(activate(x_1)) = x_1 POL(s(x_1)) = x_1 POL(ACTIVATE(x_1)) = x_1 POL(from(x_1)) = 1 + x_1 POL(0) = 0 POL(FIRST(x_1, x_2)) = x_2 POL(n__s(x_1)) = x_1 POL(cons(x_1, x_2)) = x_2 resulting in one subcycle. SCC1.Polo1: ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X1) FIRST(s(X), cons(Y, Z)) -> ACTIVATE(Z) ACTIVATE(n__first(X1, X2)) -> FIRST(activate(X1), activate(X2)) ACTIVATE(n__s(X)) -> ACTIVATE(X) ACTIVATE(n__first(X1, X2)) -> ACTIVATE(X2) By using a polynomial ordering, at least one Dependency Pair of this SCC can be strictly oriented. Additionally, the following rules can be oriented: first(X1, X2) -> n__first(X1, X2) first(0, X) -> nil first(s(X), cons(Y, Z)) -> cons(Y, n__first(X, activate(Z))) activate(n__s(X)) -> s(activate(X)) activate(n__first(X1, X2)) -> first(activate(X1), activate(X2)) activate(X) -> X activate(n__from(X)) -> from(activate(X)) s(X) -> n__s(X) from(X) -> cons(X, n__from(n__s(X))) from(X) -> n__from(X) Used ordering: Polynomial ordering with Polynomial interpretation: POL(n__first(x_1, x_2)) = 1 + x_1 + x_2 POL(first(x_1, x_2)) = 1 + x_1 + x_2 POL(n__from(x_1)) = 0 POL(nil) = 0 POL(activate(x_1)) = x_1 POL(s(x_1)) = 1 + x_1 POL(ACTIVATE(x_1)) = x_1 POL(from(x_1)) = 0 POL(0) = 0 POL(FIRST(x_1, x_2)) = x_1 + x_2 POL(n__s(x_1)) = 1 + x_1 POL(cons(x_1, x_2)) = x_2 resulting in no subcycles. Termination of R successfully shown. Duration: 1.38 seconds.