Certification Problem
Input (TPDB TRS_Innermost/Transformed_CSR_innermost_04/MYNAT_nosorts_C)
The rewrite relation of the following TRS is considered.
active(and(tt,X)) |
→ |
mark(X) |
(1) |
active(plus(N,0)) |
→ |
mark(N) |
(2) |
active(plus(N,s(M))) |
→ |
mark(s(plus(N,M))) |
(3) |
active(x(N,0)) |
→ |
mark(0) |
(4) |
active(x(N,s(M))) |
→ |
mark(plus(x(N,M),N)) |
(5) |
active(and(X1,X2)) |
→ |
and(active(X1),X2) |
(6) |
active(plus(X1,X2)) |
→ |
plus(active(X1),X2) |
(7) |
active(plus(X1,X2)) |
→ |
plus(X1,active(X2)) |
(8) |
active(s(X)) |
→ |
s(active(X)) |
(9) |
active(x(X1,X2)) |
→ |
x(active(X1),X2) |
(10) |
active(x(X1,X2)) |
→ |
x(X1,active(X2)) |
(11) |
and(mark(X1),X2) |
→ |
mark(and(X1,X2)) |
(12) |
plus(mark(X1),X2) |
→ |
mark(plus(X1,X2)) |
(13) |
plus(X1,mark(X2)) |
→ |
mark(plus(X1,X2)) |
(14) |
s(mark(X)) |
→ |
mark(s(X)) |
(15) |
x(mark(X1),X2) |
→ |
mark(x(X1,X2)) |
(16) |
x(X1,mark(X2)) |
→ |
mark(x(X1,X2)) |
(17) |
proper(and(X1,X2)) |
→ |
and(proper(X1),proper(X2)) |
(18) |
proper(tt) |
→ |
ok(tt) |
(19) |
proper(plus(X1,X2)) |
→ |
plus(proper(X1),proper(X2)) |
(20) |
proper(0) |
→ |
ok(0) |
(21) |
proper(s(X)) |
→ |
s(proper(X)) |
(22) |
proper(x(X1,X2)) |
→ |
x(proper(X1),proper(X2)) |
(23) |
and(ok(X1),ok(X2)) |
→ |
ok(and(X1,X2)) |
(24) |
plus(ok(X1),ok(X2)) |
→ |
ok(plus(X1,X2)) |
(25) |
s(ok(X)) |
→ |
ok(s(X)) |
(26) |
x(ok(X1),ok(X2)) |
→ |
ok(x(X1,X2)) |
(27) |
top(mark(X)) |
→ |
top(proper(X)) |
(28) |
top(ok(X)) |
→ |
top(active(X)) |
(29) |
The evaluation strategy is innermost.Property / Task
Prove or disprove termination.Answer / Result
Yes.Proof (by AProVE @ termCOMP 2023)
1 Rule Removal
Using the
prec(and) |
= |
0 |
|
stat(and) |
= |
mul
|
prec(tt) |
= |
1 |
|
stat(tt) |
= |
mul
|
prec(plus) |
= |
2 |
|
stat(plus) |
= |
mul
|
prec(0) |
= |
3 |
|
stat(0) |
= |
mul
|
prec(s) |
= |
0 |
|
stat(s) |
= |
mul
|
prec(x) |
= |
3 |
|
stat(x) |
= |
mul
|
prec(top) |
= |
4 |
|
stat(top) |
= |
mul
|
π(active) |
= |
1 |
π(and) |
= |
[1,2] |
π(tt) |
= |
[] |
π(mark) |
= |
1 |
π(plus) |
= |
[1,2] |
π(0) |
= |
[] |
π(s) |
= |
[1] |
π(x) |
= |
[1,2] |
π(proper) |
= |
1 |
π(ok) |
= |
1 |
π(top) |
= |
[1] |
all of the following rules can be deleted.
active(and(tt,X)) |
→ |
mark(X) |
(1) |
active(plus(N,0)) |
→ |
mark(N) |
(2) |
active(plus(N,s(M))) |
→ |
mark(s(plus(N,M))) |
(3) |
active(x(N,0)) |
→ |
mark(0) |
(4) |
active(x(N,s(M))) |
→ |
mark(plus(x(N,M),N)) |
(5) |
1.1 Rule Removal
Using the
linear polynomial interpretation over the naturals
[active(x1)] |
= |
1 · x1
|
[and(x1, x2)] |
= |
2 · x1 + 2 · x2
|
[plus(x1, x2)] |
= |
2 · x1 + 2 · x2
|
[s(x1)] |
= |
2 · x1
|
[x(x1, x2)] |
= |
2 · x1 + 2 · x2
|
[mark(x1)] |
= |
1 + 1 · x1
|
[proper(x1)] |
= |
1 · x1
|
[tt] |
= |
0 |
[ok(x1)] |
= |
1 · x1
|
[0] |
= |
0 |
[top(x1)] |
= |
2 · x1
|
all of the following rules can be deleted.
and(mark(X1),X2) |
→ |
mark(and(X1,X2)) |
(12) |
plus(mark(X1),X2) |
→ |
mark(plus(X1,X2)) |
(13) |
plus(X1,mark(X2)) |
→ |
mark(plus(X1,X2)) |
(14) |
s(mark(X)) |
→ |
mark(s(X)) |
(15) |
x(mark(X1),X2) |
→ |
mark(x(X1,X2)) |
(16) |
x(X1,mark(X2)) |
→ |
mark(x(X1,X2)) |
(17) |
top(mark(X)) |
→ |
top(proper(X)) |
(28) |
1.1.1 Rule Removal
Using the
linear polynomial interpretation over the naturals
[active(x1)] |
= |
1 + 2 · x1
|
[and(x1, x2)] |
= |
2 + 1 · x1 + 1 · x2
|
[plus(x1, x2)] |
= |
2 + 1 · x1 + 1 · x2
|
[s(x1)] |
= |
1 · x1
|
[x(x1, x2)] |
= |
2 + 1 · x1 + 1 · x2
|
[proper(x1)] |
= |
2 + 2 · x1
|
[tt] |
= |
1 |
[ok(x1)] |
= |
2 + 2 · x1
|
[0] |
= |
0 |
[top(x1)] |
= |
1 · x1
|
all of the following rules can be deleted.
active(and(X1,X2)) |
→ |
and(active(X1),X2) |
(6) |
active(plus(X1,X2)) |
→ |
plus(active(X1),X2) |
(7) |
active(plus(X1,X2)) |
→ |
plus(X1,active(X2)) |
(8) |
active(x(X1,X2)) |
→ |
x(active(X1),X2) |
(10) |
active(x(X1,X2)) |
→ |
x(X1,active(X2)) |
(11) |
top(ok(X)) |
→ |
top(active(X)) |
(29) |
1.1.1.1 Rule Removal
Using the
linear polynomial interpretation over the naturals
[active(x1)] |
= |
2 · x1
|
[s(x1)] |
= |
1 + 1 · x1
|
[proper(x1)] |
= |
2 · x1
|
[and(x1, x2)] |
= |
1 · x1 + 1 · x2
|
[tt] |
= |
1 |
[ok(x1)] |
= |
1 + 1 · x1
|
[plus(x1, x2)] |
= |
1 · x1 + 2 · x2
|
[0] |
= |
2 |
[x(x1, x2)] |
= |
1 · x1 + 1 · x2
|
all of the following rules can be deleted.
active(s(X)) |
→ |
s(active(X)) |
(9) |
proper(0) |
→ |
ok(0) |
(21) |
proper(s(X)) |
→ |
s(proper(X)) |
(22) |
and(ok(X1),ok(X2)) |
→ |
ok(and(X1,X2)) |
(24) |
plus(ok(X1),ok(X2)) |
→ |
ok(plus(X1,X2)) |
(25) |
x(ok(X1),ok(X2)) |
→ |
ok(x(X1,X2)) |
(27) |
1.1.1.1.1 Rule Removal
Using the
linear polynomial interpretation over the naturals
[proper(x1)] |
= |
2 · x1
|
[and(x1, x2)] |
= |
1 + 2 · x1 + 1 · x2
|
[tt] |
= |
2 |
[ok(x1)] |
= |
1 + 1 · x1
|
[plus(x1, x2)] |
= |
2 + 1 · x1 + 1 · x2
|
[x(x1, x2)] |
= |
1 + 2 · x1 + 2 · x2
|
[s(x1)] |
= |
2 + 2 · x1
|
all of the following rules can be deleted.
proper(and(X1,X2)) |
→ |
and(proper(X1),proper(X2)) |
(18) |
proper(tt) |
→ |
ok(tt) |
(19) |
proper(plus(X1,X2)) |
→ |
plus(proper(X1),proper(X2)) |
(20) |
proper(x(X1,X2)) |
→ |
x(proper(X1),proper(X2)) |
(23) |
s(ok(X)) |
→ |
ok(s(X)) |
(26) |
1.1.1.1.1.1 R is empty
There are no rules in the TRS. Hence, it is terminating.