Certification Problem

Input (TPDB TRS_Standard/Transformed_CSR_04/Ex2_Luc02a_L)

The rewrite relation of the following TRS is considered.

terms(N) cons(recip(sqr(N))) (1)
sqr(0) 0 (2)
sqr(s(X)) s(add(sqr(X),dbl(X))) (3)
dbl(0) 0 (4)
dbl(s(X)) s(s(dbl(X))) (5)
add(0,X) X (6)
add(s(X),Y) s(add(X,Y)) (7)
first(0,X) nil (8)
first(s(X),cons(Y)) cons(Y) (9)

Property / Task

Prove or disprove termination.

Answer / Result

Yes.

Proof (by ttt2 @ termCOMP 2023)

1 Rule Removal

Using the Weighted Path Order with the following precedence and status
prec(nil) = 0 status(nil) = [] list-extension(nil) = Lex
prec(first) = 1 status(first) = [2, 1] list-extension(first) = Lex
prec(add) = 2 status(add) = [1, 2] list-extension(add) = Lex
prec(dbl) = 2 status(dbl) = [1] list-extension(dbl) = Lex
prec(s) = 0 status(s) = [1] list-extension(s) = Lex
prec(0) = 0 status(0) = [] list-extension(0) = Lex
prec(cons) = 0 status(cons) = [1] list-extension(cons) = Lex
prec(recip) = 0 status(recip) = [1] list-extension(recip) = Lex
prec(sqr) = 3 status(sqr) = [1] list-extension(sqr) = Lex
prec(terms) = 0 status(terms) = [1] list-extension(terms) = Lex
and the following Max-polynomial interpretation
[nil] = max(0)
[first(x1, x2)] = max(4, 3 + 1 · x1, 0 + 1 · x2)
[add(x1, x2)] = max(2, 0 + 1 · x1, 0 + 1 · x2)
[dbl(x1)] = max(0, 0 + 1 · x1)
[s(x1)] = 0 + 1 · x1
[0] = max(0)
[cons(x1)] = 0 + 1 · x1
[recip(x1)] = max(2, 0 + 1 · x1)
[sqr(x1)] = max(2, 0 + 1 · x1)
[terms(x1)] = max(0, 3 + 1 · x1)
all of the following rules can be deleted.
terms(N) cons(recip(sqr(N))) (1)
sqr(0) 0 (2)
sqr(s(X)) s(add(sqr(X),dbl(X))) (3)
dbl(0) 0 (4)
dbl(s(X)) s(s(dbl(X))) (5)
add(0,X) X (6)
add(s(X),Y) s(add(X,Y)) (7)
first(0,X) nil (8)
first(s(X),cons(Y)) cons(Y) (9)

1.1 R is empty

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