MAYBE * Step 1: DependencyPairs MAYBE + Considered Problem: - Strict TRS: app(x,y) -> helpa(0(),plus(length(x),length(y)),x,y) ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) helpa(c,l,ys,zs) -> if(ge(c,l),c,l,ys,zs) helpb(c,l,ys,zs) -> cons(take(c,ys,zs),helpa(s(c),l,ys,zs)) if(false(),c,l,ys,zs) -> helpb(c,l,ys,zs) if(true(),c,l,ys,zs) -> nil() length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) take(0(),cons(x,xs()),ys) -> x take(0(),nil(),cons(y,ys)) -> y take(s(c),cons(x,xs()),ys) -> take(c,xs(),ys) take(s(c),nil(),cons(y,ys)) -> take(c,nil(),ys) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0} - Obligation: innermost runtime complexity wrt. defined symbols {app,ge,helpa,helpb,if,length,plus ,take} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: DependencyPairs {dpKind_ = DT} + Details: We add the following dependency tuples: Strict DPs app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y) ,plus#(length(x),length(y)) ,length#(x) ,length#(y)) ge#(x,0()) -> c_2() ge#(0(),s(x)) -> c_3() ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) if#(true(),c,l,ys,zs) -> c_8() length#(cons(x,y)) -> c_9(length#(y)) length#(nil()) -> c_10() plus#(x,0()) -> c_11() plus#(x,s(y)) -> c_12(plus#(x,y)) take#(0(),cons(x,xs()),ys) -> c_13() take#(0(),nil(),cons(y,ys)) -> c_14() take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) Weak DPs and mark the set of starting terms. * Step 2: UsableRules MAYBE + Considered Problem: - Strict DPs: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) ge#(x,0()) -> c_2() ge#(0(),s(x)) -> c_3() ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) if#(true(),c,l,ys,zs) -> c_8() length#(cons(x,y)) -> c_9(length#(y)) length#(nil()) -> c_10() plus#(x,0()) -> c_11() plus#(x,s(y)) -> c_12(plus#(x,y)) take#(0(),cons(x,xs()),ys) -> c_13() take#(0(),nil(),cons(y,ys)) -> c_14() take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) - Weak TRS: app(x,y) -> helpa(0(),plus(length(x),length(y)),x,y) ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) helpa(c,l,ys,zs) -> if(ge(c,l),c,l,ys,zs) helpb(c,l,ys,zs) -> cons(take(c,ys,zs),helpa(s(c),l,ys,zs)) if(false(),c,l,ys,zs) -> helpb(c,l,ys,zs) if(true(),c,l,ys,zs) -> nil() length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) take(0(),cons(x,xs()),ys) -> x take(0(),nil(),cons(y,ys)) -> y take(s(c),cons(x,xs()),ys) -> take(c,xs(),ys) take(s(c),nil(),cons(y,ys)) -> take(c,nil(),ys) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3,app#/2,ge#/2,helpa#/4,helpb#/4,if#/5,length#/1 ,plus#/2,take#/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0,c_1/4,c_2/0,c_3/0,c_4/1,c_5/2,c_6/2,c_7/1 ,c_8/0,c_9/1,c_10/0,c_11/0,c_12/1,c_13/0,c_14/0,c_15/1,c_16/1} - Obligation: innermost runtime complexity wrt. defined symbols {app#,ge#,helpa#,helpb#,if#,length#,plus# ,take#} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) ge#(x,0()) -> c_2() ge#(0(),s(x)) -> c_3() ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) if#(true(),c,l,ys,zs) -> c_8() length#(cons(x,y)) -> c_9(length#(y)) length#(nil()) -> c_10() plus#(x,0()) -> c_11() plus#(x,s(y)) -> c_12(plus#(x,y)) take#(0(),cons(x,xs()),ys) -> c_13() take#(0(),nil(),cons(y,ys)) -> c_14() take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) * Step 3: PredecessorEstimation MAYBE + Considered Problem: - Strict DPs: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) ge#(x,0()) -> c_2() ge#(0(),s(x)) -> c_3() ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) if#(true(),c,l,ys,zs) -> c_8() length#(cons(x,y)) -> c_9(length#(y)) length#(nil()) -> c_10() plus#(x,0()) -> c_11() plus#(x,s(y)) -> c_12(plus#(x,y)) take#(0(),cons(x,xs()),ys) -> c_13() take#(0(),nil(),cons(y,ys)) -> c_14() take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) - Weak TRS: ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3,app#/2,ge#/2,helpa#/4,helpb#/4,if#/5,length#/1 ,plus#/2,take#/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0,c_1/4,c_2/0,c_3/0,c_4/1,c_5/2,c_6/2,c_7/1 ,c_8/0,c_9/1,c_10/0,c_11/0,c_12/1,c_13/0,c_14/0,c_15/1,c_16/1} - Obligation: innermost runtime complexity wrt. defined symbols {app#,ge#,helpa#,helpb#,if#,length#,plus# ,take#} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: PredecessorEstimation {onSelection = all simple predecessor estimation selector} + Details: We estimate the number of application of {2,3,8,10,11,13,14,15} by application of Pre({2,3,8,10,11,13,14,15}) = {1,4,5,6,9,12,16}. Here rules are labelled as follows: 1: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y) ,plus#(length(x),length(y)) ,length#(x) ,length#(y)) 2: ge#(x,0()) -> c_2() 3: ge#(0(),s(x)) -> c_3() 4: ge#(s(x),s(y)) -> c_4(ge#(x,y)) 5: helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) 6: helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) 7: if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) 8: if#(true(),c,l,ys,zs) -> c_8() 9: length#(cons(x,y)) -> c_9(length#(y)) 10: length#(nil()) -> c_10() 11: plus#(x,0()) -> c_11() 12: plus#(x,s(y)) -> c_12(plus#(x,y)) 13: take#(0(),cons(x,xs()),ys) -> c_13() 14: take#(0(),nil(),cons(y,ys)) -> c_14() 15: take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) 16: take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) * Step 4: RemoveWeakSuffixes MAYBE + Considered Problem: - Strict DPs: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) length#(cons(x,y)) -> c_9(length#(y)) plus#(x,s(y)) -> c_12(plus#(x,y)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) - Weak DPs: ge#(x,0()) -> c_2() ge#(0(),s(x)) -> c_3() if#(true(),c,l,ys,zs) -> c_8() length#(nil()) -> c_10() plus#(x,0()) -> c_11() take#(0(),cons(x,xs()),ys) -> c_13() take#(0(),nil(),cons(y,ys)) -> c_14() take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) - Weak TRS: ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3,app#/2,ge#/2,helpa#/4,helpb#/4,if#/5,length#/1 ,plus#/2,take#/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0,c_1/4,c_2/0,c_3/0,c_4/1,c_5/2,c_6/2,c_7/1 ,c_8/0,c_9/1,c_10/0,c_11/0,c_12/1,c_13/0,c_14/0,c_15/1,c_16/1} - Obligation: innermost runtime complexity wrt. defined symbols {app#,ge#,helpa#,helpb#,if#,length#,plus# ,take#} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y) ,plus#(length(x),length(y)) ,length#(x) ,length#(y)) -->_2 plus#(x,s(y)) -> c_12(plus#(x,y)):7 -->_4 length#(cons(x,y)) -> c_9(length#(y)):6 -->_3 length#(cons(x,y)) -> c_9(length#(y)):6 -->_1 helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)):3 -->_2 plus#(x,0()) -> c_11():13 -->_4 length#(nil()) -> c_10():12 -->_3 length#(nil()) -> c_10():12 2:S:ge#(s(x),s(y)) -> c_4(ge#(x,y)) -->_1 ge#(0(),s(x)) -> c_3():10 -->_1 ge#(x,0()) -> c_2():9 -->_1 ge#(s(x),s(y)) -> c_4(ge#(x,y)):2 3:S:helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) -->_1 if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)):5 -->_1 if#(true(),c,l,ys,zs) -> c_8():11 -->_2 ge#(0(),s(x)) -> c_3():10 -->_2 ge#(x,0()) -> c_2():9 -->_2 ge#(s(x),s(y)) -> c_4(ge#(x,y)):2 4:S:helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) -->_1 take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)):8 -->_1 take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)):16 -->_1 take#(0(),nil(),cons(y,ys)) -> c_14():15 -->_1 take#(0(),cons(x,xs()),ys) -> c_13():14 -->_2 helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)):3 5:S:if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) -->_1 helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)):4 6:S:length#(cons(x,y)) -> c_9(length#(y)) -->_1 length#(nil()) -> c_10():12 -->_1 length#(cons(x,y)) -> c_9(length#(y)):6 7:S:plus#(x,s(y)) -> c_12(plus#(x,y)) -->_1 plus#(x,0()) -> c_11():13 -->_1 plus#(x,s(y)) -> c_12(plus#(x,y)):7 8:S:take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) -->_1 take#(0(),nil(),cons(y,ys)) -> c_14():15 -->_1 take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)):8 9:W:ge#(x,0()) -> c_2() 10:W:ge#(0(),s(x)) -> c_3() 11:W:if#(true(),c,l,ys,zs) -> c_8() 12:W:length#(nil()) -> c_10() 13:W:plus#(x,0()) -> c_11() 14:W:take#(0(),cons(x,xs()),ys) -> c_13() 15:W:take#(0(),nil(),cons(y,ys)) -> c_14() 16:W:take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 9: ge#(x,0()) -> c_2() 10: ge#(0(),s(x)) -> c_3() 11: if#(true(),c,l,ys,zs) -> c_8() 14: take#(0(),cons(x,xs()),ys) -> c_13() 16: take#(s(c),cons(x,xs()),ys) -> c_15(take#(c,xs(),ys)) 15: take#(0(),nil(),cons(y,ys)) -> c_14() 12: length#(nil()) -> c_10() 13: plus#(x,0()) -> c_11() * Step 5: NaturalMI MAYBE + Considered Problem: - Strict DPs: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) length#(cons(x,y)) -> c_9(length#(y)) plus#(x,s(y)) -> c_12(plus#(x,y)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) - Weak TRS: ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3,app#/2,ge#/2,helpa#/4,helpb#/4,if#/5,length#/1 ,plus#/2,take#/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0,c_1/4,c_2/0,c_3/0,c_4/1,c_5/2,c_6/2,c_7/1 ,c_8/0,c_9/1,c_10/0,c_11/0,c_12/1,c_13/0,c_14/0,c_15/1,c_16/1} - Obligation: innermost runtime complexity wrt. defined symbols {app#,ge#,helpa#,helpb#,if#,length#,plus# ,take#} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 0, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation (containing no more than 0 non-zero interpretation-entries in the diagonal of the component-wise maxima): The following argument positions are considered usable: uargs(c_1) = {1,2,3,4}, uargs(c_4) = {1}, uargs(c_5) = {1,2}, uargs(c_6) = {1,2}, uargs(c_7) = {1}, uargs(c_9) = {1}, uargs(c_12) = {1}, uargs(c_16) = {1} Following symbols are considered usable: {length,app#,ge#,helpa#,helpb#,if#,length#,plus#,take#} TcT has computed the following interpretation: p(0) = [3] p(app) = [0] p(cons) = [0] p(false) = [0] p(ge) = [0] p(helpa) = [0] p(helpb) = [0] p(if) = [0] p(length) = [3] p(nil) = [0] p(plus) = [0] p(s) = [3] p(take) = [0] p(true) = [0] p(xs) = [0] p(app#) = [5] p(ge#) = [0] p(helpa#) = [0] p(helpb#) = [0] p(if#) = [0] p(length#) = [0] p(plus#) = [0] p(take#) = [0] p(c_1) = [1] x1 + [1] x2 + [1] x3 + [1] x4 + [0] p(c_2) = [0] p(c_3) = [0] p(c_4) = [2] x1 + [0] p(c_5) = [4] x1 + [1] x2 + [0] p(c_6) = [1] x1 + [2] x2 + [0] p(c_7) = [2] x1 + [0] p(c_8) = [0] p(c_9) = [2] x1 + [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [2] x1 + [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [4] x1 + [0] Following rules are strictly oriented: app#(x,y) = [5] > [0] = c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) Following rules are (at-least) weakly oriented: ge#(s(x),s(y)) = [0] >= [0] = c_4(ge#(x,y)) helpa#(c,l,ys,zs) = [0] >= [0] = c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) = [0] >= [0] = c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) = [0] >= [0] = c_7(helpb#(c,l,ys,zs)) length#(cons(x,y)) = [0] >= [0] = c_9(length#(y)) plus#(x,s(y)) = [0] >= [0] = c_12(plus#(x,y)) take#(s(c),nil(),cons(y,ys)) = [0] >= [0] = c_16(take#(c,nil(),ys)) length(cons(x,y)) = [3] >= [3] = s(length(y)) length(nil()) = [3] >= [3] = 0() * Step 6: Failure MAYBE + Considered Problem: - Strict DPs: ge#(s(x),s(y)) -> c_4(ge#(x,y)) helpa#(c,l,ys,zs) -> c_5(if#(ge(c,l),c,l,ys,zs),ge#(c,l)) helpb#(c,l,ys,zs) -> c_6(take#(c,ys,zs),helpa#(s(c),l,ys,zs)) if#(false(),c,l,ys,zs) -> c_7(helpb#(c,l,ys,zs)) length#(cons(x,y)) -> c_9(length#(y)) plus#(x,s(y)) -> c_12(plus#(x,y)) take#(s(c),nil(),cons(y,ys)) -> c_16(take#(c,nil(),ys)) - Weak DPs: app#(x,y) -> c_1(helpa#(0(),plus(length(x),length(y)),x,y),plus#(length(x),length(y)),length#(x),length#(y)) - Weak TRS: ge(x,0()) -> true() ge(0(),s(x)) -> false() ge(s(x),s(y)) -> ge(x,y) length(cons(x,y)) -> s(length(y)) length(nil()) -> 0() plus(x,0()) -> x plus(x,s(y)) -> s(plus(x,y)) - Signature: {app/2,ge/2,helpa/4,helpb/4,if/5,length/1,plus/2,take/3,app#/2,ge#/2,helpa#/4,helpb#/4,if#/5,length#/1 ,plus#/2,take#/3} / {0/0,cons/2,false/0,nil/0,s/1,true/0,xs/0,c_1/4,c_2/0,c_3/0,c_4/1,c_5/2,c_6/2,c_7/1 ,c_8/0,c_9/1,c_10/0,c_11/0,c_12/1,c_13/0,c_14/0,c_15/1,c_16/1} - Obligation: innermost runtime complexity wrt. defined symbols {app#,ge#,helpa#,helpb#,if#,length#,plus# ,take#} and constructors {0,cons,false,nil,s,true,xs} + Applied Processor: EmptyProcessor + Details: The problem is still open. MAYBE