Certification Problem

Input (TPDB TRS_Standard/AProVE_07/thiemann17)

The rewrite relation of the following TRS is considered.

sum(cons(s(n),x),cons(m,y)) sum(cons(n,x),cons(s(m),y)) (1)
sum(cons(0,x),y) sum(x,y) (2)
sum(nil,y) y (3)
empty(nil) true (4)
empty(cons(n,x)) false (5)
tail(nil) nil (6)
tail(cons(n,x)) x (7)
head(cons(n,x)) n (8)
weight(x) if(empty(x),empty(tail(x)),x) (9)
if(true,b,x) weight_undefined_error (10)
if(false,b,x) if2(b,x) (11)
if2(true,x) head(x) (12)
if2(false,x) weight(sum(x,cons(0,tail(tail(x))))) (13)

Property / Task

Prove or disprove termination.

Answer / Result

Yes.

Proof (by ttt2 @ termCOMP 2023)

1 Dependency Pair Transformation

The following set of initial dependency pairs has been identified.
sum#(cons(s(n),x),cons(m,y)) sum#(cons(n,x),cons(s(m),y)) (14)
sum#(cons(0,x),y) sum#(x,y) (15)
weight#(x) tail#(x) (16)
weight#(x) empty#(tail(x)) (17)
weight#(x) empty#(x) (18)
weight#(x) if#(empty(x),empty(tail(x)),x) (19)
if#(false,b,x) if2#(b,x) (20)
if2#(true,x) head#(x) (21)
if2#(false,x) tail#(x) (22)
if2#(false,x) tail#(tail(x)) (23)
if2#(false,x) sum#(x,cons(0,tail(tail(x)))) (24)
if2#(false,x) weight#(sum(x,cons(0,tail(tail(x))))) (25)

1.1 Dependency Graph Processor

The dependency pairs are split into 2 components.