MAYBE We are left with following problem, upon which TcT provides the certificate MAYBE. Strict Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE We add following dependency tuples: Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , sum^#(nil(), y) -> c_3() , empty^#(cons(n, x)) -> c_4() , empty^#(nil()) -> c_5() , tail^#(cons(n, x)) -> c_6() , tail^#(nil()) -> c_7() , head^#(cons(n, x)) -> c_8() , weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if^#(true(), b, x) -> c_10() , if^#(false(), b, x) -> c_11(if2^#(b, x)) , if2^#(true(), x) -> c_12(head^#(x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } and mark the set of starting terms. We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , sum^#(nil(), y) -> c_3() , empty^#(cons(n, x)) -> c_4() , empty^#(nil()) -> c_5() , tail^#(cons(n, x)) -> c_6() , tail^#(nil()) -> c_7() , head^#(cons(n, x)) -> c_8() , weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if^#(true(), b, x) -> c_10() , if^#(false(), b, x) -> c_11(if2^#(b, x)) , if2^#(true(), x) -> c_12(head^#(x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE We estimate the number of application of {3,4,5,6,7,8,10} by applications of Pre({3,4,5,6,7,8,10}) = {2,9,12,13}. Here rules are labeled as follows: DPs: { 1: sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , 2: sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , 3: sum^#(nil(), y) -> c_3() , 4: empty^#(cons(n, x)) -> c_4() , 5: empty^#(nil()) -> c_5() , 6: tail^#(cons(n, x)) -> c_6() , 7: tail^#(nil()) -> c_7() , 8: head^#(cons(n, x)) -> c_8() , 9: weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , 10: if^#(true(), b, x) -> c_10() , 11: if^#(false(), b, x) -> c_11(if2^#(b, x)) , 12: if2^#(true(), x) -> c_12(head^#(x)) , 13: if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if^#(false(), b, x) -> c_11(if2^#(b, x)) , if2^#(true(), x) -> c_12(head^#(x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } Weak DPs: { sum^#(nil(), y) -> c_3() , empty^#(cons(n, x)) -> c_4() , empty^#(nil()) -> c_5() , tail^#(cons(n, x)) -> c_6() , tail^#(nil()) -> c_7() , head^#(cons(n, x)) -> c_8() , if^#(true(), b, x) -> c_10() } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE We estimate the number of application of {5} by applications of Pre({5}) = {4}. Here rules are labeled as follows: DPs: { 1: sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , 2: sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , 3: weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , 4: if^#(false(), b, x) -> c_11(if2^#(b, x)) , 5: if2^#(true(), x) -> c_12(head^#(x)) , 6: if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) , 7: sum^#(nil(), y) -> c_3() , 8: empty^#(cons(n, x)) -> c_4() , 9: empty^#(nil()) -> c_5() , 10: tail^#(cons(n, x)) -> c_6() , 11: tail^#(nil()) -> c_7() , 12: head^#(cons(n, x)) -> c_8() , 13: if^#(true(), b, x) -> c_10() } We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if^#(false(), b, x) -> c_11(if2^#(b, x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } Weak DPs: { sum^#(nil(), y) -> c_3() , empty^#(cons(n, x)) -> c_4() , empty^#(nil()) -> c_5() , tail^#(cons(n, x)) -> c_6() , tail^#(nil()) -> c_7() , head^#(cons(n, x)) -> c_8() , if^#(true(), b, x) -> c_10() , if2^#(true(), x) -> c_12(head^#(x)) } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. { sum^#(nil(), y) -> c_3() , empty^#(cons(n, x)) -> c_4() , empty^#(nil()) -> c_5() , tail^#(cons(n, x)) -> c_6() , tail^#(nil()) -> c_7() , head^#(cons(n, x)) -> c_8() , if^#(true(), b, x) -> c_10() , if2^#(true(), x) -> c_12(head^#(x)) } We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if^#(false(), b, x) -> c_11(if2^#(b, x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE Due to missing edges in the dependency-graph, the right-hand sides of following rules could be simplified: { weight^#(x) -> c_9(if^#(empty(x), empty(tail(x)), x), empty^#(x), empty^#(tail(x)), tail^#(x)) , if2^#(false(), x) -> c_13(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x)))), tail^#(tail(x)), tail^#(x)) } We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , weight^#(x) -> c_3(if^#(empty(x), empty(tail(x)), x)) , if^#(false(), b, x) -> c_4(if2^#(b, x)) , if2^#(false(), x) -> c_5(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x))))) } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() , head(cons(n, x)) -> n , weight(x) -> if(empty(x), empty(tail(x)), x) , if(true(), b, x) -> weight_undefined_error() , if(false(), b, x) -> if2(b, x) , if2(true(), x) -> head(x) , if2(false(), x) -> weight(sum(x, cons(0(), tail(tail(x))))) } Obligation: innermost runtime complexity Answer: MAYBE We replace rewrite rules by usable rules: Weak Usable Rules: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() } We are left with following problem, upon which TcT provides the certificate MAYBE. Strict DPs: { sum^#(cons(s(n), x), cons(m, y)) -> c_1(sum^#(cons(n, x), cons(s(m), y))) , sum^#(cons(0(), x), y) -> c_2(sum^#(x, y)) , weight^#(x) -> c_3(if^#(empty(x), empty(tail(x)), x)) , if^#(false(), b, x) -> c_4(if2^#(b, x)) , if2^#(false(), x) -> c_5(weight^#(sum(x, cons(0(), tail(tail(x))))), sum^#(x, cons(0(), tail(tail(x))))) } Weak Trs: { 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 , empty(cons(n, x)) -> false() , empty(nil()) -> true() , tail(cons(n, x)) -> x , tail(nil()) -> nil() } Obligation: innermost runtime complexity Answer: MAYBE The input cannot be shown compatible Arrrr..