Certification Problem

Input (TPDB TRS_Standard/SK90/2.14)

The rewrite relation of the following TRS is considered.

double(0) 0 (1)
double(s(x)) s(s(double(x))) (2)
half(0) 0 (3)
half(s(0)) 0 (4)
half(s(s(x))) s(half(x)) (5)
-(x,0) x (6)
-(s(x),s(y)) -(x,y) (7)
if(0,y,z) y (8)
if(s(x),y,z) z (9)
half(double(x)) x (10)

Property / Task

Prove or disprove termination.

Answer / Result

Yes.

Proof (by AProVE @ termCOMP 2023)

1 Rule Removal

Using the linear polynomial interpretation over the naturals
[double(x1)] = 2 · x1
[0] = 1
[s(x1)] = 2 + 1 · x1
[half(x1)] = 2 + 2 · x1
[-(x1, x2)] = 2 · x1 + 2 · x2
[if(x1, x2, x3)] = 2 · x1 + 1 · x2 + 1 · x3
all of the following rules can be deleted.
double(0) 0 (1)
half(0) 0 (3)
half(s(0)) 0 (4)
half(s(s(x))) s(half(x)) (5)
-(x,0) x (6)
-(s(x),s(y)) -(x,y) (7)
if(0,y,z) y (8)
if(s(x),y,z) z (9)
half(double(x)) x (10)

1.1 Rule Removal

Using the
prec(double) = 1 stat(double) = lex
prec(s) = 0 stat(s) = lex

π(double) = [1]
π(s) = [1]

all of the following rules can be deleted.
double(s(x)) s(s(double(x))) (2)

1.1.1 R is empty

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