WORST_CASE(?,O(n^2)) * Step 1: DependencyPairs WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: div(0(),s(Y)) -> 0() div(s(X),s(Y)) -> s(div(minus(X,Y),s(Y))) minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1} / {0/0,s/1} - Obligation: innermost runtime complexity wrt. defined symbols {div,minus,p} and constructors {0,s} + Applied Processor: DependencyPairs {dpKind_ = DT} + Details: We add the following dependency tuples: Strict DPs div#(0(),s(Y)) -> c_1() div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(X,0()) -> c_3() minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) p#(s(X)) -> c_5() Weak DPs and mark the set of starting terms. * Step 2: PredecessorEstimation WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: div#(0(),s(Y)) -> c_1() div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(X,0()) -> c_3() minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) p#(s(X)) -> c_5() - Weak TRS: div(0(),s(Y)) -> 0() div(s(X),s(Y)) -> s(div(minus(X,Y),s(Y))) minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/2,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: PredecessorEstimation {onSelection = all simple predecessor estimation selector} + Details: We estimate the number of application of {1,3,5} by application of Pre({1,3,5}) = {2,4}. Here rules are labelled as follows: 1: div#(0(),s(Y)) -> c_1() 2: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) 3: minus#(X,0()) -> c_3() 4: minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) 5: p#(s(X)) -> c_5() * Step 3: RemoveWeakSuffixes WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) - Weak DPs: div#(0(),s(Y)) -> c_1() minus#(X,0()) -> c_3() p#(s(X)) -> c_5() - Weak TRS: div(0(),s(Y)) -> 0() div(s(X),s(Y)) -> s(div(minus(X,Y),s(Y))) minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/2,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) -->_2 minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)):2 -->_2 minus#(X,0()) -> c_3():4 -->_1 div#(0(),s(Y)) -> c_1():3 -->_1 div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)):1 2:S:minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) -->_1 p#(s(X)) -> c_5():5 -->_2 minus#(X,0()) -> c_3():4 -->_2 minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)):2 3:W:div#(0(),s(Y)) -> c_1() 4:W:minus#(X,0()) -> c_3() 5:W:p#(s(X)) -> c_5() The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 3: div#(0(),s(Y)) -> c_1() 4: minus#(X,0()) -> c_3() 5: p#(s(X)) -> c_5() * Step 4: SimplifyRHS WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) - Weak TRS: div(0(),s(Y)) -> 0() div(s(X),s(Y)) -> s(div(minus(X,Y),s(Y))) minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/2,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) -->_2 minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)):2 -->_1 div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)):1 2:S:minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)) -->_2 minus#(s(X),s(Y)) -> c_4(p#(minus(X,Y)),minus#(X,Y)):2 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) * Step 5: UsableRules WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) - Weak TRS: div(0(),s(Y)) -> 0() div(s(X),s(Y)) -> s(div(minus(X,Y),s(Y))) minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) * Step 6: DecomposeDG WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: DecomposeDG {onSelection = all below first cut in WDG, onUpper = Nothing, onLower = Nothing} + Details: We decompose the input problem according to the dependency graph into the upper component div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) and a lower component minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) Further, following extension rules are added to the lower component. div#(s(X),s(Y)) -> div#(minus(X,Y),s(Y)) div#(s(X),s(Y)) -> minus#(X,Y) ** Step 6.a:1: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)) -->_1 div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y)),minus#(X,Y)):1 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y))) ** Step 6.a:2: WeightGap WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y))) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/1,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following constant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(p) = {1}, uargs(div#) = {1}, uargs(c_2) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(0) = [2] p(div) = [1] x1 + [0] p(minus) = [1] x1 + [4] p(p) = [1] x1 + [0] p(s) = [1] x1 + [7] p(div#) = [1] x1 + [1] p(minus#) = [1] x1 + [1] x2 + [1] p(p#) = [1] x1 + [1] p(c_1) = [8] p(c_2) = [1] x1 + [2] p(c_3) = [1] p(c_4) = [2] x1 + [1] p(c_5) = [8] Following rules are strictly oriented: div#(s(X),s(Y)) = [1] X + [8] > [1] X + [7] = c_2(div#(minus(X,Y),s(Y))) Following rules are (at-least) weakly oriented: minus(X,0()) = [1] X + [4] >= [1] X + [0] = X minus(s(X),s(Y)) = [1] X + [11] >= [1] X + [4] = p(minus(X,Y)) p(s(X)) = [1] X + [7] >= [1] X + [0] = X Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 6.a:3: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: div#(s(X),s(Y)) -> c_2(div#(minus(X,Y),s(Y))) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/1,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). ** Step 6.b:1: WeightGap WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) - Weak DPs: div#(s(X),s(Y)) -> div#(minus(X,Y),s(Y)) div#(s(X),s(Y)) -> minus#(X,Y) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following constant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(p) = {1}, uargs(div#) = {1}, uargs(c_4) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(0) = [0] p(div) = [1] x1 + [1] x2 + [0] p(minus) = [1] x1 + [0] p(p) = [1] x1 + [1] p(s) = [1] x1 + [1] p(div#) = [1] x1 + [1] x2 + [0] p(minus#) = [1] x2 + [0] p(p#) = [1] x1 + [2] p(c_1) = [1] p(c_2) = [1] x1 + [1] x2 + [0] p(c_3) = [1] p(c_4) = [1] x1 + [0] p(c_5) = [2] Following rules are strictly oriented: minus#(s(X),s(Y)) = [1] Y + [1] > [1] Y + [0] = c_4(minus#(X,Y)) Following rules are (at-least) weakly oriented: div#(s(X),s(Y)) = [1] X + [1] Y + [2] >= [1] X + [1] Y + [1] = div#(minus(X,Y),s(Y)) div#(s(X),s(Y)) = [1] X + [1] Y + [2] >= [1] Y + [0] = minus#(X,Y) minus(X,0()) = [1] X + [0] >= [1] X + [0] = X minus(s(X),s(Y)) = [1] X + [1] >= [1] X + [1] = p(minus(X,Y)) p(s(X)) = [1] X + [2] >= [1] X + [0] = X Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 6.b:2: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: div#(s(X),s(Y)) -> div#(minus(X,Y),s(Y)) div#(s(X),s(Y)) -> minus#(X,Y) minus#(s(X),s(Y)) -> c_4(minus#(X,Y)) - Weak TRS: minus(X,0()) -> X minus(s(X),s(Y)) -> p(minus(X,Y)) p(s(X)) -> X - Signature: {div/2,minus/2,p/1,div#/2,minus#/2,p#/1} / {0/0,s/1,c_1/0,c_2/2,c_3/0,c_4/1,c_5/0} - Obligation: innermost runtime complexity wrt. defined symbols {div#,minus#,p#} and constructors {0,s} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). WORST_CASE(?,O(n^2))