(0) Obligation:

Runtime Complexity TRS:
The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
active(p(X)) → p(active(X))
active(s(X)) → s(active(X))
active(leq(X1, X2)) → leq(active(X1), X2)
active(leq(X1, X2)) → leq(X1, active(X2))
active(if(X1, X2, X3)) → if(active(X1), X2, X3)
active(diff(X1, X2)) → diff(active(X1), X2)
active(diff(X1, X2)) → diff(X1, active(X2))
p(mark(X)) → mark(p(X))
s(mark(X)) → mark(s(X))
leq(mark(X1), X2) → mark(leq(X1, X2))
leq(X1, mark(X2)) → mark(leq(X1, X2))
if(mark(X1), X2, X3) → mark(if(X1, X2, X3))
diff(mark(X1), X2) → mark(diff(X1, X2))
diff(X1, mark(X2)) → mark(diff(X1, X2))
proper(p(X)) → p(proper(X))
proper(0) → ok(0)
proper(s(X)) → s(proper(X))
proper(leq(X1, X2)) → leq(proper(X1), proper(X2))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(X1, X2, X3)) → if(proper(X1), proper(X2), proper(X3))
proper(diff(X1, X2)) → diff(proper(X1), proper(X2))
p(ok(X)) → ok(p(X))
s(ok(X)) → ok(s(X))
leq(ok(X1), ok(X2)) → ok(leq(X1, X2))
if(ok(X1), ok(X2), ok(X3)) → ok(if(X1, X2, X3))
diff(ok(X1), ok(X2)) → ok(diff(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(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
p(mark(z0)) → mark(p(z0))
p(ok(z0)) → ok(p(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:

ACTIVE(p(0)) → c
ACTIVE(p(s(z0))) → c1
ACTIVE(leq(0, z0)) → c2
ACTIVE(leq(s(z0), 0)) → c3
ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(if(true, z0, z1)) → c5
ACTIVE(if(false, z0, z1)) → c6
ACTIVE(diff(z0, z1)) → c7(IF(leq(z0, z1), 0, s(diff(p(z0), z1))), LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(0) → c28
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(true) → c31
PROPER(false) → c32
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
S tuples:

ACTIVE(p(0)) → c
ACTIVE(p(s(z0))) → c1
ACTIVE(leq(0, z0)) → c2
ACTIVE(leq(s(z0), 0)) → c3
ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(if(true, z0, z1)) → c5
ACTIVE(if(false, z0, z1)) → c6
ACTIVE(diff(z0, z1)) → c7(IF(leq(z0, z1), 0, s(diff(p(z0), z1))), LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(0) → c28
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(true) → c31
PROPER(false) → c32
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
K tuples:none
Defined Rule Symbols:

active, p, s, leq, if, diff, proper, top

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, 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

(3) CdtLeafRemovalProof (BOTH BOUNDS(ID, ID) transformation)

Removed 9 trailing nodes:

PROPER(false) → c32
ACTIVE(p(0)) → c
PROPER(true) → c31
PROPER(0) → c28
ACTIVE(leq(0, z0)) → c2
ACTIVE(p(s(z0))) → c1
ACTIVE(leq(s(z0), 0)) → c3
ACTIVE(if(false, z0, z1)) → c6
ACTIVE(if(true, z0, z1)) → c5

(4) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
p(mark(z0)) → mark(p(z0))
p(ok(z0)) → ok(p(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c7(IF(leq(z0, z1), 0, s(diff(p(z0), z1))), LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c7(IF(leq(z0, z1), 0, s(diff(p(z0), z1))), LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
K tuples:none
Defined Rule Symbols:

active, p, s, leq, if, diff, proper, top

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36

(5) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 1 trailing tuple parts

(6) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
p(mark(z0)) → mark(p(z0))
p(ok(z0)) → ok(p(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c7(LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c7(LEQ(z0, z1), S(diff(p(z0), z1)), DIFF(p(z0), z1), P(z0))
K tuples:none
Defined Rule Symbols:

active, p, s, leq, if, diff, proper, top

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c7

(7) CdtGraphSplitRhsProof (BOTH BOUNDS(ID, ID) transformation)

Split RHS of tuples not part of any SCC

(8) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
p(mark(z0)) → mark(p(z0))
p(ok(z0)) → ok(p(z0))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
top(mark(z0)) → top(proper(z0))
top(ok(z0)) → top(active(z0))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
K tuples:none
Defined Rule Symbols:

active, p, s, leq, if, diff, proper, top

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c

(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(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c

(11) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace ACTIVE(p(z0)) → c8(P(active(z0)), ACTIVE(z0)) by

ACTIVE(p(p(0))) → c8(P(mark(0)), ACTIVE(p(0)))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))

(12) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(0))) → c8(P(mark(0)), ACTIVE(p(0)))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(0))) → c8(P(mark(0)), ACTIVE(p(0)))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8

(13) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 1 trailing tuple parts

(14) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8, c8

(15) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace ACTIVE(s(z0)) → c9(S(active(z0)), ACTIVE(z0)) by

ACTIVE(s(p(0))) → c9(S(mark(0)), ACTIVE(p(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))

(16) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(0))) → c9(S(mark(0)), ACTIVE(p(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(0))) → c9(S(mark(0)), ACTIVE(p(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8, c8, c9

(17) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 1 trailing tuple parts

(18) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8, c8, c9, c9

(19) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace ACTIVE(if(z0, z1, z2)) → c12(IF(active(z0), z1, z2), ACTIVE(z0)) by

ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2), ACTIVE(p(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(if(true, z0, z1)))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2), ACTIVE(if(false, z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))

(20) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2), ACTIVE(p(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(if(true, z0, z1)))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2), ACTIVE(if(false, z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)), ACTIVE(if(true, z0, z1)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)), ACTIVE(if(false, z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2), ACTIVE(p(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(if(true, z0, z1)))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2), ACTIVE(if(false, z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12

(21) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 7 trailing tuple parts

(22) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c27, c29, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12

(23) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace PROPER(p(z0)) → c27(P(proper(z0)), PROPER(z0)) by

PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(0)) → c27(P(ok(0)), PROPER(0))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(true)) → c27(P(ok(true)), PROPER(true))
PROPER(p(false)) → c27(P(ok(false)), PROPER(false))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))

(24) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(0)) → c27(P(ok(0)), PROPER(0))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(true)) → c27(P(ok(true)), PROPER(true))
PROPER(p(false)) → c27(P(ok(false)), PROPER(false))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(0)) → c27(P(ok(0)), PROPER(0))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(true)) → c27(P(ok(true)), PROPER(true))
PROPER(p(false)) → c27(P(ok(false)), PROPER(false))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c29, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27

(25) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 3 trailing tuple parts

(26) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c29, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27

(27) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace PROPER(s(z0)) → c29(S(proper(z0)), PROPER(z0)) by

PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(0)) → c29(S(ok(0)), PROPER(0))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(true)) → c29(S(ok(true)), PROPER(true))
PROPER(s(false)) → c29(S(ok(false)), PROPER(false))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))

(28) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(0)) → c29(S(ok(0)), PROPER(0))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(true)) → c29(S(ok(true)), PROPER(true))
PROPER(s(false)) → c29(S(ok(false)), PROPER(false))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(0)) → c29(S(ok(0)), PROPER(0))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(true)) → c29(S(ok(true)), PROPER(true))
PROPER(s(false)) → c29(S(ok(false)), PROPER(false))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29

(29) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 3 trailing tuple parts

(30) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c30, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29

(31) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace PROPER(leq(z0, z1)) → c30(LEQ(proper(z0), proper(z1)), PROPER(z0), PROPER(z1)) by

PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))

(32) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30

(33) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 6 trailing tuple parts

(34) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c33, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30

(35) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace PROPER(if(z0, z1, z2)) → c33(IF(proper(z0), proper(z1), proper(z2)), PROPER(z0), PROPER(z1), PROPER(z2)) by

PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1), PROPER(0))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1), PROPER(true))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1), PROPER(false))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(0), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(true), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(false), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(0), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(true), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(false), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))

(36) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1), PROPER(0))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1), PROPER(true))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1), PROPER(false))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(0), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(true), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(false), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(0), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(true), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(false), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1), PROPER(0))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1), PROPER(true))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1), PROPER(false))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(0), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(true), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(false), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(0), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(true), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(false), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33

(37) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 9 trailing tuple parts

(38) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c34, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33

(39) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace PROPER(diff(z0, z1)) → c34(DIFF(proper(z0), proper(z1)), PROPER(z0), PROPER(z1)) by

PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))

(40) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0), PROPER(0))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0), PROPER(true))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0), PROPER(false))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(0), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(true), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(false), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, TOP, PROPER

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34

(41) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 6 trailing tuple parts

(42) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, TOP, PROPER

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c35, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34

(43) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace TOP(mark(z0)) → c35(TOP(proper(z0)), PROPER(z0)) by

TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(0)) → c35(TOP(ok(0)), PROPER(0))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(true)) → c35(TOP(ok(true)), PROPER(true))
TOP(mark(false)) → c35(TOP(ok(false)), PROPER(false))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))

(44) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(0)) → c35(TOP(ok(0)), PROPER(0))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(true)) → c35(TOP(ok(true)), PROPER(true))
TOP(mark(false)) → c35(TOP(ok(false)), PROPER(false))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(0)) → c35(TOP(ok(0)), PROPER(0))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(true)) → c35(TOP(ok(true)), PROPER(true))
TOP(mark(false)) → c35(TOP(ok(false)), PROPER(false))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, TOP, PROPER

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34, c35

(45) CdtRhsSimplificationProcessorProof (BOTH BOUNDS(ID, ID) transformation)

Removed 3 trailing tuple parts

(46) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, TOP, PROPER

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34, c35, c35

(47) 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)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
We considered the (Usable) Rules:

p(mark(z0)) → mark(p(z0))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
p(ok(z0)) → ok(p(z0))
active(diff(z0, z1)) → diff(active(z0), z1)
active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(z0, z1)) → leq(active(z0), z1)
active(if(true, z0, z1)) → mark(z0)
leq(z0, mark(z1)) → mark(leq(z0, z1))
diff(mark(z0), z1) → mark(diff(z0, z1))
leq(mark(z0), z1) → mark(leq(z0, z1))
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(diff(z0, z1)) → diff(z0, active(z1))
s(ok(z0)) → ok(s(z0))
active(if(false, z0, z1)) → mark(z1)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
s(mark(z0)) → mark(s(z0))
active(s(z0)) → s(active(z0))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
And the Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(0) = 0   
POL(ACTIVE(x1)) = 0   
POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = 0   
POL(LEQ(x1, x2)) = 0   
POL(P(x1)) = 0   
POL(PROPER(x1)) = 0   
POL(S(x1)) = 0   
POL(TOP(x1)) = [4]x1   
POL(active(x1)) = x1   
POL(c(x1)) = x1   
POL(c10(x1, x2)) = x1 + x2   
POL(c11(x1, x2)) = x1 + x2   
POL(c12(x1)) = x1   
POL(c12(x1, x2)) = x1 + x2   
POL(c13(x1, x2)) = x1 + x2   
POL(c14(x1, x2)) = x1 + x2   
POL(c15(x1)) = x1   
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(c27(x1, x2)) = x1 + x2   
POL(c29(x1)) = x1   
POL(c29(x1, x2)) = x1 + x2   
POL(c30(x1, x2)) = x1 + x2   
POL(c30(x1, x2, x3)) = x1 + x2 + x3   
POL(c33(x1, x2, x3)) = x1 + x2 + x3   
POL(c33(x1, x2, x3, x4)) = x1 + x2 + x3 + x4   
POL(c34(x1, x2)) = x1 + x2   
POL(c34(x1, x2, x3)) = x1 + x2 + x3   
POL(c35(x1)) = x1   
POL(c35(x1, x2)) = x1 + x2   
POL(c36(x1, x2)) = x1 + x2   
POL(c4(x1)) = x1   
POL(c8(x1)) = x1   
POL(c8(x1, x2)) = x1 + x2   
POL(c9(x1)) = x1   
POL(c9(x1, x2)) = x1 + x2   
POL(diff(x1, x2)) = [1]   
POL(false) = 0   
POL(if(x1, x2, x3)) = [1]   
POL(leq(x1, x2)) = [1]   
POL(mark(x1)) = [1]   
POL(ok(x1)) = x1   
POL(p(x1)) = [1]   
POL(proper(x1)) = 0   
POL(s(x1)) = [1]   
POL(true) = 0   

(48) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
K tuples:

TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, TOP, PROPER

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c36, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34, c35, c35

(49) CdtNarrowingProof (BOTH BOUNDS(ID, ID) transformation)

Use narrowing to replace TOP(ok(z0)) → c36(TOP(active(z0)), ACTIVE(z0)) by

TOP(ok(p(0))) → c36(TOP(mark(0)), ACTIVE(p(0)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))

(50) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
TOP(ok(p(0))) → c36(TOP(mark(0)), ACTIVE(p(0)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(ok(p(0))) → c36(TOP(mark(0)), ACTIVE(p(0)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
K tuples:

TOP(mark(0)) → c35(TOP(ok(0)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(false)) → c35(TOP(ok(false)))
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34, c35, c35, c36

(51) CdtLeafRemovalProof (BOTH BOUNDS(ID, ID) transformation)

Removed 4 trailing nodes:

TOP(mark(false)) → c35(TOP(ok(false)))
TOP(mark(true)) → c35(TOP(ok(true)))
TOP(mark(0)) → c35(TOP(ok(0)))
TOP(ok(p(0))) → c36(TOP(mark(0)), ACTIVE(p(0)))

(52) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
S tuples:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

ACTIVE, P, S, LEQ, IF, DIFF, PROPER, TOP

Compound Symbols:

c4, c10, c11, c13, c14, c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26, c, c8, c8, c9, c9, c12, c12, c27, c27, c29, c29, c30, c30, c33, c33, c34, c34, c35, c36

(53) CdtUnreachableProof (EQUIVALENT transformation)

The following tuples could be removed as they are not reachable from basic start terms:

ACTIVE(leq(s(z0), s(z1))) → c4(LEQ(z0, z1))
ACTIVE(leq(z0, z1)) → c10(LEQ(active(z0), z1), ACTIVE(z0))
ACTIVE(leq(z0, z1)) → c11(LEQ(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c13(DIFF(active(z0), z1), ACTIVE(z0))
ACTIVE(diff(z0, z1)) → c14(DIFF(z0, active(z1)), ACTIVE(z1))
ACTIVE(diff(z0, z1)) → c(LEQ(z0, z1))
ACTIVE(diff(z0, z1)) → c(S(diff(p(z0), z1)))
ACTIVE(diff(z0, z1)) → c(DIFF(p(z0), z1))
ACTIVE(diff(z0, z1)) → c(P(z0))
ACTIVE(p(p(s(z0)))) → c8(P(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(p(leq(0, z0))) → c8(P(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(p(leq(s(z0), 0))) → c8(P(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(p(leq(s(z0), s(z1)))) → c8(P(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(p(diff(z0, z1))) → c8(P(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(z0))) → c8(P(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(p(s(z0))) → c8(P(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(p(leq(z0, z1))) → c8(P(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(p(if(z0, z1, z2))) → c8(P(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(p(diff(z0, z1))) → c8(P(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(p(p(0))) → c8(P(mark(0)))
ACTIVE(s(p(s(z0)))) → c9(S(mark(z0)), ACTIVE(p(s(z0))))
ACTIVE(s(leq(0, z0))) → c9(S(mark(true)), ACTIVE(leq(0, z0)))
ACTIVE(s(leq(s(z0), 0))) → c9(S(mark(false)), ACTIVE(leq(s(z0), 0)))
ACTIVE(s(leq(s(z0), s(z1)))) → c9(S(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(s(diff(z0, z1))) → c9(S(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(z0))) → c9(S(p(active(z0))), ACTIVE(p(z0)))
ACTIVE(s(s(z0))) → c9(S(s(active(z0))), ACTIVE(s(z0)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
ACTIVE(s(leq(z0, z1))) → c9(S(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
ACTIVE(s(if(z0, z1, z2))) → c9(S(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
ACTIVE(s(diff(z0, z1))) → c9(S(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))
ACTIVE(s(p(0))) → c9(S(mark(0)))
ACTIVE(if(p(s(z0)), x1, x2)) → c12(IF(mark(z0), x1, x2), ACTIVE(p(s(z0))))
ACTIVE(if(leq(0, z0), x1, x2)) → c12(IF(mark(true), x1, x2), ACTIVE(leq(0, z0)))
ACTIVE(if(leq(s(z0), 0), x1, x2)) → c12(IF(mark(false), x1, x2), ACTIVE(leq(s(z0), 0)))
ACTIVE(if(leq(s(z0), s(z1)), x1, x2)) → c12(IF(mark(leq(z0, z1)), x1, x2), ACTIVE(leq(s(z0), s(z1))))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1)))), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(p(z0), x1, x2)) → c12(IF(p(active(z0)), x1, x2), ACTIVE(p(z0)))
ACTIVE(if(s(z0), x1, x2)) → c12(IF(s(active(z0)), x1, x2), ACTIVE(s(z0)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(active(z0), z1), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(leq(z0, z1), x1, x2)) → c12(IF(leq(z0, active(z1)), x1, x2), ACTIVE(leq(z0, z1)))
ACTIVE(if(if(z0, z1, z2), x1, x2)) → c12(IF(if(active(z0), z1, z2), x1, x2), ACTIVE(if(z0, z1, z2)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(active(z0), z1), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(if(diff(z0, z1), x1, x2)) → c12(IF(diff(z0, active(z1)), x1, x2), ACTIVE(diff(z0, z1)))
ACTIVE(p(if(true, z0, z1))) → c8(P(mark(z0)))
ACTIVE(p(if(false, z0, z1))) → c8(P(mark(z1)))
ACTIVE(s(if(true, z0, z1))) → c9(S(mark(z0)))
ACTIVE(s(if(false, z0, z1))) → c9(S(mark(z1)))
ACTIVE(if(p(0), x1, x2)) → c12(IF(mark(0), x1, x2))
ACTIVE(if(if(true, z0, z1), x1, x2)) → c12(IF(mark(z0), x1, x2))
ACTIVE(if(if(false, z0, z1), x1, x2)) → c12(IF(mark(z1), x1, x2))
PROPER(p(p(z0))) → c27(P(p(proper(z0))), PROPER(p(z0)))
PROPER(p(s(z0))) → c27(P(s(proper(z0))), PROPER(s(z0)))
PROPER(p(leq(z0, z1))) → c27(P(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(p(if(z0, z1, z2))) → c27(P(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(p(diff(z0, z1))) → c27(P(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(p(0)) → c27(P(ok(0)))
PROPER(p(true)) → c27(P(ok(true)))
PROPER(p(false)) → c27(P(ok(false)))
PROPER(s(p(z0))) → c29(S(p(proper(z0))), PROPER(p(z0)))
PROPER(s(s(z0))) → c29(S(s(proper(z0))), PROPER(s(z0)))
PROPER(s(leq(z0, z1))) → c29(S(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
PROPER(s(if(z0, z1, z2))) → c29(S(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
PROPER(s(diff(z0, z1))) → c29(S(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
PROPER(s(0)) → c29(S(ok(0)))
PROPER(s(true)) → c29(S(ok(true)))
PROPER(s(false)) → c29(S(ok(false)))
PROPER(leq(x0, p(z0))) → c30(LEQ(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(leq(x0, s(z0))) → c30(LEQ(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(leq(x0, leq(z0, z1))) → c30(LEQ(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(leq(x0, if(z0, z1, z2))) → c30(LEQ(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(leq(x0, diff(z0, z1))) → c30(LEQ(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(leq(p(z0), x1)) → c30(LEQ(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(leq(s(z0), x1)) → c30(LEQ(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(leq(leq(z0, z1), x1)) → c30(LEQ(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(leq(if(z0, z1, z2), x1)) → c30(LEQ(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(leq(diff(z0, z1), x1)) → c30(LEQ(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(leq(x0, 0)) → c30(LEQ(proper(x0), ok(0)), PROPER(x0))
PROPER(leq(x0, true)) → c30(LEQ(proper(x0), ok(true)), PROPER(x0))
PROPER(leq(x0, false)) → c30(LEQ(proper(x0), ok(false)), PROPER(x0))
PROPER(leq(0, x1)) → c30(LEQ(ok(0), proper(x1)), PROPER(x1))
PROPER(leq(true, x1)) → c30(LEQ(ok(true), proper(x1)), PROPER(x1))
PROPER(leq(false, x1)) → c30(LEQ(ok(false), proper(x1)), PROPER(x1))
PROPER(if(x0, x1, p(z0))) → c33(IF(proper(x0), proper(x1), p(proper(z0))), PROPER(x0), PROPER(x1), PROPER(p(z0)))
PROPER(if(x0, x1, s(z0))) → c33(IF(proper(x0), proper(x1), s(proper(z0))), PROPER(x0), PROPER(x1), PROPER(s(z0)))
PROPER(if(x0, x1, leq(z0, z1))) → c33(IF(proper(x0), proper(x1), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(leq(z0, z1)))
PROPER(if(x0, x1, if(z0, z1, z2))) → c33(IF(proper(x0), proper(x1), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(x1), PROPER(if(z0, z1, z2)))
PROPER(if(x0, x1, diff(z0, z1))) → c33(IF(proper(x0), proper(x1), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(x1), PROPER(diff(z0, z1)))
PROPER(if(x0, p(z0), x2)) → c33(IF(proper(x0), p(proper(z0)), proper(x2)), PROPER(x0), PROPER(p(z0)), PROPER(x2))
PROPER(if(x0, s(z0), x2)) → c33(IF(proper(x0), s(proper(z0)), proper(x2)), PROPER(x0), PROPER(s(z0)), PROPER(x2))
PROPER(if(x0, leq(z0, z1), x2)) → c33(IF(proper(x0), leq(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(leq(z0, z1)), PROPER(x2))
PROPER(if(x0, if(z0, z1, z2), x2)) → c33(IF(proper(x0), if(proper(z0), proper(z1), proper(z2)), proper(x2)), PROPER(x0), PROPER(if(z0, z1, z2)), PROPER(x2))
PROPER(if(x0, diff(z0, z1), x2)) → c33(IF(proper(x0), diff(proper(z0), proper(z1)), proper(x2)), PROPER(x0), PROPER(diff(z0, z1)), PROPER(x2))
PROPER(if(p(z0), x1, x2)) → c33(IF(p(proper(z0)), proper(x1), proper(x2)), PROPER(p(z0)), PROPER(x1), PROPER(x2))
PROPER(if(s(z0), x1, x2)) → c33(IF(s(proper(z0)), proper(x1), proper(x2)), PROPER(s(z0)), PROPER(x1), PROPER(x2))
PROPER(if(leq(z0, z1), x1, x2)) → c33(IF(leq(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(leq(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(if(z0, z1, z2), x1, x2)) → c33(IF(if(proper(z0), proper(z1), proper(z2)), proper(x1), proper(x2)), PROPER(if(z0, z1, z2)), PROPER(x1), PROPER(x2))
PROPER(if(diff(z0, z1), x1, x2)) → c33(IF(diff(proper(z0), proper(z1)), proper(x1), proper(x2)), PROPER(diff(z0, z1)), PROPER(x1), PROPER(x2))
PROPER(if(x0, x1, 0)) → c33(IF(proper(x0), proper(x1), ok(0)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, true)) → c33(IF(proper(x0), proper(x1), ok(true)), PROPER(x0), PROPER(x1))
PROPER(if(x0, x1, false)) → c33(IF(proper(x0), proper(x1), ok(false)), PROPER(x0), PROPER(x1))
PROPER(if(x0, 0, x2)) → c33(IF(proper(x0), ok(0), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, true, x2)) → c33(IF(proper(x0), ok(true), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(x0, false, x2)) → c33(IF(proper(x0), ok(false), proper(x2)), PROPER(x0), PROPER(x2))
PROPER(if(0, x1, x2)) → c33(IF(ok(0), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(true, x1, x2)) → c33(IF(ok(true), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(if(false, x1, x2)) → c33(IF(ok(false), proper(x1), proper(x2)), PROPER(x1), PROPER(x2))
PROPER(diff(x0, p(z0))) → c34(DIFF(proper(x0), p(proper(z0))), PROPER(x0), PROPER(p(z0)))
PROPER(diff(x0, s(z0))) → c34(DIFF(proper(x0), s(proper(z0))), PROPER(x0), PROPER(s(z0)))
PROPER(diff(x0, leq(z0, z1))) → c34(DIFF(proper(x0), leq(proper(z0), proper(z1))), PROPER(x0), PROPER(leq(z0, z1)))
PROPER(diff(x0, if(z0, z1, z2))) → c34(DIFF(proper(x0), if(proper(z0), proper(z1), proper(z2))), PROPER(x0), PROPER(if(z0, z1, z2)))
PROPER(diff(x0, diff(z0, z1))) → c34(DIFF(proper(x0), diff(proper(z0), proper(z1))), PROPER(x0), PROPER(diff(z0, z1)))
PROPER(diff(p(z0), x1)) → c34(DIFF(p(proper(z0)), proper(x1)), PROPER(p(z0)), PROPER(x1))
PROPER(diff(s(z0), x1)) → c34(DIFF(s(proper(z0)), proper(x1)), PROPER(s(z0)), PROPER(x1))
PROPER(diff(leq(z0, z1), x1)) → c34(DIFF(leq(proper(z0), proper(z1)), proper(x1)), PROPER(leq(z0, z1)), PROPER(x1))
PROPER(diff(if(z0, z1, z2), x1)) → c34(DIFF(if(proper(z0), proper(z1), proper(z2)), proper(x1)), PROPER(if(z0, z1, z2)), PROPER(x1))
PROPER(diff(diff(z0, z1), x1)) → c34(DIFF(diff(proper(z0), proper(z1)), proper(x1)), PROPER(diff(z0, z1)), PROPER(x1))
PROPER(diff(x0, 0)) → c34(DIFF(proper(x0), ok(0)), PROPER(x0))
PROPER(diff(x0, true)) → c34(DIFF(proper(x0), ok(true)), PROPER(x0))
PROPER(diff(x0, false)) → c34(DIFF(proper(x0), ok(false)), PROPER(x0))
PROPER(diff(0, x1)) → c34(DIFF(ok(0), proper(x1)), PROPER(x1))
PROPER(diff(true, x1)) → c34(DIFF(ok(true), proper(x1)), PROPER(x1))
PROPER(diff(false, x1)) → c34(DIFF(ok(false), proper(x1)), PROPER(x1))
TOP(mark(p(z0))) → c35(TOP(p(proper(z0))), PROPER(p(z0)))
TOP(mark(s(z0))) → c35(TOP(s(proper(z0))), PROPER(s(z0)))
TOP(mark(leq(z0, z1))) → c35(TOP(leq(proper(z0), proper(z1))), PROPER(leq(z0, z1)))
TOP(mark(if(z0, z1, z2))) → c35(TOP(if(proper(z0), proper(z1), proper(z2))), PROPER(if(z0, z1, z2)))
TOP(mark(diff(z0, z1))) → c35(TOP(diff(proper(z0), proper(z1))), PROPER(diff(z0, z1)))
TOP(ok(p(s(z0)))) → c36(TOP(mark(z0)), ACTIVE(p(s(z0))))
TOP(ok(leq(0, z0))) → c36(TOP(mark(true)), ACTIVE(leq(0, z0)))
TOP(ok(leq(s(z0), 0))) → c36(TOP(mark(false)), ACTIVE(leq(s(z0), 0)))
TOP(ok(leq(s(z0), s(z1)))) → c36(TOP(mark(leq(z0, z1))), ACTIVE(leq(s(z0), s(z1))))
TOP(ok(if(true, z0, z1))) → c36(TOP(mark(z0)), ACTIVE(if(true, z0, z1)))
TOP(ok(if(false, z0, z1))) → c36(TOP(mark(z1)), ACTIVE(if(false, z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))), ACTIVE(diff(z0, z1)))
TOP(ok(p(z0))) → c36(TOP(p(active(z0))), ACTIVE(p(z0)))
TOP(ok(s(z0))) → c36(TOP(s(active(z0))), ACTIVE(s(z0)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(active(z0), z1)), ACTIVE(leq(z0, z1)))
TOP(ok(leq(z0, z1))) → c36(TOP(leq(z0, active(z1))), ACTIVE(leq(z0, z1)))
TOP(ok(if(z0, z1, z2))) → c36(TOP(if(active(z0), z1, z2)), ACTIVE(if(z0, z1, z2)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(active(z0), z1)), ACTIVE(diff(z0, z1)))
TOP(ok(diff(z0, z1))) → c36(TOP(diff(z0, active(z1))), ACTIVE(diff(z0, z1)))

(54) Obligation:

Complexity Dependency Tuples Problem
Rules:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:none
Defined Rule Symbols:

active, s, diff, p, leq, if, proper

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(55) CdtUsableRulesProof (EQUIVALENT transformation)

The following rules are not usable and were removed:

active(p(0)) → mark(0)
active(p(s(z0))) → mark(z0)
active(leq(0, z0)) → mark(true)
active(leq(s(z0), 0)) → mark(false)
active(leq(s(z0), s(z1))) → mark(leq(z0, z1))
active(if(true, z0, z1)) → mark(z0)
active(if(false, z0, z1)) → mark(z1)
active(diff(z0, z1)) → mark(if(leq(z0, z1), 0, s(diff(p(z0), z1))))
active(p(z0)) → p(active(z0))
active(s(z0)) → s(active(z0))
active(leq(z0, z1)) → leq(active(z0), z1)
active(leq(z0, z1)) → leq(z0, active(z1))
active(if(z0, z1, z2)) → if(active(z0), z1, z2)
active(diff(z0, z1)) → diff(active(z0), z1)
active(diff(z0, z1)) → diff(z0, active(z1))
s(mark(z0)) → mark(s(z0))
s(ok(z0)) → ok(s(z0))
diff(mark(z0), z1) → mark(diff(z0, z1))
diff(ok(z0), ok(z1)) → ok(diff(z0, z1))
diff(z0, mark(z1)) → mark(diff(z0, z1))
p(ok(z0)) → ok(p(z0))
p(mark(z0)) → mark(p(z0))
leq(mark(z0), z1) → mark(leq(z0, z1))
leq(ok(z0), ok(z1)) → ok(leq(z0, z1))
leq(z0, mark(z1)) → mark(leq(z0, z1))
if(mark(z0), z1, z2) → mark(if(z0, z1, z2))
if(ok(z0), ok(z1), ok(z2)) → ok(if(z0, z1, z2))
proper(p(z0)) → p(proper(z0))
proper(0) → ok(0)
proper(s(z0)) → s(proper(z0))
proper(leq(z0, z1)) → leq(proper(z0), proper(z1))
proper(true) → ok(true)
proper(false) → ok(false)
proper(if(z0, z1, z2)) → if(proper(z0), proper(z1), proper(z2))
proper(diff(z0, z1)) → diff(proper(z0), proper(z1))

(56) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:none
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(57) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)

Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = [4]x1 + [2]x2   
POL(IF(x1, x2, x3)) = [2]x1 + [2]x2   
POL(LEQ(x1, x2)) = 0   
POL(P(x1)) = x1   
POL(S(x1)) = 0   
POL(c15(x1)) = x1   
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(mark(x1)) = [1] + x1   
POL(ok(x1)) = x1   

(58) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(59) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)

Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.

S(mark(z0)) → c17(S(z0))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = 0   
POL(LEQ(x1, x2)) = 0   
POL(P(x1)) = 0   
POL(S(x1)) = [2]x1   
POL(c15(x1)) = x1   
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(mark(x1)) = [2] + x1   
POL(ok(x1)) = x1   

(60) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(61) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)

Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.

IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = x2 + x3   
POL(LEQ(x1, x2)) = 0   
POL(P(x1)) = 0   
POL(S(x1)) = 0   
POL(c15(x1)) = x1   
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(mark(x1)) = [3]   
POL(ok(x1)) = [4] + x1   

(62) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(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.

LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = [2]x1 + [5]x2 + [4]x3   
POL(LEQ(x1, x2)) = [4]x2   
POL(P(x1)) = 0   
POL(S(x1)) = 0   
POL(c15(x1)) = x1   
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(mark(x1)) = [2] + x1   
POL(ok(x1)) = x1   

(64) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(65) CdtRuleRemovalProof (UPPER BOUND(ADD(n^2)) transformation)

Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.

P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = [3]x1 + [3]x2 + x22 + [2]x1·x2 + [2]x12   
POL(IF(x1, x2, x3)) = [2]x3   
POL(LEQ(x1, x2)) = 0   
POL(P(x1)) = [2]x12   
POL(S(x1)) = [2]x1 + x12   
POL(c15(x1)) = x1   
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(mark(x1)) = x1   
POL(ok(x1)) = [2] + x1   

(66) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(67) CdtRuleRemovalProof (UPPER BOUND(ADD(n^1)) transformation)

Found a reduction pair which oriented the following tuples strictly. Hence they can be removed from S.

LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = [5]x1 + [4]x2   
POL(IF(x1, x2, x3)) = [4]x1 + [3]x3   
POL(LEQ(x1, x2)) = x1   
POL(P(x1)) = [2]x1   
POL(S(x1)) = [4]x1   
POL(c15(x1)) = x1   
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(mark(x1)) = [1] + x1   
POL(ok(x1)) = x1   

(68) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:

LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(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.

LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
We considered the (Usable) Rules:none
And the Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
The order we found is given by the following interpretation:
Polynomial interpretation :

POL(DIFF(x1, x2)) = [3]x1   
POL(IF(x1, x2, x3)) = [2]x2   
POL(LEQ(x1, x2)) = [4]x1   
POL(P(x1)) = 0   
POL(S(x1)) = [4]x1   
POL(c15(x1)) = x1   
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(mark(x1)) = x1   
POL(ok(x1)) = [1] + x1   

(70) Obligation:

Complexity Dependency Tuples Problem
Rules:none
Tuples:

P(mark(z0)) → c15(P(z0))
P(ok(z0)) → c16(P(z0))
S(mark(z0)) → c17(S(z0))
S(ok(z0)) → c18(S(z0))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
S tuples:none
K tuples:

P(mark(z0)) → c15(P(z0))
IF(mark(z0), z1, z2) → c22(IF(z0, z1, z2))
DIFF(mark(z0), z1) → c24(DIFF(z0, z1))
DIFF(z0, mark(z1)) → c25(DIFF(z0, z1))
S(mark(z0)) → c17(S(z0))
IF(ok(z0), ok(z1), ok(z2)) → c23(IF(z0, z1, z2))
LEQ(z0, mark(z1)) → c20(LEQ(z0, z1))
P(ok(z0)) → c16(P(z0))
S(ok(z0)) → c18(S(z0))
DIFF(ok(z0), ok(z1)) → c26(DIFF(z0, z1))
LEQ(mark(z0), z1) → c19(LEQ(z0, z1))
LEQ(ok(z0), ok(z1)) → c21(LEQ(z0, z1))
Defined Rule Symbols:none

Defined Pair Symbols:

P, S, LEQ, IF, DIFF

Compound Symbols:

c15, c16, c17, c18, c19, c20, c21, c22, c23, c24, c25, c26

(71) SIsEmptyProof (BOTH BOUNDS(ID, ID) transformation)

The set S is empty

(72) BOUNDS(1, 1)