21.47/6.39 WORST_CASE(Omega(n^1), O(n^1)) 21.83/6.40 proof of /export/starexec/sandbox2/benchmark/theBenchmark.xml 21.83/6.40 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 21.83/6.40 21.83/6.40 21.83/6.40 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^1). 21.83/6.40 21.83/6.40 (0) CpxTRS 21.83/6.40 (1) RelTrsToWeightedTrsProof [BOTH BOUNDS(ID, ID), 0 ms] 21.83/6.40 (2) CpxWeightedTrs 21.83/6.40 (3) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 21.83/6.40 (4) CpxTypedWeightedTrs 21.83/6.40 (5) CompletionProof [UPPER BOUND(ID), 0 ms] 21.83/6.40 (6) CpxTypedWeightedCompleteTrs 21.83/6.40 (7) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] 21.83/6.40 (8) CpxRNTS 21.83/6.40 (9) CompleteCoflocoProof [FINISHED, 284 ms] 21.83/6.40 (10) BOUNDS(1, n^1) 21.83/6.40 (11) RenamingProof [BOTH BOUNDS(ID, ID), 0 ms] 21.83/6.40 (12) CpxTRS 21.83/6.40 (13) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 21.83/6.40 (14) typed CpxTrs 21.83/6.40 (15) OrderProof [LOWER BOUND(ID), 0 ms] 21.83/6.40 (16) typed CpxTrs 21.83/6.40 (17) RewriteLemmaProof [LOWER BOUND(ID), 1101 ms] 21.83/6.40 (18) BEST 21.83/6.40 (19) proven lower bound 21.83/6.40 (20) LowerBoundPropagationProof [FINISHED, 0 ms] 21.83/6.40 (21) BOUNDS(n^1, INF) 21.83/6.40 (22) typed CpxTrs 21.83/6.40 (23) RewriteLemmaProof [LOWER BOUND(ID), 6 ms] 21.83/6.40 (24) BOUNDS(1, INF) 21.83/6.40 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (0) 21.83/6.40 Obligation: 21.83/6.40 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^1). 21.83/6.40 21.83/6.40 21.83/6.40 The TRS R consists of the following rules: 21.83/6.40 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0) -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0, s(y)) -> 0 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 S is empty. 21.83/6.40 Rewrite Strategy: INNERMOST 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (1) RelTrsToWeightedTrsProof (BOTH BOUNDS(ID, ID)) 21.83/6.40 Transformed relative TRS to weighted TRS 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (2) 21.83/6.40 Obligation: 21.83/6.40 The Runtime Complexity (innermost) of the given CpxWeightedTrs could be proven to be BOUNDS(1, n^1). 21.83/6.40 21.83/6.40 21.83/6.40 The TRS R consists of the following rules: 21.83/6.40 21.83/6.40 pred(s(x)) -> x [1] 21.83/6.40 minus(x, 0) -> x [1] 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) [1] 21.83/6.40 quot(0, s(y)) -> 0 [1] 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) [1] 21.83/6.40 21.83/6.40 Rewrite Strategy: INNERMOST 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (3) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 21.83/6.40 Infered types. 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (4) 21.83/6.40 Obligation: 21.83/6.40 Runtime Complexity Weighted TRS with Types. 21.83/6.40 The TRS R consists of the following rules: 21.83/6.40 21.83/6.40 pred(s(x)) -> x [1] 21.83/6.40 minus(x, 0) -> x [1] 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) [1] 21.83/6.40 quot(0, s(y)) -> 0 [1] 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) [1] 21.83/6.40 21.83/6.40 The TRS has the following type information: 21.83/6.40 pred :: s:0 -> s:0 21.83/6.40 s :: s:0 -> s:0 21.83/6.40 minus :: s:0 -> s:0 -> s:0 21.83/6.40 0 :: s:0 21.83/6.40 quot :: s:0 -> s:0 -> s:0 21.83/6.40 21.83/6.40 Rewrite Strategy: INNERMOST 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (5) CompletionProof (UPPER BOUND(ID)) 21.83/6.40 The TRS is a completely defined constructor system, as every type has a constant constructor and the following rules were added: 21.83/6.40 21.83/6.40 pred(v0) -> null_pred [0] 21.83/6.40 quot(v0, v1) -> null_quot [0] 21.83/6.40 minus(v0, v1) -> null_minus [0] 21.83/6.40 21.83/6.40 And the following fresh constants: null_pred, null_quot, null_minus 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (6) 21.83/6.40 Obligation: 21.83/6.40 Runtime Complexity Weighted TRS where all functions are completely defined. The underlying TRS is: 21.83/6.40 21.83/6.40 Runtime Complexity Weighted TRS with Types. 21.83/6.40 The TRS R consists of the following rules: 21.83/6.40 21.83/6.40 pred(s(x)) -> x [1] 21.83/6.40 minus(x, 0) -> x [1] 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) [1] 21.83/6.40 quot(0, s(y)) -> 0 [1] 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) [1] 21.83/6.40 pred(v0) -> null_pred [0] 21.83/6.40 quot(v0, v1) -> null_quot [0] 21.83/6.40 minus(v0, v1) -> null_minus [0] 21.83/6.40 21.83/6.40 The TRS has the following type information: 21.83/6.40 pred :: s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus 21.83/6.40 s :: s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus 21.83/6.40 minus :: s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus 21.83/6.40 0 :: s:0:null_pred:null_quot:null_minus 21.83/6.40 quot :: s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus -> s:0:null_pred:null_quot:null_minus 21.83/6.40 null_pred :: s:0:null_pred:null_quot:null_minus 21.83/6.40 null_quot :: s:0:null_pred:null_quot:null_minus 21.83/6.40 null_minus :: s:0:null_pred:null_quot:null_minus 21.83/6.40 21.83/6.40 Rewrite Strategy: INNERMOST 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (7) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) 21.83/6.40 Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. 21.83/6.40 The constant constructors are abstracted as follows: 21.83/6.40 21.83/6.40 0 => 0 21.83/6.40 null_pred => 0 21.83/6.40 null_quot => 0 21.83/6.40 null_minus => 0 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (8) 21.83/6.40 Obligation: 21.83/6.40 Complexity RNTS consisting of the following rules: 21.83/6.40 21.83/6.40 minus(z, z') -{ 1 }-> x :|: x >= 0, z = x, z' = 0 21.83/6.40 minus(z, z') -{ 1 }-> pred(minus(x, y)) :|: z' = 1 + y, x >= 0, y >= 0, z = x 21.83/6.40 minus(z, z') -{ 0 }-> 0 :|: v0 >= 0, v1 >= 0, z = v0, z' = v1 21.83/6.40 pred(z) -{ 1 }-> x :|: x >= 0, z = 1 + x 21.83/6.40 pred(z) -{ 0 }-> 0 :|: v0 >= 0, z = v0 21.83/6.40 quot(z, z') -{ 1 }-> 0 :|: z' = 1 + y, y >= 0, z = 0 21.83/6.40 quot(z, z') -{ 0 }-> 0 :|: v0 >= 0, v1 >= 0, z = v0, z' = v1 21.83/6.40 quot(z, z') -{ 1 }-> 1 + quot(minus(x, y), 1 + y) :|: z' = 1 + y, x >= 0, y >= 0, z = 1 + x 21.83/6.40 21.83/6.40 Only complete derivations are relevant for the runtime complexity. 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (9) CompleteCoflocoProof (FINISHED) 21.83/6.40 Transformed the RNTS (where only complete derivations are relevant) into cost relations for CoFloCo: 21.83/6.40 21.83/6.40 eq(start(V, V2),0,[pred(V, Out)],[V >= 0]). 21.83/6.40 eq(start(V, V2),0,[minus(V, V2, Out)],[V >= 0,V2 >= 0]). 21.83/6.40 eq(start(V, V2),0,[quot(V, V2, Out)],[V >= 0,V2 >= 0]). 21.83/6.40 eq(pred(V, Out),1,[],[Out = V1,V1 >= 0,V = 1 + V1]). 21.83/6.40 eq(minus(V, V2, Out),1,[],[Out = V3,V3 >= 0,V = V3,V2 = 0]). 21.83/6.40 eq(minus(V, V2, Out),1,[minus(V4, V5, Ret0),pred(Ret0, Ret)],[Out = Ret,V2 = 1 + V5,V4 >= 0,V5 >= 0,V = V4]). 21.83/6.40 eq(quot(V, V2, Out),1,[],[Out = 0,V2 = 1 + V6,V6 >= 0,V = 0]). 21.83/6.40 eq(quot(V, V2, Out),1,[minus(V7, V8, Ret10),quot(Ret10, 1 + V8, Ret1)],[Out = 1 + Ret1,V2 = 1 + V8,V7 >= 0,V8 >= 0,V = 1 + V7]). 21.83/6.40 eq(pred(V, Out),0,[],[Out = 0,V9 >= 0,V = V9]). 21.83/6.40 eq(quot(V, V2, Out),0,[],[Out = 0,V11 >= 0,V10 >= 0,V = V11,V2 = V10]). 21.83/6.40 eq(minus(V, V2, Out),0,[],[Out = 0,V13 >= 0,V12 >= 0,V = V13,V2 = V12]). 21.83/6.40 input_output_vars(pred(V,Out),[V],[Out]). 21.83/6.40 input_output_vars(minus(V,V2,Out),[V,V2],[Out]). 21.83/6.40 input_output_vars(quot(V,V2,Out),[V,V2],[Out]). 21.83/6.40 21.83/6.40 21.83/6.40 CoFloCo proof output: 21.83/6.40 Preprocessing Cost Relations 21.83/6.40 ===================================== 21.83/6.40 21.83/6.40 #### Computed strongly connected components 21.83/6.40 0. non_recursive : [pred/2] 21.83/6.40 1. recursive [non_tail] : [minus/3] 21.83/6.40 2. recursive : [quot/3] 21.83/6.40 3. non_recursive : [start/2] 21.83/6.40 21.83/6.40 #### Obtained direct recursion through partial evaluation 21.83/6.40 0. SCC is partially evaluated into pred/2 21.83/6.40 1. SCC is partially evaluated into minus/3 21.83/6.40 2. SCC is partially evaluated into quot/3 21.83/6.40 3. SCC is partially evaluated into start/2 21.83/6.40 21.83/6.40 Control-Flow Refinement of Cost Relations 21.83/6.40 ===================================== 21.83/6.40 21.83/6.40 ### Specialization of cost equations pred/2 21.83/6.40 * CE 4 is refined into CE [12] 21.83/6.40 * CE 5 is refined into CE [13] 21.83/6.40 21.83/6.40 21.83/6.40 ### Cost equations --> "Loop" of pred/2 21.83/6.40 * CEs [12] --> Loop 9 21.83/6.40 * CEs [13] --> Loop 10 21.83/6.40 21.83/6.40 ### Ranking functions of CR pred(V,Out) 21.83/6.40 21.83/6.40 #### Partial ranking functions of CR pred(V,Out) 21.83/6.40 21.83/6.40 21.83/6.40 ### Specialization of cost equations minus/3 21.83/6.40 * CE 8 is refined into CE [14] 21.83/6.40 * CE 6 is refined into CE [15] 21.83/6.40 * CE 7 is refined into CE [16,17] 21.83/6.40 21.83/6.40 21.83/6.40 ### Cost equations --> "Loop" of minus/3 21.83/6.40 * CEs [17] --> Loop 11 21.83/6.40 * CEs [16] --> Loop 12 21.83/6.40 * CEs [14] --> Loop 13 21.83/6.40 * CEs [15] --> Loop 14 21.83/6.40 21.83/6.40 ### Ranking functions of CR minus(V,V2,Out) 21.83/6.40 * RF of phase [11]: [V2] 21.83/6.40 * RF of phase [12]: [V2] 21.83/6.40 21.83/6.40 #### Partial ranking functions of CR minus(V,V2,Out) 21.83/6.40 * Partial RF of phase [11]: 21.83/6.40 - RF of loop [11:1]: 21.83/6.40 V2 21.83/6.40 * Partial RF of phase [12]: 21.83/6.40 - RF of loop [12:1]: 21.83/6.40 V2 21.83/6.40 21.83/6.40 21.83/6.40 ### Specialization of cost equations quot/3 21.83/6.40 * CE 9 is refined into CE [18] 21.83/6.40 * CE 11 is refined into CE [19] 21.83/6.40 * CE 10 is refined into CE [20,21,22] 21.83/6.40 21.83/6.40 21.83/6.40 ### Cost equations --> "Loop" of quot/3 21.83/6.40 * CEs [22] --> Loop 15 21.83/6.40 * CEs [21] --> Loop 16 21.83/6.40 * CEs [20] --> Loop 17 21.83/6.40 * CEs [18,19] --> Loop 18 21.83/6.40 21.83/6.40 ### Ranking functions of CR quot(V,V2,Out) 21.83/6.40 * RF of phase [15]: [V-1,V-V2+1] 21.83/6.40 * RF of phase [17]: [V] 21.83/6.40 21.83/6.40 #### Partial ranking functions of CR quot(V,V2,Out) 21.83/6.40 * Partial RF of phase [15]: 21.83/6.40 - RF of loop [15:1]: 21.83/6.40 V-1 21.83/6.40 V-V2+1 21.83/6.40 * Partial RF of phase [17]: 21.83/6.40 - RF of loop [17:1]: 21.83/6.40 V 21.83/6.40 21.83/6.40 21.83/6.40 ### Specialization of cost equations start/2 21.83/6.40 * CE 1 is refined into CE [23,24] 21.83/6.40 * CE 2 is refined into CE [25,26,27] 21.83/6.40 * CE 3 is refined into CE [28,29,30,31,32] 21.83/6.40 21.83/6.40 21.83/6.40 ### Cost equations --> "Loop" of start/2 21.83/6.40 * CEs [28] --> Loop 19 21.83/6.40 * CEs [23,24,25,26,27,29,30,31,32] --> Loop 20 21.83/6.40 21.83/6.40 ### Ranking functions of CR start(V,V2) 21.83/6.40 21.83/6.40 #### Partial ranking functions of CR start(V,V2) 21.83/6.40 21.83/6.40 21.83/6.40 Computing Bounds 21.83/6.40 ===================================== 21.83/6.40 21.83/6.40 #### Cost of chains of pred(V,Out): 21.83/6.40 * Chain [10]: 0 21.83/6.40 with precondition: [Out=0,V>=0] 21.83/6.40 21.83/6.40 * Chain [9]: 1 21.83/6.40 with precondition: [V=Out+1,V>=1] 21.83/6.40 21.83/6.40 21.83/6.40 #### Cost of chains of minus(V,V2,Out): 21.83/6.40 * Chain [[12],[11],14]: 3*it(11)+1 21.83/6.40 Such that:aux(1) =< V2 21.83/6.40 it(11) =< aux(1) 21.83/6.40 21.83/6.40 with precondition: [Out=0,V>=1,V2>=2] 21.83/6.40 21.83/6.40 * Chain [[12],14]: 1*it(12)+1 21.83/6.40 Such that:it(12) =< V2 21.83/6.40 21.83/6.40 with precondition: [Out=0,V>=0,V2>=1] 21.83/6.40 21.83/6.40 * Chain [[12],13]: 1*it(12)+0 21.83/6.40 Such that:it(12) =< V2 21.83/6.40 21.83/6.40 with precondition: [Out=0,V>=0,V2>=1] 21.83/6.40 21.83/6.40 * Chain [[11],14]: 2*it(11)+1 21.83/6.40 Such that:it(11) =< V2 21.83/6.40 21.83/6.40 with precondition: [V=Out+V2,V2>=1,V>=V2] 21.83/6.40 21.83/6.40 * Chain [14]: 1 21.83/6.40 with precondition: [V2=0,V=Out,V>=0] 21.83/6.40 21.83/6.40 * Chain [13]: 0 21.83/6.40 with precondition: [Out=0,V>=0,V2>=0] 21.83/6.40 21.83/6.40 21.83/6.40 #### Cost of chains of quot(V,V2,Out): 21.83/6.40 * Chain [[17],18]: 2*it(17)+1 21.83/6.40 Such that:it(17) =< Out 21.83/6.40 21.83/6.40 with precondition: [V2=1,Out>=1,V>=Out] 21.83/6.40 21.83/6.40 * Chain [[17],16,18]: 2*it(17)+5*s(6)+3 21.83/6.40 Such that:s(5) =< 1 21.83/6.40 it(17) =< Out 21.83/6.40 s(6) =< s(5) 21.83/6.40 21.83/6.40 with precondition: [V2=1,Out>=2,V>=Out] 21.83/6.40 21.83/6.40 * Chain [[15],18]: 2*it(15)+2*s(9)+1 21.83/6.40 Such that:it(15) =< V-V2+1 21.83/6.40 aux(5) =< V 21.83/6.40 it(15) =< aux(5) 21.83/6.40 s(9) =< aux(5) 21.83/6.40 21.83/6.40 with precondition: [V2>=2,Out>=1,V+2>=2*Out+V2] 21.83/6.40 21.83/6.40 * Chain [[15],16,18]: 2*it(15)+5*s(6)+2*s(9)+3 21.83/6.40 Such that:it(15) =< V-V2+1 21.83/6.40 s(5) =< V2 21.83/6.40 aux(6) =< V 21.83/6.40 s(6) =< s(5) 21.83/6.40 it(15) =< aux(6) 21.83/6.40 s(9) =< aux(6) 21.83/6.40 21.83/6.40 with precondition: [V2>=2,Out>=2,V+3>=2*Out+V2] 21.83/6.40 21.83/6.40 * Chain [18]: 1 21.83/6.40 with precondition: [Out=0,V>=0,V2>=0] 21.83/6.40 21.83/6.40 * Chain [16,18]: 5*s(6)+3 21.83/6.40 Such that:s(5) =< V2 21.83/6.40 s(6) =< s(5) 21.83/6.40 21.83/6.40 with precondition: [Out=1,V>=1,V2>=1] 21.83/6.40 21.83/6.40 21.83/6.40 #### Cost of chains of start(V,V2): 21.83/6.40 * Chain [20]: 17*s(15)+4*s(19)+4*s(21)+3 21.83/6.40 Such that:aux(8) =< V 21.83/6.40 aux(9) =< V-V2+1 21.83/6.40 aux(10) =< V2 21.83/6.40 s(19) =< aux(9) 21.83/6.40 s(15) =< aux(10) 21.83/6.40 s(19) =< aux(8) 21.83/6.40 s(21) =< aux(8) 21.83/6.40 21.83/6.40 with precondition: [V>=0] 21.83/6.40 21.83/6.40 * Chain [19]: 4*s(29)+5*s(30)+3 21.83/6.40 Such that:s(27) =< 1 21.83/6.40 s(28) =< V 21.83/6.40 s(29) =< s(28) 21.83/6.40 s(30) =< s(27) 21.83/6.40 21.83/6.40 with precondition: [V2=1,V>=1] 21.83/6.40 21.83/6.40 21.83/6.40 Closed-form bounds of start(V,V2): 21.83/6.40 ------------------------------------- 21.83/6.40 * Chain [20] with precondition: [V>=0] 21.83/6.40 - Upper bound: 4*V+3+nat(V2)*17+nat(V-V2+1)*4 21.83/6.40 - Complexity: n 21.83/6.40 * Chain [19] with precondition: [V2=1,V>=1] 21.83/6.40 - Upper bound: 4*V+8 21.83/6.40 - Complexity: n 21.83/6.40 21.83/6.40 ### Maximum cost of start(V,V2): 4*V+3+max([5,nat(V-V2+1)*4+nat(V2)*17]) 21.83/6.40 Asymptotic class: n 21.83/6.40 * Total analysis performed in 201 ms. 21.83/6.40 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (10) 21.83/6.40 BOUNDS(1, n^1) 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (11) RenamingProof (BOTH BOUNDS(ID, ID)) 21.83/6.40 Renamed function symbols to avoid clashes with predefined symbol. 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (12) 21.83/6.40 Obligation: 21.83/6.40 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, INF). 21.83/6.40 21.83/6.40 21.83/6.40 The TRS R consists of the following rules: 21.83/6.40 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0') -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0', s(y)) -> 0' 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 S is empty. 21.83/6.40 Rewrite Strategy: INNERMOST 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (13) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 21.83/6.40 Infered types. 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (14) 21.83/6.40 Obligation: 21.83/6.40 Innermost TRS: 21.83/6.40 Rules: 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0') -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0', s(y)) -> 0' 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 Types: 21.83/6.40 pred :: s:0' -> s:0' 21.83/6.40 s :: s:0' -> s:0' 21.83/6.40 minus :: s:0' -> s:0' -> s:0' 21.83/6.40 0' :: s:0' 21.83/6.40 quot :: s:0' -> s:0' -> s:0' 21.83/6.40 hole_s:0'1_0 :: s:0' 21.83/6.40 gen_s:0'2_0 :: Nat -> s:0' 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (15) OrderProof (LOWER BOUND(ID)) 21.83/6.40 Heuristically decided to analyse the following defined symbols: 21.83/6.40 minus, quot 21.83/6.40 21.83/6.40 They will be analysed ascendingly in the following order: 21.83/6.40 minus < quot 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (16) 21.83/6.40 Obligation: 21.83/6.40 Innermost TRS: 21.83/6.40 Rules: 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0') -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0', s(y)) -> 0' 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 Types: 21.83/6.40 pred :: s:0' -> s:0' 21.83/6.40 s :: s:0' -> s:0' 21.83/6.40 minus :: s:0' -> s:0' -> s:0' 21.83/6.40 0' :: s:0' 21.83/6.40 quot :: s:0' -> s:0' -> s:0' 21.83/6.40 hole_s:0'1_0 :: s:0' 21.83/6.40 gen_s:0'2_0 :: Nat -> s:0' 21.83/6.40 21.83/6.40 21.83/6.40 Generator Equations: 21.83/6.40 gen_s:0'2_0(0) <=> 0' 21.83/6.40 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 21.83/6.40 21.83/6.40 21.83/6.40 The following defined symbols remain to be analysed: 21.83/6.40 minus, quot 21.83/6.40 21.83/6.40 They will be analysed ascendingly in the following order: 21.83/6.40 minus < quot 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (17) RewriteLemmaProof (LOWER BOUND(ID)) 21.83/6.40 Proved the following rewrite lemma: 21.83/6.40 minus(gen_s:0'2_0(a), gen_s:0'2_0(+(1, n4_0))) -> *3_0, rt in Omega(n4_0) 21.83/6.40 21.83/6.40 Induction Base: 21.83/6.40 minus(gen_s:0'2_0(a), gen_s:0'2_0(+(1, 0))) 21.83/6.40 21.83/6.40 Induction Step: 21.83/6.40 minus(gen_s:0'2_0(a), gen_s:0'2_0(+(1, +(n4_0, 1)))) ->_R^Omega(1) 21.83/6.40 pred(minus(gen_s:0'2_0(a), gen_s:0'2_0(+(1, n4_0)))) ->_IH 21.83/6.40 pred(*3_0) 21.83/6.40 21.83/6.40 We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (18) 21.83/6.40 Complex Obligation (BEST) 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (19) 21.83/6.40 Obligation: 21.83/6.40 Proved the lower bound n^1 for the following obligation: 21.83/6.40 21.83/6.40 Innermost TRS: 21.83/6.40 Rules: 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0') -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0', s(y)) -> 0' 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 Types: 21.83/6.40 pred :: s:0' -> s:0' 21.83/6.40 s :: s:0' -> s:0' 21.83/6.40 minus :: s:0' -> s:0' -> s:0' 21.83/6.40 0' :: s:0' 21.83/6.40 quot :: s:0' -> s:0' -> s:0' 21.83/6.40 hole_s:0'1_0 :: s:0' 21.83/6.40 gen_s:0'2_0 :: Nat -> s:0' 21.83/6.40 21.83/6.40 21.83/6.40 Generator Equations: 21.83/6.40 gen_s:0'2_0(0) <=> 0' 21.83/6.40 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 21.83/6.40 21.83/6.40 21.83/6.40 The following defined symbols remain to be analysed: 21.83/6.40 minus, quot 21.83/6.40 21.83/6.40 They will be analysed ascendingly in the following order: 21.83/6.40 minus < quot 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (20) LowerBoundPropagationProof (FINISHED) 21.83/6.40 Propagated lower bound. 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (21) 21.83/6.40 BOUNDS(n^1, INF) 21.83/6.40 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (22) 21.83/6.40 Obligation: 21.83/6.40 Innermost TRS: 21.83/6.40 Rules: 21.83/6.40 pred(s(x)) -> x 21.83/6.40 minus(x, 0') -> x 21.83/6.40 minus(x, s(y)) -> pred(minus(x, y)) 21.83/6.40 quot(0', s(y)) -> 0' 21.83/6.40 quot(s(x), s(y)) -> s(quot(minus(x, y), s(y))) 21.83/6.40 21.83/6.40 Types: 21.83/6.40 pred :: s:0' -> s:0' 21.83/6.40 s :: s:0' -> s:0' 21.83/6.40 minus :: s:0' -> s:0' -> s:0' 21.83/6.40 0' :: s:0' 21.83/6.40 quot :: s:0' -> s:0' -> s:0' 21.83/6.40 hole_s:0'1_0 :: s:0' 21.83/6.40 gen_s:0'2_0 :: Nat -> s:0' 21.83/6.40 21.83/6.40 21.83/6.40 Lemmas: 21.83/6.40 minus(gen_s:0'2_0(a), gen_s:0'2_0(+(1, n4_0))) -> *3_0, rt in Omega(n4_0) 21.83/6.40 21.83/6.40 21.83/6.40 Generator Equations: 21.83/6.40 gen_s:0'2_0(0) <=> 0' 21.83/6.40 gen_s:0'2_0(+(x, 1)) <=> s(gen_s:0'2_0(x)) 21.83/6.40 21.83/6.40 21.83/6.40 The following defined symbols remain to be analysed: 21.83/6.40 quot 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (23) RewriteLemmaProof (LOWER BOUND(ID)) 21.83/6.40 Proved the following rewrite lemma: 21.83/6.40 quot(gen_s:0'2_0(n2293_0), gen_s:0'2_0(1)) -> gen_s:0'2_0(n2293_0), rt in Omega(1 + n2293_0) 21.83/6.40 21.83/6.40 Induction Base: 21.83/6.40 quot(gen_s:0'2_0(0), gen_s:0'2_0(1)) ->_R^Omega(1) 21.83/6.40 0' 21.83/6.40 21.83/6.40 Induction Step: 21.83/6.40 quot(gen_s:0'2_0(+(n2293_0, 1)), gen_s:0'2_0(1)) ->_R^Omega(1) 21.83/6.40 s(quot(minus(gen_s:0'2_0(n2293_0), gen_s:0'2_0(0)), s(gen_s:0'2_0(0)))) ->_R^Omega(1) 21.83/6.40 s(quot(gen_s:0'2_0(n2293_0), s(gen_s:0'2_0(0)))) ->_IH 21.83/6.40 s(gen_s:0'2_0(c2294_0)) 21.83/6.40 21.83/6.40 We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). 21.83/6.40 ---------------------------------------- 21.83/6.40 21.83/6.40 (24) 21.83/6.40 BOUNDS(1, INF) 22.51/10.67 EOF