YES We show the termination of the TRS R: minus(|0|()) -> |0|() +(x,|0|()) -> x +(|0|(),y) -> y +(minus(|1|()),|1|()) -> |0|() minus(minus(x)) -> x +(x,minus(y)) -> minus(+(minus(x),y)) +(x,+(y,z)) -> +(+(x,y),z) +(minus(+(x,|1|())),|1|()) -> minus(x) -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: +#(x,minus(y)) -> minus#(+(minus(x),y)) p2: +#(x,minus(y)) -> +#(minus(x),y) p3: +#(x,minus(y)) -> minus#(x) p4: +#(x,+(y,z)) -> +#(+(x,y),z) p5: +#(x,+(y,z)) -> +#(x,y) p6: +#(minus(+(x,|1|())),|1|()) -> minus#(x) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The estimated dependency graph contains the following SCCs: {p2, p4, p5} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: +#(x,minus(y)) -> +#(minus(x),y) p2: +#(x,+(y,z)) -> +#(x,y) p3: +#(x,+(y,z)) -> +#(+(x,y),z) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The set of usable rules consists of r1, r2, r3, r4, r5, r6, r7, r8 Take the reduction pair: weighted path order base order: max/plus interpretations on natural numbers: +#_A(x1,x2) = max{x1 + 3, x2 + 7} minus_A(x1) = x1 +_A(x1,x2) = max{x1, x2 + 3} |0|_A = 3 |1|_A = 4 precedence: minus = + > |1| > +# = |0| partial status: pi(+#) = [2] pi(minus) = [] pi(+) = [] pi(|0|) = [] pi(|1|) = [] The next rules are strictly ordered: p3 We remove them from the problem. -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: +#(x,minus(y)) -> +#(minus(x),y) p2: +#(x,+(y,z)) -> +#(x,y) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The estimated dependency graph contains the following SCCs: {p1, p2} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: +#(x,minus(y)) -> +#(minus(x),y) p2: +#(x,+(y,z)) -> +#(x,y) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The set of usable rules consists of r1, r5 Take the reduction pair: weighted path order base order: max/plus interpretations on natural numbers: +#_A(x1,x2) = max{x1 + 2, x2 + 2} minus_A(x1) = max{1, x1} +_A(x1,x2) = max{x1, x2} |0|_A = 2 precedence: +# = + > minus = |0| partial status: pi(+#) = [2] pi(minus) = [1] pi(+) = [1, 2] 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: +#(x,+(y,z)) -> +#(x,y) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The estimated dependency graph contains the following SCCs: {p1} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: +#(x,+(y,z)) -> +#(x,y) and R consists of: r1: minus(|0|()) -> |0|() r2: +(x,|0|()) -> x r3: +(|0|(),y) -> y r4: +(minus(|1|()),|1|()) -> |0|() r5: minus(minus(x)) -> x r6: +(x,minus(y)) -> minus(+(minus(x),y)) r7: +(x,+(y,z)) -> +(+(x,y),z) r8: +(minus(+(x,|1|())),|1|()) -> minus(x) The set of usable rules consists of (no rules) Take the reduction pair: weighted path order base order: max/plus interpretations on natural numbers: +#_A(x1,x2) = max{x1 + 1, x2 + 1} +_A(x1,x2) = max{x1, x2} precedence: +# = + partial status: pi(+#) = [2] pi(+) = [1, 2] The next rules are strictly ordered: p1 We remove them from the problem. Then no dependency pair remains.