883.94/291.44 WORST_CASE(Omega(n^1), O(n^2)) 884.02/291.45 proof of /export/starexec/sandbox2/benchmark/theBenchmark.xml 884.02/291.45 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 884.02/291.45 884.02/291.45 884.02/291.45 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^2). 884.02/291.45 884.02/291.45 (0) CpxTRS 884.02/291.45 (1) RelTrsToWeightedTrsProof [BOTH BOUNDS(ID, ID), 0 ms] 884.02/291.45 (2) CpxWeightedTrs 884.02/291.45 (3) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 884.02/291.45 (4) CpxTypedWeightedTrs 884.02/291.45 (5) CompletionProof [UPPER BOUND(ID), 0 ms] 884.02/291.45 (6) CpxTypedWeightedCompleteTrs 884.02/291.45 (7) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] 884.02/291.45 (8) CpxRNTS 884.02/291.45 (9) CompleteCoflocoProof [FINISHED, 319 ms] 884.02/291.45 (10) BOUNDS(1, n^2) 884.02/291.45 (11) RelTrsToDecreasingLoopProblemProof [LOWER BOUND(ID), 0 ms] 884.02/291.45 (12) TRS for Loop Detection 884.02/291.45 (13) DecreasingLoopProof [LOWER BOUND(ID), 0 ms] 884.02/291.45 (14) BEST 884.02/291.45 (15) proven lower bound 884.02/291.45 (16) LowerBoundPropagationProof [FINISHED, 0 ms] 884.02/291.45 (17) BOUNDS(n^1, INF) 884.02/291.45 (18) TRS for Loop Detection 884.02/291.45 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (0) 884.02/291.45 Obligation: 884.02/291.45 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^2). 884.02/291.45 884.02/291.45 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true 884.02/291.45 lt(x, 0) -> false 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) 884.02/291.45 fac(x) -> help(x, 0) 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) 884.02/291.45 if(false, x, c) -> s(0) 884.02/291.45 884.02/291.45 S is empty. 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (1) RelTrsToWeightedTrsProof (BOTH BOUNDS(ID, ID)) 884.02/291.45 Transformed relative TRS to weighted TRS 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (2) 884.02/291.45 Obligation: 884.02/291.45 The Runtime Complexity (innermost) of the given CpxWeightedTrs could be proven to be BOUNDS(1, n^2). 884.02/291.45 884.02/291.45 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true [1] 884.02/291.45 lt(x, 0) -> false [1] 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) [1] 884.02/291.45 fac(x) -> help(x, 0) [1] 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) [1] 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) [1] 884.02/291.45 if(false, x, c) -> s(0) [1] 884.02/291.45 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (3) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 884.02/291.45 Infered types. 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (4) 884.02/291.45 Obligation: 884.02/291.45 Runtime Complexity Weighted TRS with Types. 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true [1] 884.02/291.45 lt(x, 0) -> false [1] 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) [1] 884.02/291.45 fac(x) -> help(x, 0) [1] 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) [1] 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) [1] 884.02/291.45 if(false, x, c) -> s(0) [1] 884.02/291.45 884.02/291.45 The TRS has the following type information: 884.02/291.45 lt :: 0:s:times -> 0:s:times -> true:false 884.02/291.45 0 :: 0:s:times 884.02/291.45 s :: 0:s:times -> 0:s:times 884.02/291.45 true :: true:false 884.02/291.45 false :: true:false 884.02/291.45 fac :: 0:s:times -> 0:s:times 884.02/291.45 help :: 0:s:times -> 0:s:times -> 0:s:times 884.02/291.45 if :: true:false -> 0:s:times -> 0:s:times -> 0:s:times 884.02/291.45 times :: 0:s:times -> 0:s:times -> 0:s:times 884.02/291.45 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (5) CompletionProof (UPPER BOUND(ID)) 884.02/291.45 The TRS is a completely defined constructor system, as every type has a constant constructor and the following rules were added: 884.02/291.45 884.02/291.45 lt(v0, v1) -> null_lt [0] 884.02/291.45 if(v0, v1, v2) -> null_if [0] 884.02/291.45 884.02/291.45 And the following fresh constants: null_lt, null_if 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (6) 884.02/291.45 Obligation: 884.02/291.45 Runtime Complexity Weighted TRS where all functions are completely defined. The underlying TRS is: 884.02/291.45 884.02/291.45 Runtime Complexity Weighted TRS with Types. 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true [1] 884.02/291.45 lt(x, 0) -> false [1] 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) [1] 884.02/291.45 fac(x) -> help(x, 0) [1] 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) [1] 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) [1] 884.02/291.45 if(false, x, c) -> s(0) [1] 884.02/291.45 lt(v0, v1) -> null_lt [0] 884.02/291.45 if(v0, v1, v2) -> null_if [0] 884.02/291.45 884.02/291.45 The TRS has the following type information: 884.02/291.45 lt :: 0:s:times:null_if -> 0:s:times:null_if -> true:false:null_lt 884.02/291.45 0 :: 0:s:times:null_if 884.02/291.45 s :: 0:s:times:null_if -> 0:s:times:null_if 884.02/291.45 true :: true:false:null_lt 884.02/291.45 false :: true:false:null_lt 884.02/291.45 fac :: 0:s:times:null_if -> 0:s:times:null_if 884.02/291.45 help :: 0:s:times:null_if -> 0:s:times:null_if -> 0:s:times:null_if 884.02/291.45 if :: true:false:null_lt -> 0:s:times:null_if -> 0:s:times:null_if -> 0:s:times:null_if 884.02/291.45 times :: 0:s:times:null_if -> 0:s:times:null_if -> 0:s:times:null_if 884.02/291.45 null_lt :: true:false:null_lt 884.02/291.45 null_if :: 0:s:times:null_if 884.02/291.45 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (7) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) 884.02/291.45 Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. 884.02/291.45 The constant constructors are abstracted as follows: 884.02/291.45 884.02/291.45 0 => 0 884.02/291.45 true => 2 884.02/291.45 false => 1 884.02/291.45 null_lt => 0 884.02/291.45 null_if => 0 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (8) 884.02/291.45 Obligation: 884.02/291.45 Complexity RNTS consisting of the following rules: 884.02/291.45 884.02/291.45 fac(z) -{ 1 }-> help(x, 0) :|: x >= 0, z = x 884.02/291.45 help(z, z') -{ 1 }-> if(lt(c, x), x, c) :|: c >= 0, x >= 0, z' = c, z = x 884.02/291.45 if(z, z', z'') -{ 0 }-> 0 :|: v0 >= 0, z'' = v2, v1 >= 0, z = v0, z' = v1, v2 >= 0 884.02/291.45 if(z, z', z'') -{ 1 }-> 1 + 0 :|: z' = x, c >= 0, z = 1, x >= 0, z'' = c 884.02/291.45 if(z, z', z'') -{ 1 }-> 1 + (1 + c) + help(x, 1 + c) :|: z = 2, z' = x, c >= 0, x >= 0, z'' = c 884.02/291.45 lt(z, z') -{ 1 }-> lt(x, y) :|: z' = 1 + y, x >= 0, y >= 0, z = 1 + x 884.02/291.45 lt(z, z') -{ 1 }-> 2 :|: z' = 1 + x, x >= 0, z = 0 884.02/291.45 lt(z, z') -{ 1 }-> 1 :|: x >= 0, z = x, z' = 0 884.02/291.45 lt(z, z') -{ 0 }-> 0 :|: v0 >= 0, v1 >= 0, z = v0, z' = v1 884.02/291.45 884.02/291.45 Only complete derivations are relevant for the runtime complexity. 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (9) CompleteCoflocoProof (FINISHED) 884.02/291.45 Transformed the RNTS (where only complete derivations are relevant) into cost relations for CoFloCo: 884.02/291.45 884.02/291.45 eq(start(V1, V, V9),0,[lt(V1, V, Out)],[V1 >= 0,V >= 0]). 884.02/291.45 eq(start(V1, V, V9),0,[fac(V1, Out)],[V1 >= 0]). 884.02/291.45 eq(start(V1, V, V9),0,[help(V1, V, Out)],[V1 >= 0,V >= 0]). 884.02/291.45 eq(start(V1, V, V9),0,[if(V1, V, V9, Out)],[V1 >= 0,V >= 0,V9 >= 0]). 884.02/291.45 eq(lt(V1, V, Out),1,[],[Out = 2,V = 1 + V2,V2 >= 0,V1 = 0]). 884.02/291.45 eq(lt(V1, V, Out),1,[],[Out = 1,V3 >= 0,V1 = V3,V = 0]). 884.02/291.45 eq(lt(V1, V, Out),1,[lt(V4, V5, Ret)],[Out = Ret,V = 1 + V5,V4 >= 0,V5 >= 0,V1 = 1 + V4]). 884.02/291.45 eq(fac(V1, Out),1,[help(V6, 0, Ret1)],[Out = Ret1,V6 >= 0,V1 = V6]). 884.02/291.45 eq(help(V1, V, Out),1,[lt(V8, V7, Ret0),if(Ret0, V7, V8, Ret2)],[Out = Ret2,V8 >= 0,V7 >= 0,V = V8,V1 = V7]). 884.02/291.45 eq(if(V1, V, V9, Out),1,[help(V10, 1 + V11, Ret11)],[Out = 2 + Ret11 + V11,V1 = 2,V = V10,V11 >= 0,V10 >= 0,V9 = V11]). 884.02/291.45 eq(if(V1, V, V9, Out),1,[],[Out = 1,V = V13,V12 >= 0,V1 = 1,V13 >= 0,V9 = V12]). 884.02/291.45 eq(lt(V1, V, Out),0,[],[Out = 0,V15 >= 0,V14 >= 0,V1 = V15,V = V14]). 884.02/291.45 eq(if(V1, V, V9, Out),0,[],[Out = 0,V17 >= 0,V9 = V18,V16 >= 0,V1 = V17,V = V16,V18 >= 0]). 884.02/291.45 input_output_vars(lt(V1,V,Out),[V1,V],[Out]). 884.02/291.45 input_output_vars(fac(V1,Out),[V1],[Out]). 884.02/291.45 input_output_vars(help(V1,V,Out),[V1,V],[Out]). 884.02/291.45 input_output_vars(if(V1,V,V9,Out),[V1,V,V9],[Out]). 884.02/291.45 884.02/291.45 884.02/291.45 CoFloCo proof output: 884.02/291.45 Preprocessing Cost Relations 884.02/291.45 ===================================== 884.02/291.45 884.02/291.45 #### Computed strongly connected components 884.02/291.45 0. recursive : [lt/3] 884.02/291.45 1. recursive : [help/3,if/4] 884.02/291.45 2. non_recursive : [fac/2] 884.02/291.45 3. non_recursive : [start/3] 884.02/291.45 884.02/291.45 #### Obtained direct recursion through partial evaluation 884.02/291.45 0. SCC is partially evaluated into lt/3 884.02/291.45 1. SCC is partially evaluated into help/3 884.02/291.45 2. SCC is completely evaluated into other SCCs 884.02/291.45 3. SCC is partially evaluated into start/3 884.02/291.45 884.02/291.45 Control-Flow Refinement of Cost Relations 884.02/291.45 ===================================== 884.02/291.45 884.02/291.45 ### Specialization of cost equations lt/3 884.02/291.45 * CE 13 is refined into CE [14] 884.02/291.45 * CE 11 is refined into CE [15] 884.02/291.45 * CE 10 is refined into CE [16] 884.02/291.45 * CE 12 is refined into CE [17] 884.02/291.45 884.02/291.45 884.02/291.45 ### Cost equations --> "Loop" of lt/3 884.02/291.45 * CEs [17] --> Loop 10 884.02/291.45 * CEs [14] --> Loop 11 884.02/291.45 * CEs [15] --> Loop 12 884.02/291.45 * CEs [16] --> Loop 13 884.02/291.45 884.02/291.45 ### Ranking functions of CR lt(V1,V,Out) 884.02/291.45 * RF of phase [10]: [V,V1] 884.02/291.45 884.02/291.45 #### Partial ranking functions of CR lt(V1,V,Out) 884.02/291.45 * Partial RF of phase [10]: 884.02/291.45 - RF of loop [10:1]: 884.02/291.45 V 884.02/291.45 V1 884.02/291.45 884.02/291.45 884.02/291.45 ### Specialization of cost equations help/3 884.02/291.45 * CE 9 is refined into CE [18,19] 884.02/291.45 * CE 8 is refined into CE [20,21] 884.02/291.45 * CE 7 is refined into CE [22,23,24,25,26] 884.02/291.45 884.02/291.45 884.02/291.45 ### Cost equations --> "Loop" of help/3 884.02/291.45 * CEs [21] --> Loop 14 884.02/291.45 * CEs [22] --> Loop 15 884.02/291.45 * CEs [20] --> Loop 16 884.02/291.45 * CEs [23,24,25,26] --> Loop 17 884.02/291.45 * CEs [19] --> Loop 18 884.02/291.45 * CEs [18] --> Loop 19 884.02/291.45 884.02/291.45 ### Ranking functions of CR help(V1,V,Out) 884.02/291.45 * RF of phase [18]: [V1-V] 884.02/291.45 884.02/291.45 #### Partial ranking functions of CR help(V1,V,Out) 884.02/291.45 * Partial RF of phase [18]: 884.02/291.45 - RF of loop [18:1]: 884.02/291.45 V1-V 884.02/291.45 884.02/291.45 884.02/291.45 ### Specialization of cost equations start/3 884.02/291.45 * CE 3 is refined into CE [27,28,29,30] 884.02/291.45 * CE 1 is refined into CE [31] 884.02/291.45 * CE 2 is refined into CE [32] 884.02/291.45 * CE 4 is refined into CE [33,34,35,36,37] 884.02/291.45 * CE 5 is refined into CE [38,39,40,41,42] 884.02/291.45 * CE 6 is refined into CE [43,44,45,46,47,48,49] 884.02/291.45 884.02/291.45 884.02/291.45 ### Cost equations --> "Loop" of start/3 884.02/291.45 * CEs [34,46,47] --> Loop 20 884.02/291.45 * CEs [27,28,29,30] --> Loop 21 884.02/291.45 * CEs [32,39,44] --> Loop 22 884.02/291.45 * CEs [31,33,35,36,37,38,40,41,42,43,45,48,49] --> Loop 23 884.02/291.45 884.02/291.45 ### Ranking functions of CR start(V1,V,V9) 884.02/291.45 884.02/291.45 #### Partial ranking functions of CR start(V1,V,V9) 884.02/291.45 884.02/291.45 884.02/291.45 Computing Bounds 884.02/291.45 ===================================== 884.02/291.45 884.02/291.45 #### Cost of chains of lt(V1,V,Out): 884.02/291.45 * Chain [[10],13]: 1*it(10)+1 884.02/291.45 Such that:it(10) =< V1 884.02/291.45 884.02/291.45 with precondition: [Out=2,V1>=1,V>=V1+1] 884.02/291.45 884.02/291.45 * Chain [[10],12]: 1*it(10)+1 884.02/291.45 Such that:it(10) =< V 884.02/291.45 884.02/291.45 with precondition: [Out=1,V>=1,V1>=V] 884.02/291.45 884.02/291.45 * Chain [[10],11]: 1*it(10)+0 884.02/291.45 Such that:it(10) =< V 884.02/291.45 884.02/291.45 with precondition: [Out=0,V1>=1,V>=1] 884.02/291.45 884.02/291.45 * Chain [13]: 1 884.02/291.45 with precondition: [V1=0,Out=2,V>=1] 884.02/291.45 884.02/291.45 * Chain [12]: 1 884.02/291.45 with precondition: [V=0,Out=1,V1>=0] 884.02/291.45 884.02/291.45 * Chain [11]: 0 884.02/291.45 with precondition: [Out=0,V1>=0,V>=0] 884.02/291.45 884.02/291.45 884.02/291.45 #### Cost of chains of help(V1,V,Out): 884.02/291.45 * Chain [[18],17]: 3*it(18)+3*s(2)+1*s(7)+2 884.02/291.45 Such that:it(18) =< V1-V 884.02/291.45 aux(3) =< V1 884.02/291.45 s(2) =< aux(3) 884.02/291.45 s(7) =< it(18)*aux(3) 884.02/291.45 884.02/291.45 with precondition: [V>=1,V1>=V+1,Out>=V+2] 884.02/291.45 884.02/291.45 * Chain [[18],14]: 3*it(18)+1*s(7)+1*s(8)+3 884.02/291.45 Such that:it(18) =< V1-V 884.02/291.45 aux(4) =< V1 884.02/291.45 s(8) =< aux(4) 884.02/291.45 s(7) =< it(18)*aux(4) 884.02/291.45 884.02/291.45 with precondition: [V>=1,V1>=V+1,Out+3*V+1>=4*V1] 884.02/291.45 884.02/291.45 * Chain [19,[18],17]: 6*it(18)+1*s(7)+5 884.02/291.45 Such that:aux(5) =< V1 884.02/291.45 it(18) =< aux(5) 884.02/291.45 s(7) =< it(18)*aux(5) 884.02/291.45 884.02/291.45 with precondition: [V=0,V1>=2,Out>=5] 884.02/291.45 884.02/291.45 * Chain [19,[18],14]: 4*it(18)+1*s(7)+6 884.02/291.45 Such that:aux(6) =< V1 884.02/291.45 it(18) =< aux(6) 884.02/291.45 s(7) =< it(18)*aux(6) 884.02/291.45 884.02/291.45 with precondition: [V=0,V1>=2,Out+2>=4*V1] 884.02/291.45 884.02/291.45 * Chain [19,17]: 2*s(2)+1*s(4)+5 884.02/291.45 Such that:s(4) =< 1 884.02/291.45 aux(1) =< V1 884.02/291.45 s(2) =< aux(1) 884.02/291.45 884.02/291.45 with precondition: [V=0,Out=2,V1>=1] 884.02/291.45 884.02/291.45 * Chain [19,14]: 1*s(8)+6 884.02/291.45 Such that:s(8) =< 1 884.02/291.45 884.02/291.45 with precondition: [V1=1,V=0,Out=3] 884.02/291.45 884.02/291.45 * Chain [17]: 2*s(2)+1*s(4)+2 884.02/291.45 Such that:s(4) =< V 884.02/291.45 aux(1) =< V1 884.02/291.45 s(2) =< aux(1) 884.02/291.45 884.02/291.45 with precondition: [Out=0,V1>=0,V>=0] 884.02/291.45 884.02/291.45 * Chain [16]: 3 884.02/291.45 with precondition: [V1=0,Out=1,V>=0] 884.02/291.45 884.02/291.45 * Chain [15]: 2 884.02/291.45 with precondition: [V=0,Out=0,V1>=1] 884.02/291.45 884.02/291.45 * Chain [14]: 1*s(8)+3 884.02/291.45 Such that:s(8) =< V1 884.02/291.45 884.02/291.45 with precondition: [Out=1,V1>=1,V>=V1] 884.02/291.45 884.02/291.45 884.02/291.45 #### Cost of chains of start(V1,V,V9): 884.02/291.45 * Chain [23]: 3*s(26)+22*s(28)+1*s(32)+2*s(37)+6*s(44)+2*s(46)+7 884.02/291.45 Such that:s(32) =< 1 884.02/291.45 s(43) =< V1-V 884.02/291.45 aux(10) =< V1 884.02/291.45 aux(11) =< V 884.02/291.45 s(28) =< aux(10) 884.02/291.45 s(26) =< aux(11) 884.02/291.45 s(37) =< s(28)*aux(10) 884.02/291.45 s(44) =< s(43) 884.02/291.45 s(46) =< s(44)*aux(10) 884.02/291.45 884.02/291.45 with precondition: [V1>=0] 884.02/291.45 884.02/291.45 * Chain [22]: 9 884.02/291.45 with precondition: [V1=1] 884.02/291.45 884.02/291.45 * Chain [21]: 1*s(50)+7*s(51)+6*s(55)+2*s(57)+4 884.02/291.45 Such that:s(54) =< V-V9 884.02/291.45 s(50) =< V9+1 884.02/291.45 aux(13) =< V 884.02/291.45 s(51) =< aux(13) 884.02/291.45 s(55) =< s(54) 884.02/291.45 s(57) =< s(55)*aux(13) 884.02/291.45 884.02/291.45 with precondition: [V1=2,V>=0,V9>=0] 884.02/291.45 884.02/291.45 * Chain [20]: 1*s(58)+12*s(60)+2*s(63)+6 884.02/291.45 Such that:s(58) =< 1 884.02/291.45 aux(14) =< V1 884.02/291.45 s(60) =< aux(14) 884.02/291.45 s(63) =< s(60)*aux(14) 884.02/291.45 884.02/291.45 with precondition: [V=0,V1>=0] 884.02/291.45 884.02/291.45 884.02/291.45 Closed-form bounds of start(V1,V,V9): 884.02/291.45 ------------------------------------- 884.02/291.45 * Chain [23] with precondition: [V1>=0] 884.02/291.45 - Upper bound: 22*V1+8+2*V1*V1+2*V1*nat(V1-V)+nat(V)*3+nat(V1-V)*6 884.02/291.45 - Complexity: n^2 884.02/291.45 * Chain [22] with precondition: [V1=1] 884.02/291.45 - Upper bound: 9 884.02/291.45 - Complexity: constant 884.02/291.45 * Chain [21] with precondition: [V1=2,V>=0,V9>=0] 884.02/291.45 - Upper bound: 7*V+4+2*V*nat(V-V9)+(V9+1)+nat(V-V9)*6 884.02/291.45 - Complexity: n^2 884.02/291.45 * Chain [20] with precondition: [V=0,V1>=0] 884.02/291.45 - Upper bound: 12*V1+7+2*V1*V1 884.02/291.45 - Complexity: n^2 884.02/291.45 884.02/291.45 ### Maximum cost of start(V1,V,V9): max([max([5,nat(V)*2*nat(V-V9)+nat(V)*7+nat(V9+1)+nat(V-V9)*6]),10*V1+1+2*V1*nat(V1-V)+nat(V)*3+nat(V1-V)*6+(12*V1+3+2*V1*V1)])+4 884.02/291.45 Asymptotic class: n^2 884.02/291.45 * Total analysis performed in 246 ms. 884.02/291.45 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (10) 884.02/291.45 BOUNDS(1, n^2) 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (11) RelTrsToDecreasingLoopProblemProof (LOWER BOUND(ID)) 884.02/291.45 Transformed a relative TRS into a decreasing-loop problem. 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (12) 884.02/291.45 Obligation: 884.02/291.45 Analyzing the following TRS for decreasing loops: 884.02/291.45 884.02/291.45 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^2). 884.02/291.45 884.02/291.45 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true 884.02/291.45 lt(x, 0) -> false 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) 884.02/291.45 fac(x) -> help(x, 0) 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) 884.02/291.45 if(false, x, c) -> s(0) 884.02/291.45 884.02/291.45 S is empty. 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (13) DecreasingLoopProof (LOWER BOUND(ID)) 884.02/291.45 The following loop(s) give(s) rise to the lower bound Omega(n^1): 884.02/291.45 884.02/291.45 The rewrite sequence 884.02/291.45 884.02/291.45 lt(s(x), s(y)) ->^+ lt(x, y) 884.02/291.45 884.02/291.45 gives rise to a decreasing loop by considering the right hand sides subterm at position []. 884.02/291.45 884.02/291.45 The pumping substitution is [x / s(x), y / s(y)]. 884.02/291.45 884.02/291.45 The result substitution is [ ]. 884.02/291.45 884.02/291.45 884.02/291.45 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (14) 884.02/291.45 Complex Obligation (BEST) 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (15) 884.02/291.45 Obligation: 884.02/291.45 Proved the lower bound n^1 for the following obligation: 884.02/291.45 884.02/291.45 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^2). 884.02/291.45 884.02/291.45 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true 884.02/291.45 lt(x, 0) -> false 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) 884.02/291.45 fac(x) -> help(x, 0) 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) 884.02/291.45 if(false, x, c) -> s(0) 884.02/291.45 884.02/291.45 S is empty. 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (16) LowerBoundPropagationProof (FINISHED) 884.02/291.45 Propagated lower bound. 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (17) 884.02/291.45 BOUNDS(n^1, INF) 884.02/291.45 884.02/291.45 ---------------------------------------- 884.02/291.45 884.02/291.45 (18) 884.02/291.45 Obligation: 884.02/291.45 Analyzing the following TRS for decreasing loops: 884.02/291.45 884.02/291.45 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(n^1, n^2). 884.02/291.45 884.02/291.45 884.02/291.45 The TRS R consists of the following rules: 884.02/291.45 884.02/291.45 lt(0, s(x)) -> true 884.02/291.45 lt(x, 0) -> false 884.02/291.45 lt(s(x), s(y)) -> lt(x, y) 884.02/291.45 fac(x) -> help(x, 0) 884.02/291.45 help(x, c) -> if(lt(c, x), x, c) 884.02/291.45 if(true, x, c) -> times(s(c), help(x, s(c))) 884.02/291.45 if(false, x, c) -> s(0) 884.02/291.45 884.02/291.45 S is empty. 884.02/291.45 Rewrite Strategy: INNERMOST 884.02/291.49 EOF