YES We show the termination of the TRS R: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) sum(cons(|0|(),x),y) -> sum(x,y) sum(nil(),y) -> y weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) weight(cons(n,nil())) -> n -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: sum#(cons(s(n),x),cons(m,y)) -> sum#(cons(n,x),cons(s(m),y)) p2: sum#(cons(|0|(),x),y) -> sum#(x,y) p3: weight#(cons(n,cons(m,x))) -> weight#(sum(cons(n,cons(m,x)),cons(|0|(),x))) p4: weight#(cons(n,cons(m,x))) -> sum#(cons(n,cons(m,x)),cons(|0|(),x)) and R consists of: r1: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) r2: sum(cons(|0|(),x),y) -> sum(x,y) r3: sum(nil(),y) -> y r4: weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) r5: weight(cons(n,nil())) -> n The estimated dependency graph contains the following SCCs: {p3} {p1, p2} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: weight#(cons(n,cons(m,x))) -> weight#(sum(cons(n,cons(m,x)),cons(|0|(),x))) and R consists of: r1: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) r2: sum(cons(|0|(),x),y) -> sum(x,y) r3: sum(nil(),y) -> y r4: weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) r5: weight(cons(n,nil())) -> n The set of usable rules consists of r1, r2, r3 Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: weight#_A(x1) = x1 + (2,2) cons_A(x1,x2) = ((1,0),(0,0)) x2 + (1,1) sum_A(x1,x2) = x2 |0|_A() = (5,2) nil_A() = (1,1) s_A(x1) = ((1,0),(1,1)) x1 precedence: weight# = cons = sum = |0| = nil = s partial status: pi(weight#) = [] pi(cons) = [] pi(sum) = [] pi(|0|) = [] pi(nil) = [] pi(s) = [] 2. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: weight#_A(x1) = (2,1) cons_A(x1,x2) = (3,3) sum_A(x1,x2) = x2 + (4,4) |0|_A() = (1,2) nil_A() = (1,1) s_A(x1) = ((0,0),(1,0)) x1 + (1,6) precedence: weight# = cons = sum = |0| = s > nil partial status: pi(weight#) = [] pi(cons) = [] pi(sum) = [] pi(|0|) = [] pi(nil) = [] pi(s) = [] The next rules are strictly ordered: p1 We remove them from the problem. Then no dependency pair remains. -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: sum#(cons(s(n),x),cons(m,y)) -> sum#(cons(n,x),cons(s(m),y)) p2: sum#(cons(|0|(),x),y) -> sum#(x,y) and R consists of: r1: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) r2: sum(cons(|0|(),x),y) -> sum(x,y) r3: sum(nil(),y) -> y r4: weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) r5: weight(cons(n,nil())) -> n The set of usable rules consists of (no rules) Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: sum#_A(x1,x2) = ((1,0),(1,0)) x1 + ((0,0),(1,0)) x2 + (2,1) cons_A(x1,x2) = ((1,0),(0,0)) x1 + x2 + (4,14) s_A(x1) = ((1,0),(1,0)) x1 + (3,13) |0|_A() = (1,2) precedence: s = |0| > sum# = cons partial status: pi(sum#) = [] pi(cons) = [2] pi(s) = [] pi(|0|) = [] 2. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: sum#_A(x1,x2) = (0,0) cons_A(x1,x2) = (2,1) s_A(x1) = (1,0) |0|_A() = (1,1) precedence: |0| > cons = s > sum# partial status: pi(sum#) = [] pi(cons) = [] pi(s) = [] pi(|0|) = [] The next rules are strictly ordered: p1 We remove them from the problem. -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: sum#(cons(|0|(),x),y) -> sum#(x,y) and R consists of: r1: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) r2: sum(cons(|0|(),x),y) -> sum(x,y) r3: sum(nil(),y) -> y r4: weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) r5: weight(cons(n,nil())) -> n The estimated dependency graph contains the following SCCs: {p1} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: sum#(cons(|0|(),x),y) -> sum#(x,y) and R consists of: r1: sum(cons(s(n),x),cons(m,y)) -> sum(cons(n,x),cons(s(m),y)) r2: sum(cons(|0|(),x),y) -> sum(x,y) r3: sum(nil(),y) -> y r4: weight(cons(n,cons(m,x))) -> weight(sum(cons(n,cons(m,x)),cons(|0|(),x))) r5: weight(cons(n,nil())) -> n The set of usable rules consists of (no rules) Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: sum#_A(x1,x2) = ((1,0),(0,0)) x1 + x2 + (2,2) cons_A(x1,x2) = ((1,0),(0,0)) x2 + (1,0) |0|_A() = (1,1) precedence: cons > sum# = |0| partial status: pi(sum#) = [2] pi(cons) = [] pi(|0|) = [] 2. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: sum#_A(x1,x2) = x2 cons_A(x1,x2) = (1,1) |0|_A() = (1,1) precedence: sum# = |0| > cons partial status: pi(sum#) = [2] pi(cons) = [] pi(|0|) = [] The next rules are strictly ordered: p1 We remove them from the problem. Then no dependency pair remains.