YES We show the termination of the TRS R: cond(true(),x) -> cond(odd(x),p(p(p(x)))) odd(|0|()) -> false() odd(s(|0|())) -> true() odd(s(s(x))) -> odd(x) p(|0|()) -> |0|() p(s(x)) -> x -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: cond#(true(),x) -> cond#(odd(x),p(p(p(x)))) p2: cond#(true(),x) -> odd#(x) p3: cond#(true(),x) -> p#(p(p(x))) p4: cond#(true(),x) -> p#(p(x)) p5: cond#(true(),x) -> p#(x) p6: odd#(s(s(x))) -> odd#(x) and R consists of: r1: cond(true(),x) -> cond(odd(x),p(p(p(x)))) r2: odd(|0|()) -> false() r3: odd(s(|0|())) -> true() r4: odd(s(s(x))) -> odd(x) r5: p(|0|()) -> |0|() r6: p(s(x)) -> x The estimated dependency graph contains the following SCCs: {p1} {p6} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: cond#(true(),x) -> cond#(odd(x),p(p(p(x)))) and R consists of: r1: cond(true(),x) -> cond(odd(x),p(p(p(x)))) r2: odd(|0|()) -> false() r3: odd(s(|0|())) -> true() r4: odd(s(s(x))) -> odd(x) r5: p(|0|()) -> |0|() r6: p(s(x)) -> x The set of usable rules consists of r2, r3, r4, r5, r6 Take the reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: max/plus interpretations on natural numbers: cond#_A(x1,x2) = max{22, x1, x2 + 17} true_A = 23 odd_A(x1) = max{16, x1 + 15} p_A(x1) = max{4, x1 - 1} |0|_A = 3 false_A = 17 s_A(x1) = max{9, x1 + 6} precedence: cond# = true = odd = p = |0| = false = s partial status: pi(cond#) = [1, 2] pi(true) = [] pi(odd) = [1] pi(p) = [] pi(|0|) = [] pi(false) = [] pi(s) = [1] 2. weighted path order base order: max/plus interpretations on natural numbers: cond#_A(x1,x2) = max{x1 - 7, x2 + 31} true_A = 34 odd_A(x1) = max{37, x1 + 8} p_A(x1) = 32 |0|_A = 33 false_A = 38 s_A(x1) = max{27, x1 + 9} precedence: cond# = true = odd = p = |0| = false = s partial status: pi(cond#) = [2] pi(true) = [] pi(odd) = [1] pi(p) = [] pi(|0|) = [] pi(false) = [] pi(s) = [1] 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: odd#(s(s(x))) -> odd#(x) and R consists of: r1: cond(true(),x) -> cond(odd(x),p(p(p(x)))) r2: odd(|0|()) -> false() r3: odd(s(|0|())) -> true() r4: odd(s(s(x))) -> odd(x) r5: p(|0|()) -> |0|() r6: p(s(x)) -> x The set of usable rules consists of (no rules) Take the monotone reduction pair: lexicographic combination of reduction pairs: 1. weighted path order base order: max/plus interpretations on natural numbers: odd#_A(x1) = max{2, x1 + 1} s_A(x1) = max{1, x1} precedence: odd# = s partial status: pi(odd#) = [1] pi(s) = [1] 2. weighted path order base order: max/plus interpretations on natural numbers: odd#_A(x1) = x1 + 1 s_A(x1) = x1 precedence: odd# = s partial status: pi(odd#) = [1] pi(s) = [1] The next rules are strictly ordered: p1 We remove them from the problem. Then no dependency pair remains.