WORST_CASE(Omega(n^1),O(n^1)) * Step 1: Sum WORST_CASE(Omega(n^1),O(n^1)) + Considered Problem: - Strict TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: Sum {left = someStrategy, right = someStrategy} + Details: () ** Step 1.a:1: DecreasingLoops WORST_CASE(Omega(n^1),?) + Considered Problem: - Strict TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: DecreasingLoops {bound = AnyLoop, narrow = 10} + Details: The system has following decreasing Loops: fold#3(y){y -> Cons(x,y)} = fold#3(Cons(x,y)) ->^+ plus#2(x,fold#3(y)) = C[fold#3(y) = fold#3(y){}] ** Step 1.b:1: NaturalPI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: NaturalPI {shape = Linear, restrict = Restrict, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a polynomial interpretation of kind constructor-based(linear): The following argument positions are considered usable: uargs(S) = {1}, uargs(plus#2) = {2} Following symbols are considered usable: {fold#3,main,plus#2} TcT has computed the following interpretation: p(0) = 0 p(Cons) = 2 p(Nil) = 2 p(S) = x1 p(fold#3) = 0 p(main) = 2 + x1 p(plus#2) = 4*x2 Following rules are strictly oriented: main(x1) = 2 + x1 > 0 = fold#3(x1) Following rules are (at-least) weakly oriented: fold#3(Cons(x4,x2)) = 0 >= 0 = plus#2(x4,fold#3(x2)) fold#3(Nil()) = 0 >= 0 = 0() plus#2(0(),x12) = 4*x12 >= x12 = x12 plus#2(S(x4),x2) = 4*x2 >= 4*x2 = S(plus#2(x4,x2)) ** Step 1.b:2: NaturalPI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Weak TRS: main(x1) -> fold#3(x1) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: NaturalPI {shape = Linear, restrict = Restrict, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a polynomial interpretation of kind constructor-based(linear): The following argument positions are considered usable: uargs(S) = {1}, uargs(plus#2) = {2} Following symbols are considered usable: {fold#3,main,plus#2} TcT has computed the following interpretation: p(0) = 14 p(Cons) = 2 + x2 p(Nil) = 5 p(S) = x1 p(fold#3) = 4 + 2*x1 p(main) = 4 + 2*x1 p(plus#2) = x2 Following rules are strictly oriented: fold#3(Cons(x4,x2)) = 8 + 2*x2 > 4 + 2*x2 = plus#2(x4,fold#3(x2)) Following rules are (at-least) weakly oriented: fold#3(Nil()) = 14 >= 14 = 0() main(x1) = 4 + 2*x1 >= 4 + 2*x1 = fold#3(x1) plus#2(0(),x12) = x12 >= x12 = x12 plus#2(S(x4),x2) = x2 >= x2 = S(plus#2(x4,x2)) ** Step 1.b:3: NaturalPI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict TRS: fold#3(Nil()) -> 0() plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Weak TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) main(x1) -> fold#3(x1) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: NaturalPI {shape = Linear, restrict = Restrict, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a polynomial interpretation of kind constructor-based(linear): The following argument positions are considered usable: uargs(S) = {1}, uargs(plus#2) = {2} Following symbols are considered usable: {fold#3,main,plus#2} TcT has computed the following interpretation: p(0) = 3 p(Cons) = 0 p(Nil) = 0 p(S) = x1 p(fold#3) = 5 p(main) = 5 p(plus#2) = x2 Following rules are strictly oriented: fold#3(Nil()) = 5 > 3 = 0() Following rules are (at-least) weakly oriented: fold#3(Cons(x4,x2)) = 5 >= 5 = plus#2(x4,fold#3(x2)) main(x1) = 5 >= 5 = fold#3(x1) plus#2(0(),x12) = x12 >= x12 = x12 plus#2(S(x4),x2) = x2 >= x2 = S(plus#2(x4,x2)) ** Step 1.b:4: NaturalPI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict TRS: plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Weak TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: NaturalPI {shape = Linear, restrict = Restrict, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a polynomial interpretation of kind constructor-based(linear): The following argument positions are considered usable: uargs(S) = {1}, uargs(plus#2) = {2} Following symbols are considered usable: {fold#3,main,plus#2} TcT has computed the following interpretation: p(0) = 8 p(Cons) = x1 + x2 p(Nil) = 5 p(S) = 7 + x1 p(fold#3) = 1 + 4*x1 p(main) = 8 + 8*x1 p(plus#2) = x1 + x2 Following rules are strictly oriented: plus#2(0(),x12) = 8 + x12 > x12 = x12 Following rules are (at-least) weakly oriented: fold#3(Cons(x4,x2)) = 1 + 4*x2 + 4*x4 >= 1 + 4*x2 + x4 = plus#2(x4,fold#3(x2)) fold#3(Nil()) = 21 >= 8 = 0() main(x1) = 8 + 8*x1 >= 1 + 4*x1 = fold#3(x1) plus#2(S(x4),x2) = 7 + x2 + x4 >= 7 + x2 + x4 = S(plus#2(x4,x2)) ** Step 1.b:5: NaturalPI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict TRS: plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Weak TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) plus#2(0(),x12) -> x12 - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: NaturalPI {shape = Linear, restrict = Restrict, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a polynomial interpretation of kind constructor-based(linear): The following argument positions are considered usable: uargs(S) = {1}, uargs(plus#2) = {2} Following symbols are considered usable: {fold#3,main,plus#2} TcT has computed the following interpretation: p(0) = 5 p(Cons) = 2 + x1 + x2 p(Nil) = 0 p(S) = 1 + x1 p(fold#3) = 14 + 8*x1 p(main) = 15 + 10*x1 p(plus#2) = 4 + 2*x1 + x2 Following rules are strictly oriented: plus#2(S(x4),x2) = 6 + x2 + 2*x4 > 5 + x2 + 2*x4 = S(plus#2(x4,x2)) Following rules are (at-least) weakly oriented: fold#3(Cons(x4,x2)) = 30 + 8*x2 + 8*x4 >= 18 + 8*x2 + 2*x4 = plus#2(x4,fold#3(x2)) fold#3(Nil()) = 14 >= 5 = 0() main(x1) = 15 + 10*x1 >= 14 + 8*x1 = fold#3(x1) plus#2(0(),x12) = 14 + x12 >= x12 = x12 ** Step 1.b:6: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak TRS: fold#3(Cons(x4,x2)) -> plus#2(x4,fold#3(x2)) fold#3(Nil()) -> 0() main(x1) -> fold#3(x1) plus#2(0(),x12) -> x12 plus#2(S(x4),x2) -> S(plus#2(x4,x2)) - Signature: {fold#3/1,main/1,plus#2/2} / {0/0,Cons/2,Nil/0,S/1} - Obligation: innermost runtime complexity wrt. defined symbols {fold#3,main,plus#2} and constructors {0,Cons,Nil,S} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). WORST_CASE(Omega(n^1),O(n^1))