The rewrite relation of the following TRS is considered.
from(X) | → | cons(X,n__from(n__s(X))) | (1) |
head(cons(X,XS)) | → | X | (2) |
2nd(cons(X,XS)) | → | head(activate(XS)) | (3) |
take(0,XS) | → | nil | (4) |
take(s(N),cons(X,XS)) | → | cons(X,n__take(N,activate(XS))) | (5) |
sel(0,cons(X,XS)) | → | X | (6) |
sel(s(N),cons(X,XS)) | → | sel(N,activate(XS)) | (7) |
from(X) | → | n__from(X) | (8) |
s(X) | → | n__s(X) | (9) |
take(X1,X2) | → | n__take(X1,X2) | (10) |
activate(n__from(X)) | → | from(activate(X)) | (11) |
activate(n__s(X)) | → | s(activate(X)) | (12) |
activate(n__take(X1,X2)) | → | take(activate(X1),activate(X2)) | (13) |
activate(X) | → | X | (14) |
2nd#(cons(X,XS)) | → | head#(activate(XS)) | (15) |
2nd#(cons(X,XS)) | → | activate#(XS) | (16) |
take#(s(N),cons(X,XS)) | → | activate#(XS) | (17) |
sel#(s(N),cons(X,XS)) | → | sel#(N,activate(XS)) | (18) |
sel#(s(N),cons(X,XS)) | → | activate#(XS) | (19) |
activate#(n__from(X)) | → | from#(activate(X)) | (20) |
activate#(n__from(X)) | → | activate#(X) | (21) |
activate#(n__s(X)) | → | s#(activate(X)) | (22) |
activate#(n__s(X)) | → | activate#(X) | (23) |
activate#(n__take(X1,X2)) | → | take#(activate(X1),activate(X2)) | (24) |
activate#(n__take(X1,X2)) | → | activate#(X1) | (25) |
activate#(n__take(X1,X2)) | → | activate#(X2) | (26) |
The dependency pairs are split into 2 components.
sel#(s(N),cons(X,XS)) | → | sel#(N,activate(XS)) | (18) |
Using size-change termination in combination with the subterm criterion one obtains the following initial size-change graphs.
sel#(s(N),cons(X,XS)) | → | sel#(N,activate(XS)) | (18) |
1 | > | 1 |
As there is no critical graph in the transitive closure, there are no infinite chains.
activate#(n__from(X)) | → | activate#(X) | (21) |
activate#(n__s(X)) | → | activate#(X) | (23) |
activate#(n__take(X1,X2)) | → | take#(activate(X1),activate(X2)) | (24) |
take#(s(N),cons(X,XS)) | → | activate#(XS) | (17) |
activate#(n__take(X1,X2)) | → | activate#(X1) | (25) |
activate#(n__take(X1,X2)) | → | activate#(X2) | (26) |
prec(n__take) | = | 0 | weight(n__take) | = | 2 | ||||
prec(activate) | = | 4 | weight(activate) | = | 0 | ||||
prec(take) | = | 1 | weight(take) | = | 2 | ||||
prec(0) | = | 2 | weight(0) | = | 2 | ||||
prec(nil) | = | 3 | weight(nil) | = | 4 |
π(activate#) | = | 1 |
π(n__from) | = | 1 |
π(n__s) | = | 1 |
π(n__take) | = | [1,2] |
π(take#) | = | 2 |
π(activate) | = | [1] |
π(cons) | = | 2 |
π(from) | = | 1 |
π(s) | = | 1 |
π(take) | = | [1,2] |
π(0) | = | [] |
π(nil) | = | [] |
activate(n__from(X)) | → | from(activate(X)) | (11) |
activate(n__s(X)) | → | s(activate(X)) | (12) |
activate(n__take(X1,X2)) | → | take(activate(X1),activate(X2)) | (13) |
activate(X) | → | X | (14) |
take(s(N),cons(X,XS)) | → | cons(X,n__take(N,activate(XS))) | (5) |
s(X) | → | n__s(X) | (9) |
from(X) | → | cons(X,n__from(n__s(X))) | (1) |
from(X) | → | n__from(X) | (8) |
take(0,XS) | → | nil | (4) |
take(X1,X2) | → | n__take(X1,X2) | (10) |
activate#(n__take(X1,X2)) | → | take#(activate(X1),activate(X2)) | (24) |
activate#(n__take(X1,X2)) | → | activate#(X1) | (25) |
activate#(n__take(X1,X2)) | → | activate#(X2) | (26) |
The dependency pairs are split into 1 component.
activate#(n__s(X)) | → | activate#(X) | (23) |
activate#(n__from(X)) | → | activate#(X) | (21) |
[n__s(x1)] | = | 1 · x1 |
[n__from(x1)] | = | 1 · x1 |
[activate#(x1)] | = | 1 · x1 |
Using size-change termination in combination with the subterm criterion one obtains the following initial size-change graphs.
activate#(n__s(X)) | → | activate#(X) | (23) |
1 | > | 1 | |
activate#(n__from(X)) | → | activate#(X) | (21) |
1 | > | 1 |
As there is no critical graph in the transitive closure, there are no infinite chains.