(0) Obligation:

Q restricted rewrite system:
The TRS R consists of the following rules:

active(from(X)) → mark(cons(X, from(s(X))))
active(length(nil)) → mark(0)
active(length(cons(X, Y))) → mark(s(length1(Y)))
active(length1(X)) → mark(length(X))
active(from(X)) → from(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(s(X)) → s(active(X))
from(mark(X)) → mark(from(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
s(mark(X)) → mark(s(X))
proper(from(X)) → from(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(s(X)) → s(proper(X))
proper(length(X)) → length(proper(X))
proper(nil) → ok(nil)
proper(0) → ok(0)
proper(length1(X)) → length1(proper(X))
from(ok(X)) → ok(from(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
s(ok(X)) → ok(s(X))
length(ok(X)) → ok(length(X))
length1(ok(X)) → ok(length1(X))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.

(1) QTRSToCSRProof (EQUIVALENT transformation)

The following Q TRS is given: Q restricted rewrite system:
The TRS R consists of the following rules:

active(from(X)) → mark(cons(X, from(s(X))))
active(length(nil)) → mark(0)
active(length(cons(X, Y))) → mark(s(length1(Y)))
active(length1(X)) → mark(length(X))
active(from(X)) → from(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(s(X)) → s(active(X))
from(mark(X)) → mark(from(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
s(mark(X)) → mark(s(X))
proper(from(X)) → from(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(s(X)) → s(proper(X))
proper(length(X)) → length(proper(X))
proper(nil) → ok(nil)
proper(0) → ok(0)
proper(length1(X)) → length1(proper(X))
from(ok(X)) → ok(from(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
s(ok(X)) → ok(s(X))
length(ok(X)) → ok(length(X))
length1(ok(X)) → ok(length1(X))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
Special symbols used for the transformation (see [GM04]):
top: top, active: active, mark: mark, ok: ok, proper: proper
The replacement map contains the following entries:

from: {1}
cons: {1}
s: {1}
length: empty set
nil: empty set
0: empty set
length1: empty set
The QTRS contained all rules created by the complete Giesl-Middeldorp transformation. Therefore, the inverse transformation is complete (and sound).

(2) Obligation:

Context-sensitive rewrite system:
The TRS R consists of the following rules:

from(X) → cons(X, from(s(X)))
length(nil) → 0
length(cons(X, Y)) → s(length1(Y))
length1(X) → length(X)

The replacement map contains the following entries:

from: {1}
cons: {1}
s: {1}
length: empty set
nil: empty set
0: empty set
length1: empty set

(3) PoloCSRProof (EQUIVALENT transformation)

The following rules can be removed because they are oriented strictly by a µ-monotonic polynomial ordering:

from(X) → cons(X, from(s(X)))
Used ordering:
Polynomial interpretation [POLO]:

POL(0) = 0   
POL(cons(x1, x2)) = x1   
POL(from(x1)) = 2 + 2·x1   
POL(length(x1)) = 0   
POL(length1(x1)) = 0   
POL(nil) = 2   
POL(s(x1)) = 2·x1   


(4) Obligation:

Context-sensitive rewrite system:
The TRS R consists of the following rules:

length(nil) → 0
length(cons(X, Y)) → s(length1(Y))
length1(X) → length(X)

The replacement map contains the following entries:

cons: {1}
s: {1}
length: empty set
nil: empty set
0: empty set
length1: empty set

(5) PoloCSRProof (EQUIVALENT transformation)

The following rules can be removed because they are oriented strictly by a µ-monotonic polynomial ordering:

length(nil) → 0
length(cons(X, Y)) → s(length1(Y))
length1(X) → length(X)
Used ordering:
Polynomial interpretation [POLO]:

POL(0) = 2   
POL(cons(x1, x2)) = 2 + x1 + 2·x2   
POL(length(x1)) = 1 + 2·x1   
POL(length1(x1)) = 2 + 2·x1   
POL(nil) = 2   
POL(s(x1)) = x1   


(6) Obligation:

Context-sensitive rewrite system:
R is empty.

(7) RisEmptyProof (EQUIVALENT transformation)

The CSR R is empty. Hence, termination is trivially proven.

(8) TRUE