MAYBE * Step 1: DependencyPairs MAYBE + Considered Problem: - Strict TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) foldl#3(x2,Nil()) -> x2 foldl#3(x6,Cons(x4,x2)) -> foldl#3(max#2(x6,x4),x2) main(x1) -> foldl#3(0(),scanr#3(x1)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1} / {0/0,Cons/2,M/1,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1,foldl#3,main,max#2,minus#2,plus#2 ,scanr#3} and constructors {0,Cons,M,Nil,S} + Applied Processor: DependencyPairs {dpKind_ = DT} + Details: We add the following dependency tuples: Strict DPs cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x2,Nil()) -> c_8() foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(0(),x8) -> c_11() max#2#(S(x12),0()) -> c_12() max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(0(),x16) -> c_14() minus#2#(S(x20),0()) -> c_15() minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(0(),S(x2)) -> c_17() plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) scanr#3#(Nil()) -> c_20() Weak DPs and mark the set of starting terms. * Step 2: UsableRules MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x2,Nil()) -> c_8() foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(0(),x8) -> c_11() max#2#(S(x12),0()) -> c_12() max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(0(),x16) -> c_14() minus#2#(S(x20),0()) -> c_15() minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(0(),S(x2)) -> c_17() plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) scanr#3#(Nil()) -> c_20() - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) foldl#3(x2,Nil()) -> x2 foldl#3(x6,Cons(x4,x2)) -> foldl#3(max#2(x6,x4),x2) main(x1) -> foldl#3(0(),scanr#3(x1)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x2,Nil()) -> c_8() foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(0(),x8) -> c_11() max#2#(S(x12),0()) -> c_12() max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(0(),x16) -> c_14() minus#2#(S(x20),0()) -> c_15() minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(0(),S(x2)) -> c_17() plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) scanr#3#(Nil()) -> c_20() * Step 3: PredecessorEstimation MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x2,Nil()) -> c_8() foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(0(),x8) -> c_11() max#2#(S(x12),0()) -> c_12() max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(0(),x16) -> c_14() minus#2#(S(x20),0()) -> c_15() minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(0(),S(x2)) -> c_17() plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) scanr#3#(Nil()) -> c_20() - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimation {onSelection = all simple predecessor estimation selector} + Details: We estimate the number of application of {1,2,3,4,6,8,11,12,14,15,17,20} by application of Pre({1,2,3,4,6,8,11,12,14,15,17,20}) = {7,9,10,13,16,18,19}. Here rules are labelled as follows: 1: cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() 2: cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() 3: cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() 4: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() 5: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) 6: cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() 7: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) 8: foldl#3#(x2,Nil()) -> c_8() 9: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) 10: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) 11: max#2#(0(),x8) -> c_11() 12: max#2#(S(x12),0()) -> c_12() 13: max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) 14: minus#2#(0(),x16) -> c_14() 15: minus#2#(S(x20),0()) -> c_15() 16: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) 17: plus#2#(0(),S(x2)) -> c_17() 18: plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) 19: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) 20: scanr#3#(Nil()) -> c_20() * Step 4: RemoveWeakSuffixes MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() foldl#3#(x2,Nil()) -> c_8() max#2#(0(),x8) -> c_11() max#2#(S(x12),0()) -> c_12() minus#2#(0(),x16) -> c_14() minus#2#(S(x20),0()) -> c_15() plus#2#(0(),S(x2)) -> c_17() scanr#3#(Nil()) -> c_20() - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 2:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 -->_1 minus#2#(S(x20),0()) -> c_15():18 -->_1 minus#2#(0(),x16) -> c_14():17 3:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):5 -->_2 max#2#(S(x12),0()) -> c_12():16 -->_2 max#2#(0(),x8) -> c_11():15 -->_1 foldl#3#(x2,Nil()) -> c_8():14 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 4:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 -->_2 scanr#3#(Nil()) -> c_20():20 -->_1 foldl#3#(x2,Nil()) -> c_8():14 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 5:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x12),0()) -> c_12():16 -->_1 max#2#(0(),x8) -> c_11():15 -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):5 6:S:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x20),0()) -> c_15():18 -->_1 minus#2#(0(),x16) -> c_14():17 -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 7:S:plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) -->_1 plus#2#(0(),S(x2)) -> c_17():19 -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 8:S:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Nil()) -> c_20():20 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6():13 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4():12 -->_1 cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3():11 -->_1 cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2():10 -->_1 cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1():9 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):2 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):1 9:W:cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() 10:W:cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() 11:W:cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() 12:W:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() 13:W:cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() 14:W:foldl#3#(x2,Nil()) -> c_8() 15:W:max#2#(0(),x8) -> c_11() 16:W:max#2#(S(x12),0()) -> c_12() 17:W:minus#2#(0(),x16) -> c_14() 18:W:minus#2#(S(x20),0()) -> c_15() 19:W:plus#2#(0(),S(x2)) -> c_17() 20:W:scanr#3#(Nil()) -> c_20() The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 9: cond_scanr_f_z_xs_1#(Cons(0(),x11),0()) -> c_1() 10: cond_scanr_f_z_xs_1#(Cons(0(),x11),M(x2)) -> c_2() 11: cond_scanr_f_z_xs_1#(Cons(0(),x11),S(x2)) -> c_3() 12: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),0()) -> c_4() 13: cond_scanr_f_z_xs_1#(Cons(S(x40),x23),M(0())) -> c_6() 20: scanr#3#(Nil()) -> c_20() 14: foldl#3#(x2,Nil()) -> c_8() 15: max#2#(0(),x8) -> c_11() 16: max#2#(S(x12),0()) -> c_12() 17: minus#2#(0(),x16) -> c_14() 18: minus#2#(S(x20),0()) -> c_15() 19: plus#2#(0(),S(x2)) -> c_17() * Step 5: Decompose MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Decompose {onSelection = all cycle independent sub-graph, withBound = RelativeAdd} + Details: We analyse the complexity of following sub-problems (R) and (S). Problem (S) is obtained from the input problem by shifting strict rules from (R) into the weak component. Problem (R) - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/2,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} Problem (S) - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/2,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} ** Step 5.a:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 2:W:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 3:W:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):5 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 4:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 5:W:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):5 6:W:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 7:S:plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 8:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):1 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):2 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 3: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) 5: max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) 2: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) 6: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) ** Step 5.a:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 4:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 7:S:plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):7 8:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):1 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):8 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: main#(x1) -> c_10(scanr#3#(x1)) ** Step 5.a:3: UsableRules WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) main#(x1) -> c_10(scanr#3#(x1)) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) ** Step 5.a:4: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 2: plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) Consider the set of all dependency pairs 1: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) 2: plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) 3: main#(x1) -> c_10(scanr#3#(x1)) 4: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {2} These cover all (indirect) predecessors of dependency pairs {2,3} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. *** Step 5.a:4.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_5) = {1}, uargs(c_10) = {1}, uargs(c_18) = {1}, uargs(c_19) = {1,2} Following symbols are considered usable: {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2#,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [1] p(Cons) = [1] x1 + [1] x2 + [2] p(M) = [1] x1 + [2] p(Nil) = [1] p(S) = [1] x1 + [2] p(cond_scanr_f_z_xs_1) = [3] p(foldl#3) = [0] p(main) = [0] p(max#2) = [0] p(minus#2) = [4] x1 + [2] x2 + [1] p(plus#2) = [3] p(scanr#3) = [0] p(cond_scanr_f_z_xs_1#) = [1] x2 + [1] p(foldl#3#) = [0] p(main#) = [6] x1 + [3] p(max#2#) = [0] p(minus#2#) = [2] x1 + [1] x2 + [1] p(plus#2#) = [1] x1 + [1] p(scanr#3#) = [6] x1 + [3] p(c_1) = [1] p(c_2) = [1] p(c_3) = [1] p(c_4) = [1] p(c_5) = [1] x1 + [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [1] x1 + [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [2] p(c_15) = [1] p(c_16) = [1] x1 + [1] p(c_17) = [1] p(c_18) = [1] x1 + [0] p(c_19) = [6] x1 + [1] x2 + [6] p(c_20) = [0] Following rules are strictly oriented: plus#2#(S(x4),S(x2)) = [1] x4 + [3] > [1] x4 + [1] = c_18(plus#2#(x4,S(x2))) Following rules are (at-least) weakly oriented: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) = [1] x4 + [3] >= [1] x4 + [3] = c_5(plus#2#(S(x4),S(x2))) main#(x1) = [6] x1 + [3] >= [6] x1 + [3] = c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) = [6] x2 + [6] x4 + [15] >= [6] x2 + [6] x4 + [15] = c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) *** Step 5.a:4.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () *** Step 5.a:4.b:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):3 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 3:W:plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):3 4:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 3: plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) *** Step 5.a:4.b:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 4:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):1 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() *** Step 5.a:4.b:3: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/0,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 1: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() Consider the set of all dependency pairs 1: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() 2: main#(x1) -> c_10(scanr#3#(x1)) 3: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {1} These cover all (indirect) predecessors of dependency pairs {1,2} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. **** Step 5.a:4.b:3.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/0,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_10) = {1}, uargs(c_19) = {1,2} Following symbols are considered usable: {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2#,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [1] p(Cons) = [1] x1 + [1] x2 + [0] p(M) = [0] p(Nil) = [6] p(S) = [1] x1 + [4] p(cond_scanr_f_z_xs_1) = [1] x2 + [6] p(foldl#3) = [2] x2 + [0] p(main) = [2] p(max#2) = [1] x2 + [1] p(minus#2) = [3] x1 + [0] p(plus#2) = [2] x1 + [0] p(scanr#3) = [0] p(cond_scanr_f_z_xs_1#) = [1] x2 + [0] p(foldl#3#) = [2] x1 + [4] x2 + [0] p(main#) = [4] x1 + [1] p(max#2#) = [4] x2 + [4] p(minus#2#) = [1] x1 + [0] p(plus#2#) = [2] p(scanr#3#) = [4] x1 + [0] p(c_1) = [1] p(c_2) = [1] p(c_3) = [0] p(c_4) = [1] p(c_5) = [2] p(c_6) = [1] p(c_7) = [0] p(c_8) = [0] p(c_9) = [2] x1 + [0] p(c_10) = [1] x1 + [1] p(c_11) = [0] p(c_12) = [0] p(c_13) = [4] p(c_14) = [4] p(c_15) = [0] p(c_16) = [4] p(c_17) = [0] p(c_18) = [2] x1 + [1] p(c_19) = [4] x1 + [1] x2 + [0] p(c_20) = [1] Following rules are strictly oriented: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) = [1] x4 + [4] > [2] = c_5() Following rules are (at-least) weakly oriented: main#(x1) = [4] x1 + [1] >= [4] x1 + [1] = c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) = [4] x2 + [4] x4 + [0] >= [4] x2 + [4] x4 + [0] = c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) **** Step 5.a:4.b:3.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/0,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () **** Step 5.a:4.b:3.b:1: RemoveWeakSuffixes WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/0,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:W:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):3 3:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):3 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5():1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 2: main#(x1) -> c_10(scanr#3#(x1)) 3: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) 1: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5() **** Step 5.a:4.b:3.b:2: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/0,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). ** Step 5.b:1: RemoveWeakSuffixes MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 2:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):2 3:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):2 4:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 5:S:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 6:S:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))):7 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):1 7:W:cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):8 8:W:plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) -->_1 plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))):8 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 7: cond_scanr_f_z_xs_1#(Cons(S(x2),x11),S(x4)) -> c_5(plus#2#(S(x4),S(x2))) 8: plus#2#(S(x4),S(x2)) -> c_18(plus#2#(x4,S(x2))) ** Step 5.b:2: Decompose MAYBE + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Decompose {onSelection = all cycle independent sub-graph, withBound = RelativeAdd} + Details: We analyse the complexity of following sub-problems (R) and (S). Problem (S) is obtained from the input problem by shifting strict rules from (R) into the weak component. Problem (R) - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/2,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} Problem (S) - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/2,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} *** Step 5.b:2.a:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 2:W:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):2 3:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):2 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 4:W:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 5:S:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 6:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):1 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 2: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) 4: max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) *** Step 5.b:2.a:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 3:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 5:S:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):5 6:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):1 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):6 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: main#(x1) -> c_10(scanr#3#(x1)) *** Step 5.b:2.a:3: UsableRules WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) main#(x1) -> c_10(scanr#3#(x1)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) *** Step 5.b:2.a:4: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 2: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) Consider the set of all dependency pairs 1: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) 2: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) 3: main#(x1) -> c_10(scanr#3#(x1)) 4: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {2} These cover all (indirect) predecessors of dependency pairs {2,3} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. **** Step 5.b:2.a:4.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_7) = {1}, uargs(c_10) = {1}, uargs(c_16) = {1}, uargs(c_19) = {1,2} Following symbols are considered usable: {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2#,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [2] p(Cons) = [1] x1 + [1] x2 + [0] p(M) = [1] x1 + [0] p(Nil) = [2] p(S) = [1] x1 + [1] p(cond_scanr_f_z_xs_1) = [4] x2 + [4] p(foldl#3) = [1] x2 + [1] p(main) = [1] x1 + [0] p(max#2) = [4] x1 + [2] x2 + [1] p(minus#2) = [4] x2 + [7] p(plus#2) = [4] x1 + [1] x2 + [3] p(scanr#3) = [0] p(cond_scanr_f_z_xs_1#) = [4] x2 + [0] p(foldl#3#) = [1] x1 + [1] p(main#) = [4] x1 + [6] p(max#2#) = [1] x2 + [0] p(minus#2#) = [4] x2 + [0] p(plus#2#) = [1] p(scanr#3#) = [4] x1 + [2] p(c_1) = [2] p(c_2) = [0] p(c_3) = [0] p(c_4) = [1] p(c_5) = [1] p(c_6) = [4] p(c_7) = [1] x1 + [4] p(c_8) = [0] p(c_9) = [4] p(c_10) = [1] x1 + [2] p(c_11) = [0] p(c_12) = [0] p(c_13) = [1] x1 + [0] p(c_14) = [1] p(c_15) = [1] p(c_16) = [1] x1 + [0] p(c_17) = [1] p(c_18) = [1] x1 + [0] p(c_19) = [1] x1 + [1] x2 + [0] p(c_20) = [1] Following rules are strictly oriented: minus#2#(S(x4),S(x2)) = [4] x2 + [4] > [4] x2 + [0] = c_16(minus#2#(x4,x2)) Following rules are (at-least) weakly oriented: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) = [4] x4 + [4] >= [4] x4 + [4] = c_7(minus#2#(x8,x4)) main#(x1) = [4] x1 + [6] >= [4] x1 + [4] = c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) = [4] x2 + [4] x4 + [2] >= [4] x2 + [4] x4 + [2] = c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) **** Step 5.b:2.a:4.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () **** Step 5.b:2.a:4.b:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):3 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 3:W:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):3 4:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 3: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) **** Step 5.b:2.a:4.b:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 4:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):1 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() **** Step 5.b:2.a:4.b:3: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/0,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 1: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() Consider the set of all dependency pairs 1: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() 2: main#(x1) -> c_10(scanr#3#(x1)) 3: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {1} These cover all (indirect) predecessors of dependency pairs {1,2} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. ***** Step 5.b:2.a:4.b:3.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/0,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_10) = {1}, uargs(c_19) = {1,2} Following symbols are considered usable: {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2#,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [2] p(Cons) = [1] x2 + [6] p(M) = [0] p(Nil) = [0] p(S) = [1] x1 + [0] p(cond_scanr_f_z_xs_1) = [1] x1 + [2] x2 + [4] p(foldl#3) = [0] p(main) = [0] p(max#2) = [0] p(minus#2) = [2] x2 + [0] p(plus#2) = [4] x1 + [0] p(scanr#3) = [0] p(cond_scanr_f_z_xs_1#) = [2] p(foldl#3#) = [0] p(main#) = [4] x1 + [4] p(max#2#) = [0] p(minus#2#) = [0] p(plus#2#) = [0] p(scanr#3#) = [1] x1 + [1] p(c_1) = [0] p(c_2) = [0] p(c_3) = [0] p(c_4) = [0] p(c_5) = [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [4] x1 + [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [0] p(c_17) = [0] p(c_18) = [0] p(c_19) = [1] x1 + [1] x2 + [1] p(c_20) = [0] Following rules are strictly oriented: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) = [2] > [0] = c_7() Following rules are (at-least) weakly oriented: main#(x1) = [4] x1 + [4] >= [4] x1 + [4] = c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) = [1] x2 + [7] >= [1] x2 + [4] = c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) ***** Step 5.b:2.a:4.b:3.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/0,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () ***** Step 5.b:2.a:4.b:3.b:1: RemoveWeakSuffixes WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/0,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:W:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() 2:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):3 3:W:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):3 -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7():1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 2: main#(x1) -> c_10(scanr#3#(x1)) 3: scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) 1: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7() ***** Step 5.b:2.a:4.b:3.b:2: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/0,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). *** Step 5.b:2.b:1: RemoveWeakSuffixes MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak DPs: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 2:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 3:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 4:S:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_1 cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)):5 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 5:W:cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 6:W:minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) -->_1 minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)):6 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 5: cond_scanr_f_z_xs_1#(Cons(S(x8),x23),M(S(x4))) -> c_7(minus#2#(x8,x4)) 6: minus#2#(S(x4),S(x2)) -> c_16(minus#2#(x4,x2)) *** Step 5.b:2.b:2: SimplifyRHS MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/2 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 2:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 3:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 4:S:scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(cond_scanr_f_z_xs_1#(scanr#3(x2),x4),scanr#3#(x2)):4 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) *** Step 5.b:2.b:3: Decompose MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Decompose {onSelection = all cycle independent sub-graph, withBound = RelativeAdd} + Details: We analyse the complexity of following sub-problems (R) and (S). Problem (S) is obtained from the input problem by shifting strict rules from (R) into the weak component. Problem (R) - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/1,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} Problem (S) - Strict DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0 ,c_3/0,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1 ,c_19/1,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} **** Step 5.b:2.b:3.a:1: RemoveWeakSuffixes MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 2:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):4 3:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 4:W:scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):4 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 4: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) **** Step 5.b:2.b:3.a:2: SimplifyRHS MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 2:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 3:S:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):3 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) **** Step 5.b:2.b:3.a:3: DecomposeDG MAYBE + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: DecomposeDG {onSelection = all below first cut in WDG, onUpper = Just someStrategy, onLower = Nothing} + Details: We decompose the input problem according to the dependency graph into the upper component foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) and a lower component max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) Further, following extension rules are added to the lower component. foldl#3#(x6,Cons(x4,x2)) -> foldl#3#(max#2(x6,x4),x2) foldl#3#(x6,Cons(x4,x2)) -> max#2#(x6,x4) main#(x1) -> foldl#3#(0(),scanr#3(x1)) ***** Step 5.b:2.b:3.a:3.a:1: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 1: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) Consider the set of all dependency pairs 1: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) 2: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {1} These cover all (indirect) predecessors of dependency pairs {1,2} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. ****** Step 5.b:2.b:3.a:3.a:1.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) - Weak DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_9) = {1}, uargs(c_10) = {1} Following symbols are considered usable: {cond_scanr_f_z_xs_1,max#2,minus#2,plus#2,scanr#3,cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [0] p(Cons) = [1] x1 + [1] x2 + [4] p(M) = [1] x1 + [0] p(Nil) = [4] p(S) = [0] p(cond_scanr_f_z_xs_1) = [1] x1 + [4] p(foldl#3) = [4] x1 + [4] x2 + [0] p(main) = [1] p(max#2) = [2] x2 + [7] p(minus#2) = [0] p(plus#2) = [4] x1 + [0] p(scanr#3) = [2] x1 + [0] p(cond_scanr_f_z_xs_1#) = [1] x1 + [1] p(foldl#3#) = [1] x1 + [2] x2 + [1] p(main#) = [5] x1 + [1] p(max#2#) = [1] x1 + [0] p(minus#2#) = [1] x1 + [1] p(plus#2#) = [1] x1 + [2] p(scanr#3#) = [0] p(c_1) = [2] p(c_2) = [1] p(c_3) = [0] p(c_4) = [4] p(c_5) = [4] p(c_6) = [0] p(c_7) = [0] p(c_8) = [1] p(c_9) = [1] x1 + [1] x2 + [0] p(c_10) = [1] x1 + [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [1] x1 + [0] p(c_14) = [1] p(c_15) = [1] p(c_16) = [1] x1 + [2] p(c_17) = [1] p(c_18) = [1] p(c_19) = [1] x1 + [0] p(c_20) = [1] Following rules are strictly oriented: foldl#3#(x6,Cons(x4,x2)) = [2] x2 + [2] x4 + [1] x6 + [9] > [2] x2 + [2] x4 + [1] x6 + [8] = c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) Following rules are (at-least) weakly oriented: main#(x1) = [5] x1 + [1] >= [4] x1 + [1] = c_10(foldl#3#(0(),scanr#3(x1))) cond_scanr_f_z_xs_1(Cons(0(),x11),0()) = [1] x11 + [8] >= [1] x11 + [8] = Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) = [1] x11 + [8] >= [1] x11 + [8] = Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) = [1] x11 + [8] >= [1] x11 + [8] = Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) = [1] x11 + [8] >= [1] x11 + [8] = Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) = [1] x11 + [8] >= [1] x11 + [8] = Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) = [1] x23 + [8] >= [1] x23 + [8] = Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) = [1] x23 + [8] >= [1] x23 + [8] = Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) = [2] x8 + [7] >= [1] x8 + [0] = x8 max#2(S(x12),0()) = [7] >= [0] = S(x12) max#2(S(x4),S(x2)) = [7] >= [0] = S(max#2(x4,x2)) minus#2(0(),x16) = [0] >= [0] = 0() minus#2(S(x20),0()) = [0] >= [0] = S(x20) minus#2(S(x4),S(x2)) = [0] >= [0] = minus#2(x4,x2) plus#2(0(),S(x2)) = [0] >= [0] = S(x2) plus#2(S(x4),S(x2)) = [0] >= [0] = S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) = [2] x2 + [2] x4 + [8] >= [2] x2 + [4] = cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) = [8] >= [8] = Cons(0(),Nil()) ****** Step 5.b:2.b:3.a:3.a:1.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () ****** Step 5.b:2.b:3.a:3.a:1.b:1: RemoveWeakSuffixes WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:W:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 2:W:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 2: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1))) 1: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) ****** Step 5.b:2.b:3.a:3.a:1.b:2: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). ***** Step 5.b:2.b:3.a:3.b:1: Failure MAYBE + Considered Problem: - Strict DPs: max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> foldl#3#(max#2(x6,x4),x2) foldl#3#(x6,Cons(x4,x2)) -> max#2#(x6,x4) main#(x1) -> foldl#3#(0(),scanr#3(x1)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is still open. **** Step 5.b:2.b:3.b:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak DPs: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 -->_2 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 2:S:scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 3:W:foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) -->_2 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 -->_1 foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)):3 4:W:max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) -->_1 max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)):4 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 3: foldl#3#(x6,Cons(x4,x2)) -> c_9(foldl#3#(max#2(x6,x4),x2),max#2#(x6,x4)) 4: max#2#(S(x4),S(x2)) -> c_13(max#2#(x4,x2)) **** Step 5.b:2.b:3.b:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/2,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:main#(x1) -> c_10(foldl#3#(0(),scanr#3(x1)),scanr#3#(x1)) -->_2 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 2:S:scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: main#(x1) -> c_10(scanr#3#(x1)) **** Step 5.b:2.b:3.b:3: UsableRules WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Weak TRS: cond_scanr_f_z_xs_1(Cons(0(),x11),0()) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),M(x2)) -> Cons(0(),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(0(),x11),S(x2)) -> Cons(S(x2),Cons(0(),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),0()) -> Cons(S(x2),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x2),x11),S(x4)) -> Cons(plus#2(S(x4),S(x2)),Cons(S(x2),x11)) cond_scanr_f_z_xs_1(Cons(S(x40),x23),M(0())) -> Cons(S(x40),Cons(S(x40),x23)) cond_scanr_f_z_xs_1(Cons(S(x8),x23),M(S(x4))) -> Cons(minus#2(x8,x4),Cons(S(x8),x23)) max#2(0(),x8) -> x8 max#2(S(x12),0()) -> S(x12) max#2(S(x4),S(x2)) -> S(max#2(x4,x2)) minus#2(0(),x16) -> 0() minus#2(S(x20),0()) -> S(x20) minus#2(S(x4),S(x2)) -> minus#2(x4,x2) plus#2(0(),S(x2)) -> S(x2) plus#2(S(x4),S(x2)) -> S(plus#2(x4,S(x2))) scanr#3(Cons(x4,x2)) -> cond_scanr_f_z_xs_1(scanr#3(x2),x4) scanr#3(Nil()) -> Cons(0(),Nil()) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) **** Step 5.b:2.b:3.b:4: PredecessorEstimationCP WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: PredecessorEstimationCP {onSelectionCP = any intersect of rules of CDG leaf and strict-rules, withComplexityPair = NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}} + Details: We first use the processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing} to orient following rules strictly: 2: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) Consider the set of all dependency pairs 1: main#(x1) -> c_10(scanr#3#(x1)) 2: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) Processor NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Nothing}induces the complexity certificateTIME (?,O(n^1)) SPACE(?,?)on application of the dependency pairs {2} These cover all (indirect) predecessors of dependency pairs {1,2} their number of applications is equally bounded. The dependency pairs are shifted into the weak component. ***** Step 5.b:2.b:3.b:4.a:1: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just first alternative for predecessorEstimation on any intersect of rules of CDG leaf and strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_10) = {1}, uargs(c_19) = {1} Following symbols are considered usable: {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2#,plus#2#,scanr#3#} TcT has computed the following interpretation: p(0) = [0] p(Cons) = [1] x1 + [1] x2 + [1] p(M) = [1] x1 + [0] p(Nil) = [0] p(S) = [1] x1 + [0] p(cond_scanr_f_z_xs_1) = [0] p(foldl#3) = [0] p(main) = [0] p(max#2) = [0] p(minus#2) = [0] p(plus#2) = [0] p(scanr#3) = [0] p(cond_scanr_f_z_xs_1#) = [0] p(foldl#3#) = [0] p(main#) = [8] x1 + [1] p(max#2#) = [2] x2 + [2] p(minus#2#) = [2] x2 + [1] p(plus#2#) = [2] x2 + [0] p(scanr#3#) = [2] x1 + [0] p(c_1) = [1] p(c_2) = [1] p(c_3) = [4] p(c_4) = [1] p(c_5) = [4] x1 + [0] p(c_6) = [8] p(c_7) = [2] x1 + [1] p(c_8) = [0] p(c_9) = [8] x1 + [1] x2 + [0] p(c_10) = [2] x1 + [1] p(c_11) = [1] p(c_12) = [1] p(c_13) = [2] x1 + [0] p(c_14) = [8] p(c_15) = [0] p(c_16) = [1] x1 + [8] p(c_17) = [1] p(c_18) = [8] x1 + [0] p(c_19) = [1] x1 + [1] p(c_20) = [1] Following rules are strictly oriented: scanr#3#(Cons(x4,x2)) = [2] x2 + [2] x4 + [2] > [2] x2 + [1] = c_19(scanr#3#(x2)) Following rules are (at-least) weakly oriented: main#(x1) = [8] x1 + [1] >= [4] x1 + [1] = c_10(scanr#3#(x1)) ***** Step 5.b:2.b:3.b:4.a:2: Assumption WORST_CASE(?,O(1)) + Considered Problem: - Strict DPs: main#(x1) -> c_10(scanr#3#(x1)) - Weak DPs: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: Assumption {assumed = Certificate {spaceUB = Unknown, spaceLB = Unknown, timeUB = Poly (Just 0), timeLB = Unknown}} + Details: () ***** Step 5.b:2.b:3.b:4.b:1: RemoveWeakSuffixes WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: main#(x1) -> c_10(scanr#3#(x1)) scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:W:main#(x1) -> c_10(scanr#3#(x1)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 2:W:scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) -->_1 scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)):2 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 1: main#(x1) -> c_10(scanr#3#(x1)) 2: scanr#3#(Cons(x4,x2)) -> c_19(scanr#3#(x2)) ***** Step 5.b:2.b:3.b:4.b:2: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Signature: {cond_scanr_f_z_xs_1/2,foldl#3/2,main/1,max#2/2,minus#2/2,plus#2/2,scanr#3/1,cond_scanr_f_z_xs_1#/2 ,foldl#3#/2,main#/1,max#2#/2,minus#2#/2,plus#2#/2,scanr#3#/1} / {0/0,Cons/2,M/1,Nil/0,S/1,c_1/0,c_2/0,c_3/0 ,c_4/0,c_5/1,c_6/0,c_7/1,c_8/0,c_9/2,c_10/1,c_11/0,c_12/0,c_13/1,c_14/0,c_15/0,c_16/1,c_17/0,c_18/1,c_19/1 ,c_20/0} - Obligation: innermost runtime complexity wrt. defined symbols {cond_scanr_f_z_xs_1#,foldl#3#,main#,max#2#,minus#2# ,plus#2#,scanr#3#} and constructors {0,Cons,M,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). MAYBE