Certification Problem

Input (TPDB TRS_Standard/Transformed_CSR_04/Ex2_Luc03b_Z)

The rewrite relation of the following TRS is considered.

fst(0,Z) nil (1)
fst(s(X),cons(Y,Z)) cons(Y,n__fst(activate(X),activate(Z))) (2)
from(X) cons(X,n__from(s(X))) (3)
add(0,X) X (4)
add(s(X),Y) s(n__add(activate(X),Y)) (5)
len(nil) 0 (6)
len(cons(X,Z)) s(n__len(activate(Z))) (7)
fst(X1,X2) n__fst(X1,X2) (8)
from(X) n__from(X) (9)
add(X1,X2) n__add(X1,X2) (10)
len(X) n__len(X) (11)
activate(n__fst(X1,X2)) fst(X1,X2) (12)
activate(n__from(X)) from(X) (13)
activate(n__add(X1,X2)) add(X1,X2) (14)
activate(n__len(X)) len(X) (15)
activate(X) X (16)

Property / Task

Prove or disprove termination.

Answer / Result

Yes.

Proof (by ttt2 @ termCOMP 2023)

1 Rule Removal

Using the linear polynomial interpretation over the naturals
[cons(x1, x2)] = 8 · x1 + 1 · x2 + 1
[n__from(x1)] = 17 · x1 + 8
[fst(x1, x2)] = 2 · x1 + 4 · x2 + 1
[s(x1)] = 1 · x1 + 0
[activate(x1)] = 2 · x1 + 0
[n__add(x1, x2)] = 4 · x1 + 1 · x2 + 0
[0] = 19
[from(x1)] = 26 · x1 + 9
[n__len(x1)] = 2 · x1 + 0
[len(x1)] = 4 · x1 + 0
[add(x1, x2)] = 8 · x1 + 1 · x2 + 0
[n__fst(x1, x2)] = 1 · x1 + 2 · x2 + 1
[nil] = 28
all of the following rules can be deleted.
fst(0,Z) nil (1)
fst(s(X),cons(Y,Z)) cons(Y,n__fst(activate(X),activate(Z))) (2)
add(0,X) X (4)
len(nil) 0 (6)
len(cons(X,Z)) s(n__len(activate(Z))) (7)
from(X) n__from(X) (9)
activate(n__fst(X1,X2)) fst(X1,X2) (12)
activate(n__from(X)) from(X) (13)

1.1 Rule Removal

Using the linear polynomial interpretation over the naturals
[cons(x1, x2)] = 1 · x1 + 1 · x2 + 4
[n__from(x1)] = 2 · x1 + 0
[fst(x1, x2)] = 8 · x1 + 4 · x2 + 16
[s(x1)] = 1 · x1 + 7
[activate(x1)] = 3 · x1 + 1
[n__add(x1, x2)] = 8 · x1 + 1 · x2 + 0
[from(x1)] = 3 · x1 + 19
[n__len(x1)] = 23 · x1 + 7
[len(x1)] = 24 · x1 + 8
[add(x1, x2)] = 24 · x1 + 1 · x2 + 0
[n__fst(x1, x2)] = 2 · x1 + 2 · x2 + 0
all of the following rules can be deleted.
from(X) cons(X,n__from(s(X))) (3)
add(s(X),Y) s(n__add(activate(X),Y)) (5)
fst(X1,X2) n__fst(X1,X2) (8)
len(X) n__len(X) (11)
activate(n__add(X1,X2)) add(X1,X2) (14)
activate(n__len(X)) len(X) (15)
activate(X) X (16)

1.1.1 Rule Removal

Using the Weighted Path Order with the following precedence and status
prec(n__add) = 0 status(n__add) = [2, 1] list-extension(n__add) = Lex
prec(add) = 0 status(add) = [2, 1] list-extension(add) = Lex
and the following Max-polynomial interpretation
[n__add(x1, x2)] = max(0, 0 + 1 · x1, 4 + 1 · x2)
[add(x1, x2)] = max(1, 1 + 1 · x1, 5 + 1 · x2)
all of the following rules can be deleted.
add(X1,X2) n__add(X1,X2) (10)

1.1.1.1 R is empty

There are no rules in the TRS. Hence, it is terminating.