YES We show the termination of the TRS R: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) times(x,|0|()) -> |0|() times(x,s(y)) -> plus(times(x,y),x) plus(x,|0|()) -> x plus(x,s(y)) -> s(plus(x,y)) -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,plus(y,s(z))) -> plus#(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) p2: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) p3: times#(x,plus(y,s(z))) -> plus#(y,times(s(z),|0|())) p4: times#(x,plus(y,s(z))) -> times#(s(z),|0|()) p5: times#(x,plus(y,s(z))) -> times#(x,s(z)) p6: times#(x,s(y)) -> plus#(times(x,y),x) p7: times#(x,s(y)) -> times#(x,y) p8: plus#(x,s(y)) -> plus#(x,y) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The estimated dependency graph contains the following SCCs: {p2, p5, p7} {p8} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,s(y)) -> times#(x,y) p2: times#(x,plus(y,s(z))) -> times#(x,s(z)) p3: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The set of usable rules consists of r2, r4, r5 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: max/plus interpretation on natural numbers: times#_A(x1,x2) = max{12, x1 + 5} s_A(x1) = max{11, x1 - 2} plus_A(x1,x2) = max{14, x1 + 1, x2 - 8} times_A(x1,x2) = max{6, x1 - 35, x2 - 26} |0|_A = 4 base order 2: marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: times#_A(x1,x2) = max{6, x1 - 15, x2 - 5} s_A(x1) = max{11, x1} plus_A(x1,x2) = max{x1 + 7, x2 + 4} times_A(x1,x2) = max{2, x1 - 8, x2 - 15} |0|_A = 2 times#!_A(x1,x2) = max{1, x2 - 12} s!_A(x1) = 0 plus!_A(x1,x2) = max{0, x2 - 18} times!_A(x1,x2) = max{0, x1 - 32, x2 - 44} |0|!_A = 2 partial status: pi(times#) = [1] pi(s) = [] pi(plus) = [1] pi(times) = [] pi(|0|) = [] The following rules are removed: p2 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,s(y)) -> times#(x,y) p2: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The estimated dependency graph contains the following SCCs: {p1, p2} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,s(y)) -> times#(x,y) p2: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The set of usable rules consists of r2, r4, r5 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: max/plus interpretation on natural numbers: times#_A(x1,x2) = x2 + 17 s_A(x1) = max{20, x1} plus_A(x1,x2) = max{21, x1 + 7, x2 + 19} times_A(x1,x2) = max{15, x1 - 25} |0|_A = 9 base order 2: marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: times#_A(x1,x2) = max{0, x1 - 66, x2 - 55} s_A(x1) = max{16, x1} plus_A(x1,x2) = max{x1 + 36, x2 - 5} times_A(x1,x2) = max{59, x1 - 15, x2 - 40} |0|_A = 35 times#!_A(x1,x2) = max{20, x1 - 21, x2 - 34} s!_A(x1) = 4 plus!_A(x1,x2) = max{5, x1 + 3} times!_A(x1,x2) = max{1, x2 - 55} |0|!_A = 19 partial status: pi(times#) = [2] pi(s) = [1] pi(plus) = [2] pi(times) = [] pi(|0|) = [] The following rules are removed: p1 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The estimated dependency graph contains the following SCCs: {p1} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: times#(x,plus(y,s(z))) -> times#(x,plus(y,times(s(z),|0|()))) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The set of usable rules consists of r2, r4, r5 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: max/plus interpretation on natural numbers: times#_A(x1,x2) = max{10, x2} plus_A(x1,x2) = max{11, x1 + 6, x2 + 6} s_A(x1) = 9 times_A(x1,x2) = max{8, x1 - 16, x2 - 28} |0|_A = 7 base order 2: marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: times#_A(x1,x2) = max{0, x1 - 73, x2 - 30} plus_A(x1,x2) = max{29, x1 + 11, x2 - 9} s_A(x1) = max{1, x1 - 36} times_A(x1,x2) = max{8, x1 - 10, x2 - 41} |0|_A = 8 times#!_A(x1,x2) = max{1, x2 - 115} plus!_A(x1,x2) = max{2, x1 - 9, x2 - 68} s!_A(x1) = max{1, x1 - 115} times!_A(x1,x2) = max{4, x1 - 34, x2 - 24} |0|!_A = 3 partial status: pi(times#) = [2] pi(plus) = [2] pi(s) = [] pi(times) = [] pi(|0|) = [] The following rules are removed: p1 Then no dependency pair remains. -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: plus#(x,s(y)) -> plus#(x,y) and R consists of: r1: times(x,plus(y,s(z))) -> plus(times(x,plus(y,times(s(z),|0|()))),times(x,s(z))) r2: times(x,|0|()) -> |0|() r3: times(x,s(y)) -> plus(times(x,y),x) r4: plus(x,|0|()) -> x r5: plus(x,s(y)) -> s(plus(x,y)) The set of usable rules consists of (no rules) Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: max/plus interpretation on natural numbers: plus#_A(x1,x2) = x2 + 1 s_A(x1) = max{10, x1 + 2} base order 2: marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: plus#_A(x1,x2) = 0 s_A(x1) = max{10, x1 - 10} plus#!_A(x1,x2) = 0 s!_A(x1) = max{2, x1 - 13} partial status: pi(plus#) = [2] pi(s) = [1] The following rules are removed: p1 Then no dependency pair remains.