Certification Problem

Input (TPDB TRS_Standard/Secret_06_TRS/sumList)

The rewrite relation of the following TRS is considered.

isEmpty(cons(x,xs)) false (1)
isEmpty(nil) true (2)
isZero(0) true (3)
isZero(s(x)) false (4)
head(cons(x,xs)) x (5)
tail(cons(x,xs)) xs (6)
tail(nil) nil (7)
p(s(s(x))) s(p(s(x))) (8)
p(s(0)) 0 (9)
p(0) 0 (10)
inc(s(x)) s(inc(x)) (11)
inc(0) s(0) (12)
sumList(xs,y) if(isEmpty(xs),isZero(head(xs)),y,tail(xs),cons(p(head(xs)),tail(xs)),inc(y)) (13)
if(true,b,y,xs,ys,x) y (14)
if(false,true,y,xs,ys,x) sumList(xs,y) (15)
if(false,false,y,xs,ys,x) sumList(ys,x) (16)
sum(xs) sumList(xs,0) (17)

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.
p#(s(s(x))) p#(s(x)) (18)
inc#(s(x)) inc#(x) (19)
sumList#(xs,y) inc#(y) (20)
sumList#(xs,y) p#(head(xs)) (21)
sumList#(xs,y) tail#(xs) (22)
sumList#(xs,y) head#(xs) (23)
sumList#(xs,y) isZero#(head(xs)) (24)
sumList#(xs,y) isEmpty#(xs) (25)
sumList#(xs,y) if#(isEmpty(xs),isZero(head(xs)),y,tail(xs),cons(p(head(xs)),tail(xs)),inc(y)) (26)
if#(false,true,y,xs,ys,x) sumList#(xs,y) (27)
if#(false,false,y,xs,ys,x) sumList#(ys,x) (28)
sum#(xs) sumList#(xs,0) (29)

1.1 Dependency Graph Processor

The dependency pairs are split into 3 components.