(0) Obligation:
Runtime Complexity TRS:
The TRS R consists of the following rules:
active(from(X)) → mark(cons(X, from(s(X))))
active(head(cons(X, XS))) → mark(X)
active(2nd(cons(X, XS))) → mark(head(XS))
active(take(0, XS)) → mark(nil)
active(take(s(N), cons(X, XS))) → mark(cons(X, take(N, XS)))
active(sel(0, cons(X, XS))) → mark(X)
active(sel(s(N), cons(X, XS))) → mark(sel(N, XS))
active(from(X)) → from(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(s(X)) → s(active(X))
active(head(X)) → head(active(X))
active(2nd(X)) → 2nd(active(X))
active(take(X1, X2)) → take(active(X1), X2)
active(take(X1, X2)) → take(X1, active(X2))
active(sel(X1, X2)) → sel(active(X1), X2)
active(sel(X1, X2)) → sel(X1, active(X2))
from(mark(X)) → mark(from(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
s(mark(X)) → mark(s(X))
head(mark(X)) → mark(head(X))
2nd(mark(X)) → mark(2nd(X))
take(mark(X1), X2) → mark(take(X1, X2))
take(X1, mark(X2)) → mark(take(X1, X2))
sel(mark(X1), X2) → mark(sel(X1, X2))
sel(X1, mark(X2)) → mark(sel(X1, X2))
proper(from(X)) → from(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(s(X)) → s(proper(X))
proper(head(X)) → head(proper(X))
proper(2nd(X)) → 2nd(proper(X))
proper(take(X1, X2)) → take(proper(X1), proper(X2))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(X1, X2)) → sel(proper(X1), proper(X2))
from(ok(X)) → ok(from(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
s(ok(X)) → ok(s(X))
head(ok(X)) → ok(head(X))
2nd(ok(X)) → ok(2nd(X))
take(ok(X1), ok(X2)) → ok(take(X1, X2))
sel(ok(X1), ok(X2)) → ok(sel(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))
Rewrite Strategy: INNERMOST
(1) CpxTrsToCdtProof (BOTH BOUNDS(ID, ID) transformation)
Converted Cpx (relative) TRS to CDT
(2) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
cons(mark(z0), z1) → mark(cons(z0, z1))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
take(mark(z0), z1) → mark(take(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:
ACTIVE(from(z0)) → c(CONS(z0, from(s(z0))), FROM(s(z0)), S(z0))
ACTIVE(head(cons(z0, z1))) → c1
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(0, z0)) → c3
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(0, cons(z0, z1))) → c5
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(0) → c38
PROPER(nil) → c39
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
S tuples:
ACTIVE(from(z0)) → c(CONS(z0, from(s(z0))), FROM(s(z0)), S(z0))
ACTIVE(head(cons(z0, z1))) → c1
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(0, z0)) → c3
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(0, cons(z0, z1))) → c5
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(0) → c38
PROPER(nil) → c39
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
K tuples:none
Defined Rule Symbols:
active, from, cons, s, head, 2nd, take, sel, proper, top
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c38, c39, c40, c41, c42
(3) CdtLeafRemovalProof (BOTH BOUNDS(ID, ID) transformation)
Removed 5 trailing nodes:
PROPER(nil) → c39
ACTIVE(take(0, z0)) → c3
PROPER(0) → c38
ACTIVE(sel(0, cons(z0, z1))) → c5
ACTIVE(head(cons(z0, z1))) → c1
(4) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
cons(mark(z0), z1) → mark(cons(z0, z1))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
take(mark(z0), z1) → mark(take(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:
ACTIVE(from(z0)) → c(CONS(z0, from(s(z0))), FROM(s(z0)), S(z0))
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
S tuples:
ACTIVE(from(z0)) → c(CONS(z0, from(s(z0))), FROM(s(z0)), S(z0))
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
K tuples:none
Defined Rule Symbols:
active, from, cons, s, head, 2nd, take, sel, proper, top
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c, c2, c4, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42
(5) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(6) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
cons(mark(z0), z1) → mark(cons(z0, z1))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
take(mark(z0), z1) → mark(take(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(take(s(z0), cons(z1, z2))) → c4(CONS(z1, take(z0, z2)), TAKE(z0, z2))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
K tuples:none
Defined Rule Symbols:
active, from, cons, s, head, 2nd, take, sel, proper, top
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c4, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c
(7) CdtGraphSplitRhsProof (BOTH BOUNDS(ID, ID) transformation)
Split RHS of tuples not part of any SCC
(8) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
cons(mark(z0), z1) → mark(cons(z0, z1))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
take(mark(z0), z1) → mark(take(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
K tuples:none
Defined Rule Symbols:
active, from, cons, s, head, 2nd, take, sel, proper, top
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1
(9) CdtUsableRulesProof (EQUIVALENT transformation)
The following rules are not usable and were removed:
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
(10) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(from(z0)) → c7(FROM(active(z0)), ACTIVE(z0))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1
(11) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
ACTIVE(
from(
z0)) →
c7(
FROM(
active(
z0)),
ACTIVE(
z0)) by
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(12) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(cons(z0, z1)) → c8(CONS(active(z0), z1), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7
(13) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
ACTIVE(
cons(
z0,
z1)) →
c8(
CONS(
active(
z0),
z1),
ACTIVE(
z0)) by
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
(14) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8
(15) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
ACTIVE(
s(
z0)) →
c9(
S(
active(
z0)),
ACTIVE(
z0)) by
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(16) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(head(z0)) → c10(HEAD(active(z0)), ACTIVE(z0))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9
(17) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
ACTIVE(
head(
z0)) →
c10(
HEAD(
active(
z0)),
ACTIVE(
z0)) by
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(18) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(2nd(z0)) → c11(2ND(active(z0)), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10
(19) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
ACTIVE(
2nd(
z0)) →
c11(
2ND(
active(
z0)),
ACTIVE(
z0)) by
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(20) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(from(z0)) → c32(FROM(proper(z0)), PROPER(z0))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c32, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11
(21) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
from(
z0)) →
c32(
FROM(
proper(
z0)),
PROPER(
z0)) by
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)), PROPER(0))
PROPER(from(nil)) → c32(FROM(ok(nil)), PROPER(nil))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
(22) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)), PROPER(0))
PROPER(from(nil)) → c32(FROM(ok(nil)), PROPER(nil))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)), PROPER(0))
PROPER(from(nil)) → c32(FROM(ok(nil)), PROPER(nil))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32
(23) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(24) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(cons(z0, z1)) → c33(CONS(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c33, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32
(25) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
cons(
z0,
z1)) →
c33(
CONS(
proper(
z0),
proper(
z1)),
PROPER(
z0),
PROPER(
z1)) by
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
(26) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33
(27) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 4 trailing tuple parts
(28) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(s(z0)) → c34(S(proper(z0)), PROPER(z0))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c34, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33
(29) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
s(
z0)) →
c34(
S(
proper(
z0)),
PROPER(
z0)) by
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)), PROPER(0))
PROPER(s(nil)) → c34(S(ok(nil)), PROPER(nil))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
(30) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)), PROPER(0))
PROPER(s(nil)) → c34(S(ok(nil)), PROPER(nil))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)), PROPER(0))
PROPER(s(nil)) → c34(S(ok(nil)), PROPER(nil))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34
(31) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(32) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(head(z0)) → c35(HEAD(proper(z0)), PROPER(z0))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c35, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34
(33) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
head(
z0)) →
c35(
HEAD(
proper(
z0)),
PROPER(
z0)) by
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)), PROPER(0))
PROPER(head(nil)) → c35(HEAD(ok(nil)), PROPER(nil))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
(34) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)), PROPER(0))
PROPER(head(nil)) → c35(HEAD(ok(nil)), PROPER(nil))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)), PROPER(0))
PROPER(head(nil)) → c35(HEAD(ok(nil)), PROPER(nil))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35
(35) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(36) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(2nd(z0)) → c36(2ND(proper(z0)), PROPER(z0))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c36, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35
(37) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
2nd(
z0)) →
c36(
2ND(
proper(
z0)),
PROPER(
z0)) by
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)), PROPER(0))
PROPER(2nd(nil)) → c36(2ND(ok(nil)), PROPER(nil))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
(38) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)), PROPER(0))
PROPER(2nd(nil)) → c36(2ND(ok(nil)), PROPER(nil))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)), PROPER(0))
PROPER(2nd(nil)) → c36(2ND(ok(nil)), PROPER(nil))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36
(39) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(40) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(take(z0, z1)) → c37(TAKE(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c37, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36
(41) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
take(
z0,
z1)) →
c37(
TAKE(
proper(
z0),
proper(
z1)),
PROPER(
z0),
PROPER(
z1)) by
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
(42) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37
(43) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 4 trailing tuple parts
(44) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
PROPER(sel(z0, z1)) → c40(SEL(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c40, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37
(45) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
PROPER(
sel(
z0,
z1)) →
c40(
SEL(
proper(
z0),
proper(
z1)),
PROPER(
z0),
PROPER(
z1)) by
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
(46) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0), PROPER(nil))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(nil), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, TOP, PROPER
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40
(47) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 4 trailing tuple parts
(48) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(mark(z0)) → c41(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, TOP, PROPER
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c41, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40
(49) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
TOP(
mark(
z0)) →
c41(
TOP(
proper(
z0)),
PROPER(
z0)) by
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)), PROPER(0))
TOP(mark(nil)) → c41(TOP(ok(nil)), PROPER(nil))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
(50) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)), PROPER(0))
TOP(mark(nil)) → c41(TOP(ok(nil)), PROPER(nil))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)), PROPER(0))
TOP(mark(nil)) → c41(TOP(ok(nil)), PROPER(nil))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, TOP, PROPER
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40, c41
(51) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing tuple parts
(52) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, TOP, PROPER
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40, c41, c41
(53) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)
Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
We considered the (Usable) Rules:
active(sel(0, cons(z0, z1))) → mark(z0)
from(ok(z0)) → ok(from(z0))
from(mark(z0)) → mark(from(z0))
take(mark(z0), z1) → mark(take(z0, z1))
active(head(cons(z0, z1))) → mark(z0)
active(sel(z0, z1)) → sel(active(z0), z1)
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
active(2nd(z0)) → 2nd(active(z0))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
active(head(z0)) → head(active(z0))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(z0, z1)) → take(z0, active(z1))
take(z0, mark(z1)) → mark(take(z0, z1))
head(ok(z0)) → ok(head(z0))
active(take(0, z0)) → mark(nil)
2nd(mark(z0)) → mark(2nd(z0))
head(mark(z0)) → mark(head(z0))
sel(mark(z0), z1) → mark(sel(z0, z1))
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
2nd(ok(z0)) → ok(2nd(z0))
s(ok(z0)) → ok(s(z0))
s(mark(z0)) → mark(s(z0))
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(take(z0, z1)) → take(active(z0), z1)
active(s(z0)) → s(active(z0))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
cons(mark(z0), z1) → mark(cons(z0, z1))
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(sel(z0, z1)) → sel(z0, active(z1))
And the Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
The order we found is given by the following interpretation:
Polynomial interpretation :
POL(0) = [1]
POL(2ND(x1)) = 0
POL(2nd(x1)) = [2]
POL(ACTIVE(x1)) = 0
POL(CONS(x1, x2)) = 0
POL(FROM(x1)) = 0
POL(HEAD(x1)) = 0
POL(PROPER(x1)) = 0
POL(S(x1)) = 0
POL(SEL(x1, x2)) = 0
POL(TAKE(x1, x2)) = 0
POL(TOP(x1)) = x1
POL(active(x1)) = x1
POL(c(x1)) = x1
POL(c1(x1)) = x1
POL(c10(x1, x2)) = x1 + x2
POL(c11(x1, x2)) = x1 + x2
POL(c12(x1, x2)) = x1 + x2
POL(c13(x1, x2)) = x1 + x2
POL(c14(x1, x2)) = x1 + x2
POL(c15(x1, x2)) = x1 + x2
POL(c16(x1)) = x1
POL(c17(x1)) = x1
POL(c18(x1)) = x1
POL(c19(x1)) = x1
POL(c2(x1)) = x1
POL(c20(x1)) = x1
POL(c21(x1)) = x1
POL(c22(x1)) = x1
POL(c23(x1)) = x1
POL(c24(x1)) = x1
POL(c25(x1)) = x1
POL(c26(x1)) = x1
POL(c27(x1)) = x1
POL(c28(x1)) = x1
POL(c29(x1)) = x1
POL(c30(x1)) = x1
POL(c31(x1)) = x1
POL(c32(x1)) = x1
POL(c32(x1, x2)) = x1 + x2
POL(c33(x1, x2)) = x1 + x2
POL(c33(x1, x2, x3)) = x1 + x2 + x3
POL(c34(x1)) = x1
POL(c34(x1, x2)) = x1 + x2
POL(c35(x1)) = x1
POL(c35(x1, x2)) = x1 + x2
POL(c36(x1)) = x1
POL(c36(x1, x2)) = x1 + x2
POL(c37(x1, x2)) = x1 + x2
POL(c37(x1, x2, x3)) = x1 + x2 + x3
POL(c40(x1, x2)) = x1 + x2
POL(c40(x1, x2, x3)) = x1 + x2 + x3
POL(c41(x1)) = x1
POL(c41(x1, x2)) = x1 + x2
POL(c42(x1, x2)) = x1 + x2
POL(c6(x1)) = x1
POL(c7(x1, x2)) = x1 + x2
POL(c8(x1, x2)) = x1 + x2
POL(c9(x1, x2)) = x1 + x2
POL(cons(x1, x2)) = [2]
POL(from(x1)) = [2]
POL(head(x1)) = [2]
POL(mark(x1)) = [2]
POL(nil) = [1]
POL(ok(x1)) = x1
POL(proper(x1)) = 0
POL(s(x1)) = [2]
POL(sel(x1, x2)) = [2]
POL(take(x1, x2)) = [2]
(54) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
TOP(ok(z0)) → c42(TOP(active(z0)), ACTIVE(z0))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
K tuples:
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, TOP, PROPER
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c42, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40, c41, c41
(55) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)
Use narrowing to replace
TOP(
ok(
z0)) →
c42(
TOP(
active(
z0)),
ACTIVE(
z0)) by
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(56) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:
TOP(mark(0)) → c41(TOP(ok(0)))
TOP(mark(nil)) → c41(TOP(ok(nil)))
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40, c41, c41, c42
(57) CdtLeafRemovalProof (BOTH BOUNDS(ID, ID) transformation)
Removed 2 trailing nodes:
TOP(mark(nil)) → c41(TOP(ok(nil)))
TOP(mark(0)) → c41(TOP(ok(0)))
(58) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
S tuples:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
ACTIVE, FROM, CONS, S, HEAD, 2ND, TAKE, SEL, PROPER, TOP
Compound Symbols:
c2, c6, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31, c, c1, c7, c8, c9, c10, c11, c32, c32, c33, c33, c34, c34, c35, c35, c36, c36, c37, c37, c40, c40, c41, c42
(59) CdtUnreachableProof (EQUIVALENT transformation)
The following tuples could be removed as they are not reachable from basic start terms:
ACTIVE(2nd(cons(z0, z1))) → c2(HEAD(z1))
ACTIVE(sel(s(z0), cons(z1, z2))) → c6(SEL(z0, z2))
ACTIVE(take(z0, z1)) → c12(TAKE(active(z0), z1), ACTIVE(z0))
ACTIVE(take(z0, z1)) → c13(TAKE(z0, active(z1)), ACTIVE(z1))
ACTIVE(sel(z0, z1)) → c14(SEL(active(z0), z1), ACTIVE(z0))
ACTIVE(sel(z0, z1)) → c15(SEL(z0, active(z1)), ACTIVE(z1))
ACTIVE(from(z0)) → c(S(z0))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(CONS(z1, take(z0, z2)))
ACTIVE(take(s(z0), cons(z1, z2))) → c1(TAKE(z0, z2))
ACTIVE(from(from(z0))) → c7(FROM(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(from(head(cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(from(2nd(cons(z0, z1)))) → c7(FROM(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(from(take(0, z0))) → c7(FROM(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(from(take(s(z0), cons(z1, z2)))) → c7(FROM(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(from(sel(0, cons(z0, z1)))) → c7(FROM(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(from(sel(s(z0), cons(z1, z2)))) → c7(FROM(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(from(from(z0))) → c7(FROM(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(from(cons(z0, z1))) → c7(FROM(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(from(s(z0))) → c7(FROM(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(from(head(z0))) → c7(FROM(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(from(2nd(z0))) → c7(FROM(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(from(take(z0, z1))) → c7(FROM(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(from(sel(z0, z1))) → c7(FROM(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(cons(from(z0), x1)) → c8(CONS(mark(cons(z0, from(s(z0)))), x1), ACTIVE(from(z0)))
ACTIVE(cons(head(cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(head(cons(z0, z1))))
ACTIVE(cons(2nd(cons(z0, z1)), x1)) → c8(CONS(mark(head(z1)), x1), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(cons(take(0, z0), x1)) → c8(CONS(mark(nil), x1), ACTIVE(take(0, z0)))
ACTIVE(cons(take(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(cons(z1, take(z0, z2))), x1), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(cons(sel(0, cons(z0, z1)), x1)) → c8(CONS(mark(z0), x1), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(cons(sel(s(z0), cons(z1, z2)), x1)) → c8(CONS(mark(sel(z0, z2)), x1), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(cons(from(z0), x1)) → c8(CONS(from(active(z0)), x1), ACTIVE(from(z0)))
ACTIVE(cons(cons(z0, z1), x1)) → c8(CONS(cons(active(z0), z1), x1), ACTIVE(cons(z0, z1)))
ACTIVE(cons(s(z0), x1)) → c8(CONS(s(active(z0)), x1), ACTIVE(s(z0)))
ACTIVE(cons(head(z0), x1)) → c8(CONS(head(active(z0)), x1), ACTIVE(head(z0)))
ACTIVE(cons(2nd(z0), x1)) → c8(CONS(2nd(active(z0)), x1), ACTIVE(2nd(z0)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(active(z0), z1), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(take(z0, z1), x1)) → c8(CONS(take(z0, active(z1)), x1), ACTIVE(take(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(active(z0), z1), x1), ACTIVE(sel(z0, z1)))
ACTIVE(cons(sel(z0, z1), x1)) → c8(CONS(sel(z0, active(z1)), x1), ACTIVE(sel(z0, z1)))
ACTIVE(s(from(z0))) → c9(S(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(s(head(cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(s(2nd(cons(z0, z1)))) → c9(S(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(s(take(0, z0))) → c9(S(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(s(take(s(z0), cons(z1, z2)))) → c9(S(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(s(sel(0, cons(z0, z1)))) → c9(S(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(s(sel(s(z0), cons(z1, z2)))) → c9(S(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(s(from(z0))) → c9(S(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(s(cons(z0, z1))) → c9(S(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(head(z0))) → c9(S(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(s(2nd(z0))) → c9(S(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(s(take(z0, z1))) → c9(S(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(s(take(z0, z1))) → c9(S(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(s(sel(z0, z1))) → c9(S(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(head(from(z0))) → c10(HEAD(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(head(head(cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(head(2nd(cons(z0, z1)))) → c10(HEAD(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(head(take(0, z0))) → c10(HEAD(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(head(take(s(z0), cons(z1, z2)))) → c10(HEAD(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(head(sel(0, cons(z0, z1)))) → c10(HEAD(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(head(sel(s(z0), cons(z1, z2)))) → c10(HEAD(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(head(from(z0))) → c10(HEAD(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(head(cons(z0, z1))) → c10(HEAD(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(head(s(z0))) → c10(HEAD(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(head(head(z0))) → c10(HEAD(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(head(2nd(z0))) → c10(HEAD(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(head(take(z0, z1))) → c10(HEAD(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(head(sel(z0, z1))) → c10(HEAD(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(from(z0))) → c11(2ND(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
ACTIVE(2nd(head(cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(head(cons(z0, z1))))
ACTIVE(2nd(2nd(cons(z0, z1)))) → c11(2ND(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
ACTIVE(2nd(take(0, z0))) → c11(2ND(mark(nil)), ACTIVE(take(0, z0)))
ACTIVE(2nd(take(s(z0), cons(z1, z2)))) → c11(2ND(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
ACTIVE(2nd(sel(0, cons(z0, z1)))) → c11(2ND(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
ACTIVE(2nd(sel(s(z0), cons(z1, z2)))) → c11(2ND(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
ACTIVE(2nd(from(z0))) → c11(2ND(from(active(z0))), ACTIVE(from(z0)))
ACTIVE(2nd(cons(z0, z1))) → c11(2ND(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
ACTIVE(2nd(s(z0))) → c11(2ND(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(2nd(head(z0))) → c11(2ND(head(active(z0))), ACTIVE(head(z0)))
ACTIVE(2nd(2nd(z0))) → c11(2ND(2nd(active(z0))), ACTIVE(2nd(z0)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(active(z0), z1)), ACTIVE(take(z0, z1)))
ACTIVE(2nd(take(z0, z1))) → c11(2ND(take(z0, active(z1))), ACTIVE(take(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
ACTIVE(2nd(sel(z0, z1))) → c11(2ND(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
PROPER(from(from(z0))) → c32(FROM(from(proper(z0))), PROPER(from(z0)))
PROPER(from(cons(z0, z1))) → c32(FROM(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(from(s(z0))) → c32(FROM(s(proper(z0))), PROPER(s(z0)))
PROPER(from(head(z0))) → c32(FROM(head(proper(z0))), PROPER(head(z0)))
PROPER(from(2nd(z0))) → c32(FROM(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(from(take(z0, z1))) → c32(FROM(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(from(sel(z0, z1))) → c32(FROM(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(from(0)) → c32(FROM(ok(0)))
PROPER(from(nil)) → c32(FROM(ok(nil)))
PROPER(cons(x0, from(z0))) → c33(CONS(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(cons(x0, cons(z0, z1))) → c33(CONS(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(cons(x0, s(z0))) → c33(CONS(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(cons(x0, head(z0))) → c33(CONS(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(cons(x0, 2nd(z0))) → c33(CONS(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(cons(x0, take(z0, z1))) → c33(CONS(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(cons(x0, sel(z0, z1))) → c33(CONS(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(cons(from(z0), x1)) → c33(CONS(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(cons(cons(z0, z1), x1)) → c33(CONS(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(cons(s(z0), x1)) → c33(CONS(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(cons(head(z0), x1)) → c33(CONS(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(cons(2nd(z0), x1)) → c33(CONS(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(cons(take(z0, z1), x1)) → c33(CONS(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(cons(sel(z0, z1), x1)) → c33(CONS(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(cons(x0, 0)) → c33(CONS(proper(x0), ok(0)), PROPER(x0))
PROPER(cons(x0, nil)) → c33(CONS(proper(x0), ok(nil)), PROPER(x0))
PROPER(cons(0, x1)) → c33(CONS(ok(0), proper(x1)), PROPER(x1))
PROPER(cons(nil, x1)) → c33(CONS(ok(nil), proper(x1)), PROPER(x1))
PROPER(s(from(z0))) → c34(S(from(proper(z0))), PROPER(from(z0)))
PROPER(s(cons(z0, z1))) → c34(S(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(s(s(z0))) → c34(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(head(z0))) → c34(S(head(proper(z0))), PROPER(head(z0)))
PROPER(s(2nd(z0))) → c34(S(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(s(take(z0, z1))) → c34(S(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(s(sel(z0, z1))) → c34(S(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(s(0)) → c34(S(ok(0)))
PROPER(s(nil)) → c34(S(ok(nil)))
PROPER(head(from(z0))) → c35(HEAD(from(proper(z0))), PROPER(from(z0)))
PROPER(head(cons(z0, z1))) → c35(HEAD(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(head(s(z0))) → c35(HEAD(s(proper(z0))), PROPER(s(z0)))
PROPER(head(head(z0))) → c35(HEAD(head(proper(z0))), PROPER(head(z0)))
PROPER(head(2nd(z0))) → c35(HEAD(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(head(take(z0, z1))) → c35(HEAD(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(head(sel(z0, z1))) → c35(HEAD(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(head(0)) → c35(HEAD(ok(0)))
PROPER(head(nil)) → c35(HEAD(ok(nil)))
PROPER(2nd(from(z0))) → c36(2ND(from(proper(z0))), PROPER(from(z0)))
PROPER(2nd(cons(z0, z1))) → c36(2ND(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
PROPER(2nd(s(z0))) → c36(2ND(s(proper(z0))), PROPER(s(z0)))
PROPER(2nd(head(z0))) → c36(2ND(head(proper(z0))), PROPER(head(z0)))
PROPER(2nd(2nd(z0))) → c36(2ND(2nd(proper(z0))), PROPER(2nd(z0)))
PROPER(2nd(take(z0, z1))) → c36(2ND(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
PROPER(2nd(sel(z0, z1))) → c36(2ND(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
PROPER(2nd(0)) → c36(2ND(ok(0)))
PROPER(2nd(nil)) → c36(2ND(ok(nil)))
PROPER(take(x0, from(z0))) → c37(TAKE(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(take(x0, cons(z0, z1))) → c37(TAKE(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(take(x0, s(z0))) → c37(TAKE(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(take(x0, head(z0))) → c37(TAKE(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(take(x0, 2nd(z0))) → c37(TAKE(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(take(x0, take(z0, z1))) → c37(TAKE(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(take(x0, sel(z0, z1))) → c37(TAKE(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(take(from(z0), x1)) → c37(TAKE(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(take(cons(z0, z1), x1)) → c37(TAKE(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(take(s(z0), x1)) → c37(TAKE(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(take(head(z0), x1)) → c37(TAKE(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(take(2nd(z0), x1)) → c37(TAKE(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(take(take(z0, z1), x1)) → c37(TAKE(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(take(sel(z0, z1), x1)) → c37(TAKE(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(take(x0, 0)) → c37(TAKE(proper(x0), ok(0)), PROPER(x0))
PROPER(take(x0, nil)) → c37(TAKE(proper(x0), ok(nil)), PROPER(x0))
PROPER(take(0, x1)) → c37(TAKE(ok(0), proper(x1)), PROPER(x1))
PROPER(take(nil, x1)) → c37(TAKE(ok(nil), proper(x1)), PROPER(x1))
PROPER(sel(x0, from(z0))) → c40(SEL(proper(x0), from(proper(z0))), PROPER(x0), PROPER(from(z0)))
PROPER(sel(x0, cons(z0, z1))) → c40(SEL(proper(x0), cons(proper(z0), proper(z1))), PROPER(x0), PROPER(cons(z0, z1)))
PROPER(sel(x0, s(z0))) → c40(SEL(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(sel(x0, head(z0))) → c40(SEL(proper(x0), head(proper(z0))), PROPER(x0), PROPER(head(z0)))
PROPER(sel(x0, 2nd(z0))) → c40(SEL(proper(x0), 2nd(proper(z0))), PROPER(x0), PROPER(2nd(z0)))
PROPER(sel(x0, take(z0, z1))) → c40(SEL(proper(x0), take(proper(z0), proper(z1))), PROPER(x0), PROPER(take(z0, z1)))
PROPER(sel(x0, sel(z0, z1))) → c40(SEL(proper(x0), sel(proper(z0), proper(z1))), PROPER(x0), PROPER(sel(z0, z1)))
PROPER(sel(from(z0), x1)) → c40(SEL(from(proper(z0)), proper(x1)), PROPER(from(z0)), PROPER(x1))
PROPER(sel(cons(z0, z1), x1)) → c40(SEL(cons(proper(z0), proper(z1)), proper(x1)), PROPER(cons(z0, z1)), PROPER(x1))
PROPER(sel(s(z0), x1)) → c40(SEL(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(sel(head(z0), x1)) → c40(SEL(head(proper(z0)), proper(x1)), PROPER(head(z0)), PROPER(x1))
PROPER(sel(2nd(z0), x1)) → c40(SEL(2nd(proper(z0)), proper(x1)), PROPER(2nd(z0)), PROPER(x1))
PROPER(sel(take(z0, z1), x1)) → c40(SEL(take(proper(z0), proper(z1)), proper(x1)), PROPER(take(z0, z1)), PROPER(x1))
PROPER(sel(sel(z0, z1), x1)) → c40(SEL(sel(proper(z0), proper(z1)), proper(x1)), PROPER(sel(z0, z1)), PROPER(x1))
PROPER(sel(x0, 0)) → c40(SEL(proper(x0), ok(0)), PROPER(x0))
PROPER(sel(x0, nil)) → c40(SEL(proper(x0), ok(nil)), PROPER(x0))
PROPER(sel(0, x1)) → c40(SEL(ok(0), proper(x1)), PROPER(x1))
PROPER(sel(nil, x1)) → c40(SEL(ok(nil), proper(x1)), PROPER(x1))
TOP(mark(from(z0))) → c41(TOP(from(proper(z0))), PROPER(from(z0)))
TOP(mark(cons(z0, z1))) → c41(TOP(cons(proper(z0), proper(z1))), PROPER(cons(z0, z1)))
TOP(mark(s(z0))) → c41(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(head(z0))) → c41(TOP(head(proper(z0))), PROPER(head(z0)))
TOP(mark(2nd(z0))) → c41(TOP(2nd(proper(z0))), PROPER(2nd(z0)))
TOP(mark(take(z0, z1))) → c41(TOP(take(proper(z0), proper(z1))), PROPER(take(z0, z1)))
TOP(mark(sel(z0, z1))) → c41(TOP(sel(proper(z0), proper(z1))), PROPER(sel(z0, z1)))
TOP(ok(from(z0))) → c42(TOP(mark(cons(z0, from(s(z0))))), ACTIVE(from(z0)))
TOP(ok(head(cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(head(cons(z0, z1))))
TOP(ok(2nd(cons(z0, z1)))) → c42(TOP(mark(head(z1))), ACTIVE(2nd(cons(z0, z1))))
TOP(ok(take(0, z0))) → c42(TOP(mark(nil)), ACTIVE(take(0, z0)))
TOP(ok(take(s(z0), cons(z1, z2)))) → c42(TOP(mark(cons(z1, take(z0, z2)))), ACTIVE(take(s(z0), cons(z1, z2))))
TOP(ok(sel(0, cons(z0, z1)))) → c42(TOP(mark(z0)), ACTIVE(sel(0, cons(z0, z1))))
TOP(ok(sel(s(z0), cons(z1, z2)))) → c42(TOP(mark(sel(z0, z2))), ACTIVE(sel(s(z0), cons(z1, z2))))
TOP(ok(from(z0))) → c42(TOP(from(active(z0))), ACTIVE(from(z0)))
TOP(ok(cons(z0, z1))) → c42(TOP(cons(active(z0), z1)), ACTIVE(cons(z0, z1)))
TOP(ok(s(z0))) → c42(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(head(z0))) → c42(TOP(head(active(z0))), ACTIVE(head(z0)))
TOP(ok(2nd(z0))) → c42(TOP(2nd(active(z0))), ACTIVE(2nd(z0)))
TOP(ok(take(z0, z1))) → c42(TOP(take(active(z0), z1)), ACTIVE(take(z0, z1)))
TOP(ok(take(z0, z1))) → c42(TOP(take(z0, active(z1))), ACTIVE(take(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(active(z0), z1)), ACTIVE(sel(z0, z1)))
TOP(ok(sel(z0, z1))) → c42(TOP(sel(z0, active(z1))), ACTIVE(sel(z0, z1)))
(60) Obligation:
Complexity Dependency Tuples Problem
Rules:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
K tuples:none
Defined Rule Symbols:
active, head, cons, take, sel, from, s, 2nd, proper
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(61) CdtUsableRulesProof (EQUIVALENT transformation)
The following rules are not usable and were removed:
active(from(z0)) → mark(cons(z0, from(s(z0))))
active(head(cons(z0, z1))) → mark(z0)
active(2nd(cons(z0, z1))) → mark(head(z1))
active(take(0, z0)) → mark(nil)
active(take(s(z0), cons(z1, z2))) → mark(cons(z1, take(z0, z2)))
active(sel(0, cons(z0, z1))) → mark(z0)
active(sel(s(z0), cons(z1, z2))) → mark(sel(z0, z2))
active(from(z0)) → from(active(z0))
active(cons(z0, z1)) → cons(active(z0), z1)
active(s(z0)) → s(active(z0))
active(head(z0)) → head(active(z0))
active(2nd(z0)) → 2nd(active(z0))
active(take(z0, z1)) → take(active(z0), z1)
active(take(z0, z1)) → take(z0, active(z1))
active(sel(z0, z1)) → sel(active(z0), z1)
active(sel(z0, z1)) → sel(z0, active(z1))
head(mark(z0)) → mark(head(z0))
head(ok(z0)) → ok(head(z0))
cons(ok(z0), ok(z1)) → ok(cons(z0, z1))
cons(mark(z0), z1) → mark(cons(z0, z1))
take(z0, mark(z1)) → mark(take(z0, z1))
take(mark(z0), z1) → mark(take(z0, z1))
take(ok(z0), ok(z1)) → ok(take(z0, z1))
sel(z0, mark(z1)) → mark(sel(z0, z1))
sel(mark(z0), z1) → mark(sel(z0, z1))
sel(ok(z0), ok(z1)) → ok(sel(z0, z1))
from(mark(z0)) → mark(from(z0))
from(ok(z0)) → ok(from(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
2nd(mark(z0)) → mark(2nd(z0))
2nd(ok(z0)) → ok(2nd(z0))
proper(from(z0)) → from(proper(z0))
proper(cons(z0, z1)) → cons(proper(z0), proper(z1))
proper(s(z0)) → s(proper(z0))
proper(head(z0)) → head(proper(z0))
proper(2nd(z0)) → 2nd(proper(z0))
proper(take(z0, z1)) → take(proper(z0), proper(z1))
proper(0) → ok(0)
proper(nil) → ok(nil)
proper(sel(z0, z1)) → sel(proper(z0), proper(z1))
(62) Obligation:
Complexity Dependency Tuples Problem
Rules:none
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
K tuples:none
Defined Rule Symbols:none
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(63) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)
Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(ok(z0)) → c21(S(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :
POL(2ND(x1)) = [2]x1
POL(CONS(x1, x2)) = [2]x1 + [2]x2
POL(FROM(x1)) = 0
POL(HEAD(x1)) = 0
POL(S(x1)) = [2]x1
POL(SEL(x1, x2)) = 0
POL(TAKE(x1, x2)) = [2]x2
POL(c16(x1)) = x1
POL(c17(x1)) = x1
POL(c18(x1)) = x1
POL(c19(x1)) = x1
POL(c20(x1)) = x1
POL(c21(x1)) = x1
POL(c22(x1)) = x1
POL(c23(x1)) = x1
POL(c24(x1)) = x1
POL(c25(x1)) = x1
POL(c26(x1)) = x1
POL(c27(x1)) = x1
POL(c28(x1)) = x1
POL(c29(x1)) = x1
POL(c30(x1)) = x1
POL(c31(x1)) = x1
POL(mark(x1)) = x1
POL(ok(x1)) = [5] + x1
(64) Obligation:
Complexity Dependency Tuples Problem
Rules:none
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
K tuples:
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(ok(z0)) → c21(S(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
Defined Rule Symbols:none
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(65) CdtRuleRemovalProof (UPPER BOUND(ADD(n^3)) transformation)
Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :
POL(2ND(x1)) = 0
POL(CONS(x1, x2)) = 0
POL(FROM(x1)) = x13
POL(HEAD(x1)) = 0
POL(S(x1)) = 0
POL(SEL(x1, x2)) = 0
POL(TAKE(x1, x2)) = x1 + x22 + x12·x2
POL(c16(x1)) = x1
POL(c17(x1)) = x1
POL(c18(x1)) = x1
POL(c19(x1)) = x1
POL(c20(x1)) = x1
POL(c21(x1)) = x1
POL(c22(x1)) = x1
POL(c23(x1)) = x1
POL(c24(x1)) = x1
POL(c25(x1)) = x1
POL(c26(x1)) = x1
POL(c27(x1)) = x1
POL(c28(x1)) = x1
POL(c29(x1)) = x1
POL(c30(x1)) = x1
POL(c31(x1)) = x1
POL(mark(x1)) = [1] + x1
POL(ok(x1)) = [1] + x1
(66) Obligation:
Complexity Dependency Tuples Problem
Rules:none
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:
CONS(mark(z0), z1) → c18(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
K tuples:
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(ok(z0)) → c21(S(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
Defined Rule Symbols:none
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(67) CdtRuleRemovalProof (UPPER BOUND(ADD(n^3)) transformation)
Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.
S(mark(z0)) → c20(S(z0))
2ND(mark(z0)) → c24(2ND(z0))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :
POL(2ND(x1)) = x12
POL(CONS(x1, x2)) = 0
POL(FROM(x1)) = 0
POL(HEAD(x1)) = 0
POL(S(x1)) = x1
POL(SEL(x1, x2)) = x22 + x12 + x13 + x12·x2 + x1·x22
POL(TAKE(x1, x2)) = x1 + x2 + x1·x2
POL(c16(x1)) = x1
POL(c17(x1)) = x1
POL(c18(x1)) = x1
POL(c19(x1)) = x1
POL(c20(x1)) = x1
POL(c21(x1)) = x1
POL(c22(x1)) = x1
POL(c23(x1)) = x1
POL(c24(x1)) = x1
POL(c25(x1)) = x1
POL(c26(x1)) = x1
POL(c27(x1)) = x1
POL(c28(x1)) = x1
POL(c29(x1)) = x1
POL(c30(x1)) = x1
POL(c31(x1)) = x1
POL(mark(x1)) = [1] + x1
POL(ok(x1)) = [1] + x1
(68) Obligation:
Complexity Dependency Tuples Problem
Rules:none
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:
CONS(mark(z0), z1) → c18(CONS(z0, z1))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
K tuples:
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(ok(z0)) → c21(S(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
S(mark(z0)) → c20(S(z0))
2ND(mark(z0)) → c24(2ND(z0))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
Defined Rule Symbols:none
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(69) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)
Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.
CONS(mark(z0), z1) → c18(CONS(z0, z1))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
We considered the (Usable) Rules:none
And the Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :
POL(2ND(x1)) = [3]x1
POL(CONS(x1, x2)) = [2]x1 + [5]x2
POL(FROM(x1)) = 0
POL(HEAD(x1)) = x1
POL(S(x1)) = [3]x1
POL(SEL(x1, x2)) = [4]x2
POL(TAKE(x1, x2)) = [4]x2
POL(c16(x1)) = x1
POL(c17(x1)) = x1
POL(c18(x1)) = x1
POL(c19(x1)) = x1
POL(c20(x1)) = x1
POL(c21(x1)) = x1
POL(c22(x1)) = x1
POL(c23(x1)) = x1
POL(c24(x1)) = x1
POL(c25(x1)) = x1
POL(c26(x1)) = x1
POL(c27(x1)) = x1
POL(c28(x1)) = x1
POL(c29(x1)) = x1
POL(c30(x1)) = x1
POL(c31(x1)) = x1
POL(mark(x1)) = [1] + x1
POL(ok(x1)) = [2] + x1
(70) Obligation:
Complexity Dependency Tuples Problem
Rules:none
Tuples:
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(mark(z0)) → c20(S(z0))
S(ok(z0)) → c21(S(z0))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
2ND(mark(z0)) → c24(2ND(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
S tuples:none
K tuples:
CONS(ok(z0), ok(z1)) → c19(CONS(z0, z1))
S(ok(z0)) → c21(S(z0))
2ND(ok(z0)) → c25(2ND(z0))
TAKE(ok(z0), ok(z1)) → c28(TAKE(z0, z1))
FROM(mark(z0)) → c16(FROM(z0))
FROM(ok(z0)) → c17(FROM(z0))
TAKE(mark(z0), z1) → c26(TAKE(z0, z1))
TAKE(z0, mark(z1)) → c27(TAKE(z0, z1))
S(mark(z0)) → c20(S(z0))
2ND(mark(z0)) → c24(2ND(z0))
SEL(mark(z0), z1) → c29(SEL(z0, z1))
SEL(z0, mark(z1)) → c30(SEL(z0, z1))
SEL(ok(z0), ok(z1)) → c31(SEL(z0, z1))
CONS(mark(z0), z1) → c18(CONS(z0, z1))
HEAD(mark(z0)) → c22(HEAD(z0))
HEAD(ok(z0)) → c23(HEAD(z0))
Defined Rule Symbols:none
Defined Pair Symbols:
FROM, CONS, S, HEAD, 2ND, TAKE, SEL
Compound Symbols:
c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c28, c29, c30, c31
(71) SIsEmptyProof (BOTH BOUNDS(ID, ID) transformation)
The set S is empty
(72) BOUNDS(1, 1)