The rewrite relation of the following TRS is considered.
app(app(map,f),nil) | → | nil | (1) |
app(app(map,f),app(app(cons,x),xs)) | → | app(app(cons,app(f,x)),app(app(map,f),xs)) | (2) |
app(sum,app(app(cons,x),xs)) | → | app(app(plus,x),app(sum,xs)) | (3) |
app(size,app(app(node,x),xs)) | → | app(s,app(sum,app(app(map,size),xs))) | (4) |
app(app(plus,0),x) | → | 0 | (5) |
app(app(plus,app(s,x)),y) | → | app(s,app(app(plus,x),y)) | (6) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(app(map,f),xs) | (7) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(f,x) | (8) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(cons,app(f,x)) | (9) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(app(cons,app(f,x)),app(app(map,f),xs)) | (10) |
app#(sum,app(app(cons,x),xs)) | → | app#(sum,xs) | (11) |
app#(sum,app(app(cons,x),xs)) | → | app#(plus,x) | (12) |
app#(sum,app(app(cons,x),xs)) | → | app#(app(plus,x),app(sum,xs)) | (13) |
app#(size,app(app(node,x),xs)) | → | app#(map,size) | (14) |
app#(size,app(app(node,x),xs)) | → | app#(app(map,size),xs) | (15) |
app#(size,app(app(node,x),xs)) | → | app#(sum,app(app(map,size),xs)) | (16) |
app#(size,app(app(node,x),xs)) | → | app#(s,app(sum,app(app(map,size),xs))) | (17) |
app#(app(plus,app(s,x)),y) | → | app#(plus,x) | (18) |
app#(app(plus,app(s,x)),y) | → | app#(app(plus,x),y) | (19) |
app#(app(plus,app(s,x)),y) | → | app#(s,app(app(plus,x),y)) | (20) |
The dependency pairs are split into 3 components.
app#(size,app(app(node,x),xs)) | → | app#(app(map,size),xs) | (15) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(f,x) | (8) |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(app(map,f),xs) | (7) |
Using size-change termination in combination with the subterm criterion one obtains the following initial size-change graphs.
app#(size,app(app(node,x),xs)) | → | app#(app(map,size),xs) | (15) |
2 | > | 2 | |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(f,x) | (8) |
2 | > | 2 | |
1 | > | 1 | |
app#(app(map,f),app(app(cons,x),xs)) | → | app#(app(map,f),xs) | (7) |
2 | > | 2 | |
1 | ≥ | 1 |
As there is no critical graph in the transitive closure, there are no infinite chains.
app#(sum,app(app(cons,x),xs)) | → | app#(sum,xs) | (11) |
Using size-change termination in combination with the subterm criterion one obtains the following initial size-change graphs.
app#(sum,app(app(cons,x),xs)) | → | app#(sum,xs) | (11) |
2 | > | 2 | |
1 | ≥ | 1 |
As there is no critical graph in the transitive closure, there are no infinite chains.
app#(app(plus,app(s,x)),y) | → | app#(app(plus,x),y) | (19) |
prec(app#) | = | 0 | stat(app#) | = | lex | |
prec(s) | = | 0 | stat(s) | = | lex | |
prec(plus) | = | 0 | stat(plus) | = | lex | |
prec(app) | = | 1 | stat(app) | = | lex |
π(app#) | = | [1] |
π(s) | = | [] |
π(plus) | = | [] |
π(app) | = | [2] |
app#(app(plus,app(s,x)),y) | → | app#(app(plus,x),y) | (19) |
There are no pairs anymore.