323.64/291.49 WORST_CASE(Omega(n^2), O(n^3)) 323.73/291.51 proof of /export/starexec/sandbox2/benchmark/theBenchmark.xml 323.73/291.51 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 323.73/291.51 323.73/291.51 323.73/291.51 The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^2, n^3). 323.73/291.51 323.73/291.51 (0) CpxTRS 323.73/291.51 (1) RcToIrcProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (2) CpxTRS 323.73/291.51 (3) RelTrsToWeightedTrsProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (4) CpxWeightedTrs 323.73/291.51 (5) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (6) CpxTypedWeightedTrs 323.73/291.51 (7) CompletionProof [UPPER BOUND(ID), 3 ms] 323.73/291.51 (8) CpxTypedWeightedCompleteTrs 323.73/291.51 (9) NarrowingProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (10) CpxTypedWeightedCompleteTrs 323.73/291.51 (11) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] 323.73/291.51 (12) CpxRNTS 323.73/291.51 (13) SimplificationProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (14) CpxRNTS 323.73/291.51 (15) CpxRntsAnalysisOrderProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (16) CpxRNTS 323.73/291.51 (17) ResultPropagationProof [UPPER BOUND(ID), 0 ms] 323.73/291.51 (18) CpxRNTS 323.73/291.51 (19) IntTrsBoundProof [UPPER BOUND(ID), 611 ms] 323.73/291.51 (20) CpxRNTS 323.73/291.51 (21) IntTrsBoundProof [UPPER BOUND(ID), 190 ms] 323.73/291.51 (22) CpxRNTS 323.73/291.51 (23) ResultPropagationProof [UPPER BOUND(ID), 0 ms] 323.73/291.51 (24) CpxRNTS 323.73/291.51 (25) IntTrsBoundProof [UPPER BOUND(ID), 606 ms] 323.73/291.51 (26) CpxRNTS 323.73/291.51 (27) IntTrsBoundProof [UPPER BOUND(ID), 0 ms] 323.73/291.51 (28) CpxRNTS 323.73/291.51 (29) FinalProof [FINISHED, 0 ms] 323.73/291.51 (30) BOUNDS(1, n^3) 323.73/291.51 (31) RenamingProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (32) CpxTRS 323.73/291.51 (33) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] 323.73/291.51 (34) typed CpxTrs 323.73/291.51 (35) OrderProof [LOWER BOUND(ID), 0 ms] 323.73/291.51 (36) typed CpxTrs 323.73/291.51 (37) RewriteLemmaProof [LOWER BOUND(ID), 290 ms] 323.73/291.51 (38) BEST 323.73/291.51 (39) proven lower bound 323.73/291.51 (40) LowerBoundPropagationProof [FINISHED, 0 ms] 323.73/291.51 (41) BOUNDS(n^1, INF) 323.73/291.51 (42) typed CpxTrs 323.73/291.51 (43) RewriteLemmaProof [LOWER BOUND(ID), 58 ms] 323.73/291.51 (44) proven lower bound 323.73/291.51 (45) LowerBoundPropagationProof [FINISHED, 0 ms] 323.73/291.51 (46) BOUNDS(n^2, INF) 323.73/291.51 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (0) 323.73/291.51 Obligation: 323.73/291.51 The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^2, n^3). 323.73/291.51 323.73/291.51 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0) -> x 323.73/291.51 plus(0, x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 S is empty. 323.73/291.51 Rewrite Strategy: FULL 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (1) RcToIrcProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Converted rc-obligation to irc-obligation. 323.73/291.51 323.73/291.51 The duplicating contexts are: 323.73/291.51 times([], s(y)) 323.73/291.51 323.73/291.51 323.73/291.51 The defined contexts are: 323.73/291.51 plus([], x1) 323.73/291.51 323.73/291.51 323.73/291.51 As the TRS is an overlay system and the defined contexts and the duplicating contexts don't overlap, we have rc = irc. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (2) 323.73/291.51 Obligation: 323.73/291.51 The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(1, n^3). 323.73/291.51 323.73/291.51 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0) -> x 323.73/291.51 plus(0, x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 S is empty. 323.73/291.51 Rewrite Strategy: INNERMOST 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (3) RelTrsToWeightedTrsProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Transformed relative TRS to weighted TRS 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (4) 323.73/291.51 Obligation: 323.73/291.51 The Runtime Complexity (innermost) of the given CpxWeightedTrs could be proven to be BOUNDS(1, n^3). 323.73/291.51 323.73/291.51 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 [1] 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) [1] 323.73/291.51 plus(x, 0) -> x [1] 323.73/291.51 plus(0, x) -> x [1] 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) [1] 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) [1] 323.73/291.51 323.73/291.51 Rewrite Strategy: INNERMOST 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (5) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Infered types. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (6) 323.73/291.51 Obligation: 323.73/291.51 Runtime Complexity Weighted TRS with Types. 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 [1] 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) [1] 323.73/291.51 plus(x, 0) -> x [1] 323.73/291.51 plus(0, x) -> x [1] 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) [1] 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) [1] 323.73/291.51 323.73/291.51 The TRS has the following type information: 323.73/291.51 times :: 0:s -> 0:s -> 0:s 323.73/291.51 0 :: 0:s 323.73/291.51 s :: 0:s -> 0:s 323.73/291.51 plus :: 0:s -> 0:s -> 0:s 323.73/291.51 323.73/291.51 Rewrite Strategy: INNERMOST 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (7) CompletionProof (UPPER BOUND(ID)) 323.73/291.51 The transformation into a RNTS is sound, since: 323.73/291.51 323.73/291.51 (a) The obligation is a constructor system where every type has a constant constructor, 323.73/291.51 323.73/291.51 (b) The following defined symbols do not have to be completely defined, as they can never occur inside other defined symbols: 323.73/291.51 none 323.73/291.51 323.73/291.51 (c) The following functions are completely defined: 323.73/291.51 323.73/291.51 times_2 323.73/291.51 plus_2 323.73/291.51 323.73/291.51 Due to the following rules being added: 323.73/291.51 none 323.73/291.51 323.73/291.51 And the following fresh constants: none 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (8) 323.73/291.51 Obligation: 323.73/291.51 Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: 323.73/291.51 323.73/291.51 Runtime Complexity Weighted TRS with Types. 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 [1] 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) [1] 323.73/291.51 plus(x, 0) -> x [1] 323.73/291.51 plus(0, x) -> x [1] 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) [1] 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) [1] 323.73/291.51 323.73/291.51 The TRS has the following type information: 323.73/291.51 times :: 0:s -> 0:s -> 0:s 323.73/291.51 0 :: 0:s 323.73/291.51 s :: 0:s -> 0:s 323.73/291.51 plus :: 0:s -> 0:s -> 0:s 323.73/291.51 323.73/291.51 Rewrite Strategy: INNERMOST 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (9) NarrowingProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Narrowed the inner basic terms of all right-hand sides by a single narrowing step. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (10) 323.73/291.51 Obligation: 323.73/291.51 Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: 323.73/291.51 323.73/291.51 Runtime Complexity Weighted TRS with Types. 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0) -> 0 [1] 323.73/291.51 times(x, s(0)) -> plus(0, x) [2] 323.73/291.51 times(x, s(s(y'))) -> plus(plus(times(x, y'), x), x) [2] 323.73/291.51 plus(x, 0) -> x [1] 323.73/291.51 plus(0, x) -> x [1] 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) [1] 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) [1] 323.73/291.51 323.73/291.51 The TRS has the following type information: 323.73/291.51 times :: 0:s -> 0:s -> 0:s 323.73/291.51 0 :: 0:s 323.73/291.51 s :: 0:s -> 0:s 323.73/291.51 plus :: 0:s -> 0:s -> 0:s 323.73/291.51 323.73/291.51 Rewrite Strategy: INNERMOST 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (11) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) 323.73/291.51 Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. 323.73/291.51 The constant constructors are abstracted as follows: 323.73/291.51 323.73/291.51 0 => 0 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (12) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> x :|: x >= 0, z = x, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> x :|: z' = x, x >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(x, y) :|: z' = 1 + y, x >= 0, y >= 0, z = x 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(x, y) :|: x >= 0, y >= 0, z = 1 + x, z' = y 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(x, y'), x), x) :|: z' = 1 + (1 + y'), x >= 0, y' >= 0, z = x 323.73/291.51 times(z, z') -{ 2 }-> plus(0, x) :|: x >= 0, z' = 1 + 0, z = x 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: x >= 0, z = x, z' = 0 323.73/291.51 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (13) SimplificationProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Simplified the RNTS by moving equalities from the constraints into the right-hand sides. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (14) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z, z' - 1) :|: z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z - 1, z') :|: z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(0, z) :|: z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (15) CpxRntsAnalysisOrderProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Found the following analysis order by SCC decomposition: 323.73/291.51 323.73/291.51 { plus } 323.73/291.51 { times } 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (16) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z, z' - 1) :|: z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z - 1, z') :|: z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(0, z) :|: z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {plus}, {times} 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (17) ResultPropagationProof (UPPER BOUND(ID)) 323.73/291.51 Applied inner abstraction using the recently inferred runtime/size bounds where possible. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (18) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z, z' - 1) :|: z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z - 1, z') :|: z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(0, z) :|: z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {plus}, {times} 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (19) IntTrsBoundProof (UPPER BOUND(ID)) 323.73/291.51 323.73/291.51 Computed SIZE bound using CoFloCo for: plus 323.73/291.51 after applying outer abstraction to obtain an ITS, 323.73/291.51 resulting in: O(n^1) with polynomial bound: z + z' 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (20) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z, z' - 1) :|: z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z - 1, z') :|: z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(0, z) :|: z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {plus}, {times} 323.73/291.51 Previous analysis results are: 323.73/291.51 plus: runtime: ?, size: O(n^1) [z + z'] 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (21) IntTrsBoundProof (UPPER BOUND(ID)) 323.73/291.51 323.73/291.51 Computed RUNTIME bound using CoFloCo for: plus 323.73/291.51 after applying outer abstraction to obtain an ITS, 323.73/291.51 resulting in: O(n^1) with polynomial bound: 1 + z + z' 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (22) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z, z' - 1) :|: z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 }-> 1 + plus(z - 1, z') :|: z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 2 }-> plus(0, z) :|: z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {times} 323.73/291.51 Previous analysis results are: 323.73/291.51 plus: runtime: O(n^1) [1 + z + z'], size: O(n^1) [z + z'] 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (23) ResultPropagationProof (UPPER BOUND(ID)) 323.73/291.51 Applied inner abstraction using the recently inferred runtime/size bounds where possible. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (24) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s' :|: s' >= 0, s' <= z + (z' - 1), z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s'' :|: s'' >= 0, s'' <= z - 1 + z', z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 3 + z }-> s :|: s >= 0, s <= 0 + z, z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {times} 323.73/291.51 Previous analysis results are: 323.73/291.51 plus: runtime: O(n^1) [1 + z + z'], size: O(n^1) [z + z'] 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (25) IntTrsBoundProof (UPPER BOUND(ID)) 323.73/291.51 323.73/291.51 Computed SIZE bound using KoAT for: times 323.73/291.51 after applying outer abstraction to obtain an ITS, 323.73/291.51 resulting in: O(n^2) with polynomial bound: z + 2*z*z' 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (26) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s' :|: s' >= 0, s' <= z + (z' - 1), z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s'' :|: s'' >= 0, s'' <= z - 1 + z', z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 3 + z }-> s :|: s >= 0, s <= 0 + z, z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: {times} 323.73/291.51 Previous analysis results are: 323.73/291.51 plus: runtime: O(n^1) [1 + z + z'], size: O(n^1) [z + z'] 323.73/291.51 times: runtime: ?, size: O(n^2) [z + 2*z*z'] 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (27) IntTrsBoundProof (UPPER BOUND(ID)) 323.73/291.51 323.73/291.51 Computed RUNTIME bound using KoAT for: times 323.73/291.51 after applying outer abstraction to obtain an ITS, 323.73/291.51 resulting in: O(n^3) with polynomial bound: 4 + z + 4*z*z'^2 + 4*z' 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (28) 323.73/291.51 Obligation: 323.73/291.51 Complexity RNTS consisting of the following rules: 323.73/291.51 323.73/291.51 plus(z, z') -{ 1 }-> z :|: z >= 0, z' = 0 323.73/291.51 plus(z, z') -{ 1 }-> z' :|: z' >= 0, z = 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s' :|: s' >= 0, s' <= z + (z' - 1), z >= 0, z' - 1 >= 0 323.73/291.51 plus(z, z') -{ 1 + z + z' }-> 1 + s'' :|: s'' >= 0, s'' <= z - 1 + z', z - 1 >= 0, z' >= 0 323.73/291.51 times(z, z') -{ 3 + z }-> s :|: s >= 0, s <= 0 + z, z >= 0, z' = 1 + 0 323.73/291.51 times(z, z') -{ 2 }-> plus(plus(times(z, z' - 2), z), z) :|: z >= 0, z' - 2 >= 0 323.73/291.51 times(z, z') -{ 1 }-> 0 :|: z >= 0, z' = 0 323.73/291.51 323.73/291.51 Function symbols to be analyzed: 323.73/291.51 Previous analysis results are: 323.73/291.51 plus: runtime: O(n^1) [1 + z + z'], size: O(n^1) [z + z'] 323.73/291.51 times: runtime: O(n^3) [4 + z + 4*z*z'^2 + 4*z'], size: O(n^2) [z + 2*z*z'] 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (29) FinalProof (FINISHED) 323.73/291.51 Computed overall runtime complexity 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (30) 323.73/291.51 BOUNDS(1, n^3) 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (31) RenamingProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Renamed function symbols to avoid clashes with predefined symbol. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (32) 323.73/291.51 Obligation: 323.73/291.51 The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^2, INF). 323.73/291.51 323.73/291.51 323.73/291.51 The TRS R consists of the following rules: 323.73/291.51 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 S is empty. 323.73/291.51 Rewrite Strategy: FULL 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (33) TypeInferenceProof (BOTH BOUNDS(ID, ID)) 323.73/291.51 Infered types. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (34) 323.73/291.51 Obligation: 323.73/291.51 TRS: 323.73/291.51 Rules: 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 Types: 323.73/291.51 times :: 0':s -> 0':s -> 0':s 323.73/291.51 0' :: 0':s 323.73/291.51 s :: 0':s -> 0':s 323.73/291.51 plus :: 0':s -> 0':s -> 0':s 323.73/291.51 hole_0':s1_0 :: 0':s 323.73/291.51 gen_0':s2_0 :: Nat -> 0':s 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (35) OrderProof (LOWER BOUND(ID)) 323.73/291.51 Heuristically decided to analyse the following defined symbols: 323.73/291.51 times, plus 323.73/291.51 323.73/291.51 They will be analysed ascendingly in the following order: 323.73/291.51 plus < times 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (36) 323.73/291.51 Obligation: 323.73/291.51 TRS: 323.73/291.51 Rules: 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 Types: 323.73/291.51 times :: 0':s -> 0':s -> 0':s 323.73/291.51 0' :: 0':s 323.73/291.51 s :: 0':s -> 0':s 323.73/291.51 plus :: 0':s -> 0':s -> 0':s 323.73/291.51 hole_0':s1_0 :: 0':s 323.73/291.51 gen_0':s2_0 :: Nat -> 0':s 323.73/291.51 323.73/291.51 323.73/291.51 Generator Equations: 323.73/291.51 gen_0':s2_0(0) <=> 0' 323.73/291.51 gen_0':s2_0(+(x, 1)) <=> s(gen_0':s2_0(x)) 323.73/291.51 323.73/291.51 323.73/291.51 The following defined symbols remain to be analysed: 323.73/291.51 plus, times 323.73/291.51 323.73/291.51 They will be analysed ascendingly in the following order: 323.73/291.51 plus < times 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (37) RewriteLemmaProof (LOWER BOUND(ID)) 323.73/291.51 Proved the following rewrite lemma: 323.73/291.51 plus(gen_0':s2_0(a), gen_0':s2_0(n4_0)) -> gen_0':s2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 323.73/291.51 323.73/291.51 Induction Base: 323.73/291.51 plus(gen_0':s2_0(a), gen_0':s2_0(0)) ->_R^Omega(1) 323.73/291.51 gen_0':s2_0(a) 323.73/291.51 323.73/291.51 Induction Step: 323.73/291.51 plus(gen_0':s2_0(a), gen_0':s2_0(+(n4_0, 1))) ->_R^Omega(1) 323.73/291.51 s(plus(gen_0':s2_0(a), gen_0':s2_0(n4_0))) ->_IH 323.73/291.51 s(gen_0':s2_0(+(a, c5_0))) 323.73/291.51 323.73/291.51 We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (38) 323.73/291.51 Complex Obligation (BEST) 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (39) 323.73/291.51 Obligation: 323.73/291.51 Proved the lower bound n^1 for the following obligation: 323.73/291.51 323.73/291.51 TRS: 323.73/291.51 Rules: 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 Types: 323.73/291.51 times :: 0':s -> 0':s -> 0':s 323.73/291.51 0' :: 0':s 323.73/291.51 s :: 0':s -> 0':s 323.73/291.51 plus :: 0':s -> 0':s -> 0':s 323.73/291.51 hole_0':s1_0 :: 0':s 323.73/291.51 gen_0':s2_0 :: Nat -> 0':s 323.73/291.51 323.73/291.51 323.73/291.51 Generator Equations: 323.73/291.51 gen_0':s2_0(0) <=> 0' 323.73/291.51 gen_0':s2_0(+(x, 1)) <=> s(gen_0':s2_0(x)) 323.73/291.51 323.73/291.51 323.73/291.51 The following defined symbols remain to be analysed: 323.73/291.51 plus, times 323.73/291.51 323.73/291.51 They will be analysed ascendingly in the following order: 323.73/291.51 plus < times 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (40) LowerBoundPropagationProof (FINISHED) 323.73/291.51 Propagated lower bound. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (41) 323.73/291.51 BOUNDS(n^1, INF) 323.73/291.51 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (42) 323.73/291.51 Obligation: 323.73/291.51 TRS: 323.73/291.51 Rules: 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 Types: 323.73/291.51 times :: 0':s -> 0':s -> 0':s 323.73/291.51 0' :: 0':s 323.73/291.51 s :: 0':s -> 0':s 323.73/291.51 plus :: 0':s -> 0':s -> 0':s 323.73/291.51 hole_0':s1_0 :: 0':s 323.73/291.51 gen_0':s2_0 :: Nat -> 0':s 323.73/291.51 323.73/291.51 323.73/291.51 Lemmas: 323.73/291.51 plus(gen_0':s2_0(a), gen_0':s2_0(n4_0)) -> gen_0':s2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 323.73/291.51 323.73/291.51 323.73/291.51 Generator Equations: 323.73/291.51 gen_0':s2_0(0) <=> 0' 323.73/291.51 gen_0':s2_0(+(x, 1)) <=> s(gen_0':s2_0(x)) 323.73/291.51 323.73/291.51 323.73/291.51 The following defined symbols remain to be analysed: 323.73/291.51 times 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (43) RewriteLemmaProof (LOWER BOUND(ID)) 323.73/291.51 Proved the following rewrite lemma: 323.73/291.51 times(gen_0':s2_0(a), gen_0':s2_0(n544_0)) -> gen_0':s2_0(*(n544_0, a)), rt in Omega(1 + a*n544_0 + n544_0) 323.73/291.51 323.73/291.51 Induction Base: 323.73/291.51 times(gen_0':s2_0(a), gen_0':s2_0(0)) ->_R^Omega(1) 323.73/291.51 0' 323.73/291.51 323.73/291.51 Induction Step: 323.73/291.51 times(gen_0':s2_0(a), gen_0':s2_0(+(n544_0, 1))) ->_R^Omega(1) 323.73/291.51 plus(times(gen_0':s2_0(a), gen_0':s2_0(n544_0)), gen_0':s2_0(a)) ->_IH 323.73/291.51 plus(gen_0':s2_0(*(c545_0, a)), gen_0':s2_0(a)) ->_L^Omega(1 + a) 323.73/291.51 gen_0':s2_0(+(a, *(n544_0, a))) 323.73/291.51 323.73/291.51 We have rt in Omega(n^2) and sz in O(n). Thus, we have irc_R in Omega(n^2). 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (44) 323.73/291.51 Obligation: 323.73/291.51 Proved the lower bound n^2 for the following obligation: 323.73/291.51 323.73/291.51 TRS: 323.73/291.51 Rules: 323.73/291.51 times(x, 0') -> 0' 323.73/291.51 times(x, s(y)) -> plus(times(x, y), x) 323.73/291.51 plus(x, 0') -> x 323.73/291.51 plus(0', x) -> x 323.73/291.51 plus(x, s(y)) -> s(plus(x, y)) 323.73/291.51 plus(s(x), y) -> s(plus(x, y)) 323.73/291.51 323.73/291.51 Types: 323.73/291.51 times :: 0':s -> 0':s -> 0':s 323.73/291.51 0' :: 0':s 323.73/291.51 s :: 0':s -> 0':s 323.73/291.51 plus :: 0':s -> 0':s -> 0':s 323.73/291.51 hole_0':s1_0 :: 0':s 323.73/291.51 gen_0':s2_0 :: Nat -> 0':s 323.73/291.51 323.73/291.51 323.73/291.51 Lemmas: 323.73/291.51 plus(gen_0':s2_0(a), gen_0':s2_0(n4_0)) -> gen_0':s2_0(+(n4_0, a)), rt in Omega(1 + n4_0) 323.73/291.51 323.73/291.51 323.73/291.51 Generator Equations: 323.73/291.51 gen_0':s2_0(0) <=> 0' 323.73/291.51 gen_0':s2_0(+(x, 1)) <=> s(gen_0':s2_0(x)) 323.73/291.51 323.73/291.51 323.73/291.51 The following defined symbols remain to be analysed: 323.73/291.51 times 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (45) LowerBoundPropagationProof (FINISHED) 323.73/291.51 Propagated lower bound. 323.73/291.51 ---------------------------------------- 323.73/291.51 323.73/291.51 (46) 323.73/291.51 BOUNDS(n^2, INF) 323.73/291.55 EOF