Certification Problem
Input (TPDB TRS_Standard/SK90/2.41)
The rewrite relation of the following TRS is considered.
norm(nil) |
→ |
0 |
(1) |
norm(g(x,y)) |
→ |
s(norm(x)) |
(2) |
f(x,nil) |
→ |
g(nil,x) |
(3) |
f(x,g(y,z)) |
→ |
g(f(x,y),z) |
(4) |
rem(nil,y) |
→ |
nil |
(5) |
rem(g(x,y),0) |
→ |
g(x,y) |
(6) |
rem(g(x,y),s(z)) |
→ |
rem(x,z) |
(7) |
Property / Task
Prove or disprove termination.Answer / Result
Yes.Proof (by AProVE @ termCOMP 2023)
1 Rule Removal
Using the
Knuth Bendix order with w0 = 1 and the following precedence and weight functions
prec(nil) |
= |
0 |
|
weight(nil) |
= |
2 |
|
|
|
prec(0) |
= |
5 |
|
weight(0) |
= |
4 |
|
|
|
prec(norm) |
= |
6 |
|
weight(norm) |
= |
2 |
|
|
|
prec(s) |
= |
2 |
|
weight(s) |
= |
1 |
|
|
|
prec(g) |
= |
1 |
|
weight(g) |
= |
0 |
|
|
|
prec(f) |
= |
4 |
|
weight(f) |
= |
0 |
|
|
|
prec(rem) |
= |
3 |
|
weight(rem) |
= |
0 |
|
|
|
all of the following rules can be deleted.
norm(nil) |
→ |
0 |
(1) |
norm(g(x,y)) |
→ |
s(norm(x)) |
(2) |
f(x,nil) |
→ |
g(nil,x) |
(3) |
f(x,g(y,z)) |
→ |
g(f(x,y),z) |
(4) |
rem(nil,y) |
→ |
nil |
(5) |
rem(g(x,y),0) |
→ |
g(x,y) |
(6) |
rem(g(x,y),s(z)) |
→ |
rem(x,z) |
(7) |
1.1 R is empty
There are no rules in the TRS. Hence, it is terminating.