YES We show the termination of the TRS R: O(|0|()) -> |0|() +(|0|(),x) -> x +(x,|0|()) -> x +(O(x),O(y)) -> O(+(x,y)) +(O(x),I(y)) -> I(+(x,y)) +(I(x),O(y)) -> I(+(x,y)) +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) *(|0|(),x) -> |0|() *(x,|0|()) -> |0|() *(O(x),y) -> O(*(x,y)) *(I(x),y) -> +(O(*(x,y)),y) -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: +#(O(x),O(y)) -> O#(+(x,y)) p2: +#(O(x),O(y)) -> +#(x,y) p3: +#(O(x),I(y)) -> +#(x,y) p4: +#(I(x),O(y)) -> +#(x,y) p5: +#(I(x),I(y)) -> O#(+(+(x,y),I(|0|()))) p6: +#(I(x),I(y)) -> +#(+(x,y),I(|0|())) p7: +#(I(x),I(y)) -> +#(x,y) p8: *#(O(x),y) -> O#(*(x,y)) p9: *#(O(x),y) -> *#(x,y) p10: *#(I(x),y) -> +#(O(*(x,y)),y) p11: *#(I(x),y) -> O#(*(x,y)) p12: *#(I(x),y) -> *#(x,y) and R consists of: r1: O(|0|()) -> |0|() r2: +(|0|(),x) -> x r3: +(x,|0|()) -> x r4: +(O(x),O(y)) -> O(+(x,y)) r5: +(O(x),I(y)) -> I(+(x,y)) r6: +(I(x),O(y)) -> I(+(x,y)) r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) r8: *(|0|(),x) -> |0|() r9: *(x,|0|()) -> |0|() r10: *(O(x),y) -> O(*(x,y)) r11: *(I(x),y) -> +(O(*(x,y)),y) The estimated dependency graph contains the following SCCs: {p9, p12} {p2, p3, p4, p6, p7} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: *#(I(x),y) -> *#(x,y) p2: *#(O(x),y) -> *#(x,y) and R consists of: r1: O(|0|()) -> |0|() r2: +(|0|(),x) -> x r3: +(x,|0|()) -> x r4: +(O(x),O(y)) -> O(+(x,y)) r5: +(O(x),I(y)) -> I(+(x,y)) r6: +(I(x),O(y)) -> I(+(x,y)) r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) r8: *(|0|(),x) -> |0|() r9: *(x,|0|()) -> |0|() r10: *(O(x),y) -> O(*(x,y)) r11: *(I(x),y) -> +(O(*(x,y)),y) The set of usable rules consists of (no rules) Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: max/plus interpretations on natural numbers: *#_A(x1,x2) = max{2, x1 + 1, x2 + 1} I_A(x1) = max{1, x1} O_A(x1) = max{1, x1} precedence: *# = I = O partial status: pi(*#) = [1] pi(I) = [1] pi(O) = [1] 2. weighted path order base order: max/plus interpretations on natural numbers: *#_A(x1,x2) = max{0, x1 - 2} I_A(x1) = max{3, x1 + 1} O_A(x1) = max{3, x1 + 1} precedence: *# = I = O partial status: pi(*#) = [] pi(I) = [1] pi(O) = [1] The next rules are strictly ordered: p1, p2 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: +#(O(x),O(y)) -> +#(x,y) p2: +#(I(x),I(y)) -> +#(x,y) p3: +#(I(x),I(y)) -> +#(+(x,y),I(|0|())) p4: +#(O(x),I(y)) -> +#(x,y) p5: +#(I(x),O(y)) -> +#(x,y) and R consists of: r1: O(|0|()) -> |0|() r2: +(|0|(),x) -> x r3: +(x,|0|()) -> x r4: +(O(x),O(y)) -> O(+(x,y)) r5: +(O(x),I(y)) -> I(+(x,y)) r6: +(I(x),O(y)) -> I(+(x,y)) r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) r8: *(|0|(),x) -> |0|() r9: *(x,|0|()) -> |0|() r10: *(O(x),y) -> O(*(x,y)) r11: *(I(x),y) -> +(O(*(x,y)),y) The set of usable rules consists of r1, r2, r3, r4, r5, r6, r7 Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: +#_A(x1,x2) = ((1,0),(0,0)) x1 + x2 + (2,2) O_A(x1) = ((1,0),(1,0)) x1 + (1,0) I_A(x1) = ((1,0),(0,0)) x1 + (9,1) +_A(x1,x2) = ((1,0),(1,1)) x1 + ((1,0),(1,0)) x2 + (2,4) |0|_A() = (5,4) precedence: +# > O = I = + > |0| partial status: pi(+#) = [2] pi(O) = [] pi(I) = [] pi(+) = [1] pi(|0|) = [] 2. weighted path order base order: matrix interpretations: carrier: N^2 order: lexicographic order interpretations: +#_A(x1,x2) = (0,0) O_A(x1) = (2,0) I_A(x1) = (1,1) +_A(x1,x2) = ((1,0),(1,1)) x1 + (3,2) |0|_A() = (3,2) precedence: O > + > +# = I = |0| partial status: pi(+#) = [] pi(O) = [] pi(I) = [] pi(+) = [1] pi(|0|) = [] The next rules are strictly ordered: p1, p2, p3, p5 We remove them from the problem. -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: +#(O(x),I(y)) -> +#(x,y) and R consists of: r1: O(|0|()) -> |0|() r2: +(|0|(),x) -> x r3: +(x,|0|()) -> x r4: +(O(x),O(y)) -> O(+(x,y)) r5: +(O(x),I(y)) -> I(+(x,y)) r6: +(I(x),O(y)) -> I(+(x,y)) r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) r8: *(|0|(),x) -> |0|() r9: *(x,|0|()) -> |0|() r10: *(O(x),y) -> O(*(x,y)) r11: *(I(x),y) -> +(O(*(x,y)),y) The estimated dependency graph contains the following SCCs: {p1} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: +#(O(x),I(y)) -> +#(x,y) and R consists of: r1: O(|0|()) -> |0|() r2: +(|0|(),x) -> x r3: +(x,|0|()) -> x r4: +(O(x),O(y)) -> O(+(x,y)) r5: +(O(x),I(y)) -> I(+(x,y)) r6: +(I(x),O(y)) -> I(+(x,y)) r7: +(I(x),I(y)) -> O(+(+(x,y),I(|0|()))) r8: *(|0|(),x) -> |0|() r9: *(x,|0|()) -> |0|() r10: *(O(x),y) -> O(*(x,y)) r11: *(I(x),y) -> +(O(*(x,y)),y) The set of usable rules consists of (no rules) Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: max/plus interpretations on natural numbers: +#_A(x1,x2) = max{0, x1 - 2, x2 - 2} O_A(x1) = max{3, x1 + 1} I_A(x1) = max{3, x1 + 1} precedence: +# = O = I partial status: pi(+#) = [] pi(O) = [1] pi(I) = [1] 2. weighted path order base order: max/plus interpretations on natural numbers: +#_A(x1,x2) = 0 O_A(x1) = max{2, x1} I_A(x1) = max{2, x1} precedence: +# = O = I partial status: pi(+#) = [] pi(O) = [1] pi(I) = [1] The next rules are strictly ordered: p1 We remove them from the problem. Then no dependency pair remains.