/export/starexec/sandbox/solver/bin/starexec_run_complexity /export/starexec/sandbox/benchmark/theBenchmark.xml /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- WORST_CASE(Omega(n^3), O(n^4)) proof of /export/starexec/sandbox/benchmark/theBenchmark.xml # AProVE Commit ID: 794c25de1cacf0d048858bcd21c9a779e1221865 marcel 20200619 unpublished dirty The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^3, n^4). (0) CpxTRS (1) NestedDefinedSymbolProof [UPPER BOUND(ID), 0 ms] (2) CpxTRS (3) RcToIrcProof [BOTH BOUNDS(ID, ID), 0 ms] (4) CpxTRS (5) RelTrsToWeightedTrsProof [BOTH BOUNDS(ID, ID), 0 ms] (6) CpxWeightedTrs (7) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] (8) CpxTypedWeightedTrs (9) CompletionProof [UPPER BOUND(ID), 0 ms] (10) CpxTypedWeightedCompleteTrs (11) NarrowingProof [BOTH BOUNDS(ID, ID), 0 ms] (12) CpxTypedWeightedCompleteTrs (13) CpxTypedWeightedTrsToRntsProof [UPPER BOUND(ID), 0 ms] (14) CpxRNTS (15) SimplificationProof [BOTH BOUNDS(ID, ID), 0 ms] (16) CpxRNTS (17) CpxRntsAnalysisOrderProof [BOTH BOUNDS(ID, ID), 0 ms] (18) CpxRNTS (19) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (20) CpxRNTS (21) IntTrsBoundProof [UPPER BOUND(ID), 383 ms] (22) CpxRNTS (23) IntTrsBoundProof [UPPER BOUND(ID), 148 ms] (24) CpxRNTS (25) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (26) CpxRNTS (27) IntTrsBoundProof [UPPER BOUND(ID), 1039 ms] (28) CpxRNTS (29) IntTrsBoundProof [UPPER BOUND(ID), 346 ms] (30) CpxRNTS (31) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (32) CpxRNTS (33) IntTrsBoundProof [UPPER BOUND(ID), 572 ms] (34) CpxRNTS (35) IntTrsBoundProof [UPPER BOUND(ID), 196 ms] (36) CpxRNTS (37) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (38) CpxRNTS (39) IntTrsBoundProof [UPPER BOUND(ID), 117 ms] (40) CpxRNTS (41) IntTrsBoundProof [UPPER BOUND(ID), 42 ms] (42) CpxRNTS (43) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (44) CpxRNTS (45) IntTrsBoundProof [UPPER BOUND(ID), 584 ms] (46) CpxRNTS (47) IntTrsBoundProof [UPPER BOUND(ID), 0 ms] (48) CpxRNTS (49) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (50) CpxRNTS (51) IntTrsBoundProof [UPPER BOUND(ID), 557 ms] (52) CpxRNTS (53) IntTrsBoundProof [UPPER BOUND(ID), 9 ms] (54) CpxRNTS (55) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (56) CpxRNTS (57) IntTrsBoundProof [UPPER BOUND(ID), 191 ms] (58) CpxRNTS (59) IntTrsBoundProof [UPPER BOUND(ID), 0 ms] (60) CpxRNTS (61) ResultPropagationProof [UPPER BOUND(ID), 0 ms] (62) CpxRNTS (63) IntTrsBoundProof [UPPER BOUND(ID), 157 ms] (64) CpxRNTS (65) IntTrsBoundProof [UPPER BOUND(ID), 0 ms] (66) CpxRNTS (67) FinalProof [FINISHED, 0 ms] (68) BOUNDS(1, n^4) (69) RenamingProof [BOTH BOUNDS(ID, ID), 0 ms] (70) CpxTRS (71) TypeInferenceProof [BOTH BOUNDS(ID, ID), 0 ms] (72) typed CpxTrs (73) OrderProof [LOWER BOUND(ID), 0 ms] (74) typed CpxTrs (75) RewriteLemmaProof [LOWER BOUND(ID), 229 ms] (76) BEST (77) proven lower bound (78) LowerBoundPropagationProof [FINISHED, 0 ms] (79) BOUNDS(n^1, INF) (80) typed CpxTrs (81) RewriteLemmaProof [LOWER BOUND(ID), 94 ms] (82) BEST (83) proven lower bound (84) LowerBoundPropagationProof [FINISHED, 0 ms] (85) BOUNDS(n^3, INF) (86) typed CpxTrs (87) RewriteLemmaProof [LOWER BOUND(ID), 44 ms] (88) typed CpxTrs (89) RewriteLemmaProof [LOWER BOUND(ID), 50 ms] (90) typed CpxTrs ---------------------------------------- (0) Obligation: The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^3, n^4). The TRS R consists of the following rules: p(s(x)) -> x plus(x, 0) -> x plus(0, y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0, y) -> 0 times(s(0), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0, y) -> 0 div(x, y) -> quot(x, y, y) quot(0, s(y), z) -> 0 quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0, s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0, 0) -> true eq(s(x), 0) -> false eq(0, s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0)) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) S is empty. Rewrite Strategy: FULL ---------------------------------------- (1) NestedDefinedSymbolProof (UPPER BOUND(ID)) The following defined symbols can occur below the 0th argument of plus: p The following defined symbols can occur below the 1th argument of plus: p, plus, times, div, quot The following defined symbols can occur below the 0th argument of p: p, plus, times The following defined symbols can occur below the 0th argument of if: p, plus, eq, divides, div, times, quot The following defined symbols can occur below the 1th argument of eq: p, plus, div, times, quot The following defined symbols can occur below the 0th argument of times: div, quot Hence, the left-hand sides of the following rules are not basic-reachable and can be removed: div(div(x, y), z) -> div(x, times(y, z)) ---------------------------------------- (2) Obligation: The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(1, n^4). The TRS R consists of the following rules: p(s(x)) -> x plus(x, 0) -> x plus(0, y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0, y) -> 0 times(s(0), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0, y) -> 0 div(x, y) -> quot(x, y, y) quot(0, s(y), z) -> 0 quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0, s(z)) -> s(div(x, s(z))) eq(0, 0) -> true eq(s(x), 0) -> false eq(0, s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0)) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) S is empty. Rewrite Strategy: FULL ---------------------------------------- (3) RcToIrcProof (BOTH BOUNDS(ID, ID)) Converted rc-obligation to irc-obligation. The duplicating contexts are: times(s(x), []) div(x, []) divides(y, []) divides([], x) prime(s(s([]))) pr(x, s(s([]))) pr([], s(s(y))) The defined contexts are: plus(x0, []) plus([], x1) if([], x1, s(x2)) eq(x0, []) times([], x1) p(s([])) [] just represents basic- or constructor-terms in the following defined contexts: plus(x0, []) plus([], x1) As the TRS is an overlay system and the defined contexts and the duplicating contexts don't overlap, we have rc = irc. ---------------------------------------- (4) Obligation: The Runtime Complexity (innermost) of the given CpxTRS could be proven to be BOUNDS(1, n^4). The TRS R consists of the following rules: p(s(x)) -> x plus(x, 0) -> x plus(0, y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0, y) -> 0 times(s(0), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0, y) -> 0 div(x, y) -> quot(x, y, y) quot(0, s(y), z) -> 0 quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0, s(z)) -> s(div(x, s(z))) eq(0, 0) -> true eq(s(x), 0) -> false eq(0, s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0)) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) S is empty. Rewrite Strategy: INNERMOST ---------------------------------------- (5) RelTrsToWeightedTrsProof (BOTH BOUNDS(ID, ID)) Transformed relative TRS to weighted TRS ---------------------------------------- (6) Obligation: The Runtime Complexity (innermost) of the given CpxWeightedTrs could be proven to be BOUNDS(1, n^4). The TRS R consists of the following rules: p(s(x)) -> x [1] plus(x, 0) -> x [1] plus(0, y) -> y [1] plus(s(x), y) -> s(plus(x, y)) [1] plus(s(x), y) -> s(plus(p(s(x)), y)) [1] plus(x, s(y)) -> s(plus(x, p(s(y)))) [1] times(0, y) -> 0 [1] times(s(0), y) -> y [1] times(s(x), y) -> plus(y, times(x, y)) [1] div(0, y) -> 0 [1] div(x, y) -> quot(x, y, y) [1] quot(0, s(y), z) -> 0 [1] quot(s(x), s(y), z) -> quot(x, y, z) [1] quot(x, 0, s(z)) -> s(div(x, s(z))) [1] eq(0, 0) -> true [1] eq(s(x), 0) -> false [1] eq(0, s(y)) -> false [1] eq(s(x), s(y)) -> eq(x, y) [1] divides(y, x) -> eq(x, times(div(x, y), y)) [1] prime(s(s(x))) -> pr(s(s(x)), s(x)) [1] pr(x, s(0)) -> true [1] pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) [1] if(true, x, y) -> false [1] if(false, x, y) -> pr(x, y) [1] Rewrite Strategy: INNERMOST ---------------------------------------- (7) TypeInferenceProof (BOTH BOUNDS(ID, ID)) Infered types. ---------------------------------------- (8) Obligation: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: p(s(x)) -> x [1] plus(x, 0) -> x [1] plus(0, y) -> y [1] plus(s(x), y) -> s(plus(x, y)) [1] plus(s(x), y) -> s(plus(p(s(x)), y)) [1] plus(x, s(y)) -> s(plus(x, p(s(y)))) [1] times(0, y) -> 0 [1] times(s(0), y) -> y [1] times(s(x), y) -> plus(y, times(x, y)) [1] div(0, y) -> 0 [1] div(x, y) -> quot(x, y, y) [1] quot(0, s(y), z) -> 0 [1] quot(s(x), s(y), z) -> quot(x, y, z) [1] quot(x, 0, s(z)) -> s(div(x, s(z))) [1] eq(0, 0) -> true [1] eq(s(x), 0) -> false [1] eq(0, s(y)) -> false [1] eq(s(x), s(y)) -> eq(x, y) [1] divides(y, x) -> eq(x, times(div(x, y), y)) [1] prime(s(s(x))) -> pr(s(s(x)), s(x)) [1] pr(x, s(0)) -> true [1] pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) [1] if(true, x, y) -> false [1] if(false, x, y) -> pr(x, y) [1] The TRS has the following type information: p :: s:0 -> s:0 s :: s:0 -> s:0 plus :: s:0 -> s:0 -> s:0 0 :: s:0 times :: s:0 -> s:0 -> s:0 div :: s:0 -> s:0 -> s:0 quot :: s:0 -> s:0 -> s:0 -> s:0 eq :: s:0 -> s:0 -> true:false true :: true:false false :: true:false divides :: s:0 -> s:0 -> true:false prime :: s:0 -> true:false pr :: s:0 -> s:0 -> true:false if :: true:false -> s:0 -> s:0 -> true:false Rewrite Strategy: INNERMOST ---------------------------------------- (9) CompletionProof (UPPER BOUND(ID)) The transformation into a RNTS is sound, since: (a) The obligation is a constructor system where every type has a constant constructor, (b) The following defined symbols do not have to be completely defined, as they can never occur inside other defined symbols: prime_1 pr_2 if_3 (c) The following functions are completely defined: p_1 times_2 div_2 divides_2 plus_2 eq_2 quot_3 Due to the following rules being added: p(v0) -> 0 [0] quot(v0, v1, v2) -> 0 [0] And the following fresh constants: none ---------------------------------------- (10) Obligation: Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: p(s(x)) -> x [1] plus(x, 0) -> x [1] plus(0, y) -> y [1] plus(s(x), y) -> s(plus(x, y)) [1] plus(s(x), y) -> s(plus(p(s(x)), y)) [1] plus(x, s(y)) -> s(plus(x, p(s(y)))) [1] times(0, y) -> 0 [1] times(s(0), y) -> y [1] times(s(x), y) -> plus(y, times(x, y)) [1] div(0, y) -> 0 [1] div(x, y) -> quot(x, y, y) [1] quot(0, s(y), z) -> 0 [1] quot(s(x), s(y), z) -> quot(x, y, z) [1] quot(x, 0, s(z)) -> s(div(x, s(z))) [1] eq(0, 0) -> true [1] eq(s(x), 0) -> false [1] eq(0, s(y)) -> false [1] eq(s(x), s(y)) -> eq(x, y) [1] divides(y, x) -> eq(x, times(div(x, y), y)) [1] prime(s(s(x))) -> pr(s(s(x)), s(x)) [1] pr(x, s(0)) -> true [1] pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) [1] if(true, x, y) -> false [1] if(false, x, y) -> pr(x, y) [1] p(v0) -> 0 [0] quot(v0, v1, v2) -> 0 [0] The TRS has the following type information: p :: s:0 -> s:0 s :: s:0 -> s:0 plus :: s:0 -> s:0 -> s:0 0 :: s:0 times :: s:0 -> s:0 -> s:0 div :: s:0 -> s:0 -> s:0 quot :: s:0 -> s:0 -> s:0 -> s:0 eq :: s:0 -> s:0 -> true:false true :: true:false false :: true:false divides :: s:0 -> s:0 -> true:false prime :: s:0 -> true:false pr :: s:0 -> s:0 -> true:false if :: true:false -> s:0 -> s:0 -> true:false Rewrite Strategy: INNERMOST ---------------------------------------- (11) NarrowingProof (BOTH BOUNDS(ID, ID)) Narrowed the inner basic terms of all right-hand sides by a single narrowing step. ---------------------------------------- (12) Obligation: Runtime Complexity Weighted TRS where critical functions are completely defined. The underlying TRS is: Runtime Complexity Weighted TRS with Types. The TRS R consists of the following rules: p(s(x)) -> x [1] plus(x, 0) -> x [1] plus(0, y) -> y [1] plus(s(x), y) -> s(plus(x, y)) [1] plus(s(x), y) -> s(plus(x, y)) [2] plus(s(x), y) -> s(plus(0, y)) [1] plus(x, s(y)) -> s(plus(x, y)) [2] plus(x, s(y)) -> s(plus(x, 0)) [1] times(0, y) -> 0 [1] times(s(0), y) -> y [1] times(s(0), y) -> plus(y, 0) [2] times(s(s(0)), y) -> plus(y, y) [2] times(s(s(x')), y) -> plus(y, plus(y, times(x', y))) [2] div(0, y) -> 0 [1] div(x, y) -> quot(x, y, y) [1] quot(0, s(y), z) -> 0 [1] quot(s(x), s(y), z) -> quot(x, y, z) [1] quot(x, 0, s(z)) -> s(div(x, s(z))) [1] eq(0, 0) -> true [1] eq(s(x), 0) -> false [1] eq(0, s(y)) -> false [1] eq(s(x), s(y)) -> eq(x, y) [1] divides(y, 0) -> eq(0, times(0, y)) [2] divides(y, x) -> eq(x, times(quot(x, y, y), y)) [2] prime(s(s(x))) -> pr(s(s(x)), s(x)) [1] pr(x, s(0)) -> true [1] pr(x, s(s(y))) -> if(eq(x, times(div(x, s(s(y))), s(s(y)))), x, s(y)) [2] if(true, x, y) -> false [1] if(false, x, y) -> pr(x, y) [1] p(v0) -> 0 [0] quot(v0, v1, v2) -> 0 [0] The TRS has the following type information: p :: s:0 -> s:0 s :: s:0 -> s:0 plus :: s:0 -> s:0 -> s:0 0 :: s:0 times :: s:0 -> s:0 -> s:0 div :: s:0 -> s:0 -> s:0 quot :: s:0 -> s:0 -> s:0 -> s:0 eq :: s:0 -> s:0 -> true:false true :: true:false false :: true:false divides :: s:0 -> s:0 -> true:false prime :: s:0 -> true:false pr :: s:0 -> s:0 -> true:false if :: true:false -> s:0 -> s:0 -> true:false Rewrite Strategy: INNERMOST ---------------------------------------- (13) CpxTypedWeightedTrsToRntsProof (UPPER BOUND(ID)) Transformed the TRS into an over-approximating RNTS by (improved) Size Abstraction. The constant constructors are abstracted as follows: 0 => 0 true => 1 false => 0 ---------------------------------------- (14) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(x, y, y) :|: z' = x, z'' = y, x >= 0, y >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' = y, y >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(x, times(quot(x, y, y), y)) :|: y >= 0, x >= 0, z'' = x, z' = y divides(z', z'') -{ 2 }-> eq(0, times(0, y)) :|: z'' = 0, y >= 0, z' = y eq(z', z'') -{ 1 }-> eq(x, y) :|: z' = 1 + x, x >= 0, y >= 0, z'' = 1 + y eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' = 1 + x, x >= 0 eq(z', z'') -{ 1 }-> 0 :|: y >= 0, z'' = 1 + y, z' = 0 if(z', z'', z1) -{ 1 }-> pr(x, y) :|: z1 = y, x >= 0, y >= 0, z'' = x, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z1 = y, x >= 0, y >= 0, z'' = x, z' = 1 p(z') -{ 1 }-> x :|: z' = 1 + x, x >= 0 p(z') -{ 0 }-> 0 :|: v0 >= 0, z' = v0 plus(z', z'') -{ 1 }-> x :|: z'' = 0, z' = x, x >= 0 plus(z', z'') -{ 1 }-> y :|: z'' = y, y >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(x, y) :|: z' = 1 + x, z'' = y, x >= 0, y >= 0 plus(z', z'') -{ 2 }-> 1 + plus(x, y) :|: z' = 1 + x, z'' = y, x >= 0, y >= 0 plus(z', z'') -{ 2 }-> 1 + plus(x, y) :|: z' = x, x >= 0, y >= 0, z'' = 1 + y plus(z', z'') -{ 1 }-> 1 + plus(x, 0) :|: z' = x, x >= 0, y >= 0, z'' = 1 + y plus(z', z'') -{ 1 }-> 1 + plus(0, y) :|: z' = 1 + x, z'' = y, x >= 0, y >= 0 pr(z', z'') -{ 2 }-> if(eq(x, times(div(x, 1 + (1 + y)), 1 + (1 + y))), x, 1 + y) :|: z' = x, x >= 0, y >= 0, z'' = 1 + (1 + y) pr(z', z'') -{ 1 }-> 1 :|: z' = x, x >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + x), 1 + x) :|: x >= 0, z' = 1 + (1 + x) quot(z', z'', z1) -{ 1 }-> quot(x, y, z) :|: z' = 1 + x, z1 = z, z >= 0, x >= 0, y >= 0, z'' = 1 + y quot(z', z'', z1) -{ 1 }-> 0 :|: z1 = z, z >= 0, y >= 0, z'' = 1 + y, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: v0 >= 0, z1 = v2, v1 >= 0, z'' = v1, v2 >= 0, z' = v0 quot(z', z'', z1) -{ 1 }-> 1 + div(x, 1 + z) :|: z'' = 0, z >= 0, z' = x, x >= 0, z1 = 1 + z times(z', z'') -{ 1 }-> y :|: z'' = y, y >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(y, y) :|: z' = 1 + (1 + 0), z'' = y, y >= 0 times(z', z'') -{ 2 }-> plus(y, plus(y, times(x', y))) :|: z' = 1 + (1 + x'), z'' = y, x' >= 0, y >= 0 times(z', z'') -{ 2 }-> plus(y, 0) :|: z'' = y, y >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' = y, y >= 0, z' = 0 ---------------------------------------- (15) SimplificationProof (BOTH BOUNDS(ID, ID)) Simplified the RNTS by moving equalities from the constraints into the right-hand sides. ---------------------------------------- (16) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 1 }-> eq(z' - 1, z'' - 1) :|: z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 ---------------------------------------- (17) CpxRntsAnalysisOrderProof (BOTH BOUNDS(ID, ID)) Found the following analysis order by SCC decomposition: { eq } { div, quot } { plus } { p } { times } { if, pr } { divides } { prime } ---------------------------------------- (18) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 1 }-> eq(z' - 1, z'' - 1) :|: z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {eq}, {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} ---------------------------------------- (19) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (20) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 1 }-> eq(z' - 1, z'' - 1) :|: z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {eq}, {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} ---------------------------------------- (21) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: eq after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 ---------------------------------------- (22) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 1 }-> eq(z' - 1, z'' - 1) :|: z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {eq}, {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: ?, size: O(1) [1] ---------------------------------------- (23) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: eq after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: 3 + z' ---------------------------------------- (24) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 1 }-> eq(z' - 1, z'' - 1) :|: z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] ---------------------------------------- (25) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (26) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] ---------------------------------------- (27) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using KoAT for: div after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: z' Computed SIZE bound using KoAT for: quot after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: 1 + z' ---------------------------------------- (28) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {div,quot}, {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: ?, size: O(n^1) [z'] quot: runtime: ?, size: O(n^1) [1 + z'] ---------------------------------------- (29) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: div after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: 3 + 3*z' Computed RUNTIME bound using KoAT for: quot after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: 5 + 3*z' + z'' ---------------------------------------- (30) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 1 }-> quot(z', z'', z'') :|: z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 2 }-> eq(z'', times(quot(z'', z', z'), z')) :|: z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 2 }-> if(eq(z', times(div(z', 1 + (1 + (z'' - 2))), 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 1 }-> quot(z' - 1, z'' - 1, z1) :|: z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 1 }-> 1 + div(z', 1 + (z1 - 1)) :|: z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] ---------------------------------------- (31) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (32) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] ---------------------------------------- (33) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: plus after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: z' + z'' ---------------------------------------- (34) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {plus}, {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: ?, size: O(n^1) [z' + z''] ---------------------------------------- (35) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using CoFloCo for: plus after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: 1 + 2*z' + 2*z'' ---------------------------------------- (36) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 1 }-> 1 + plus(z', 0) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z', z'' - 1) :|: z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 1 }-> 1 + plus(0, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 }-> 1 + plus(z' - 1, z'') :|: z' - 1 >= 0, z'' >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', z'') :|: z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 2 }-> plus(z'', 0) :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] ---------------------------------------- (37) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (38) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] ---------------------------------------- (39) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using KoAT for: p after applying outer abstraction to obtain an ITS, resulting in: O(n^1) with polynomial bound: z' ---------------------------------------- (40) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {p}, {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: ?, size: O(n^1) [z'] ---------------------------------------- (41) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using CoFloCo for: p after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 ---------------------------------------- (42) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] ---------------------------------------- (43) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (44) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] ---------------------------------------- (45) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: times after applying outer abstraction to obtain an ITS, resulting in: O(n^2) with polynomial bound: 2*z'*z'' + 4*z'' ---------------------------------------- (46) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {times}, {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: ?, size: O(n^2) [2*z'*z'' + 4*z''] ---------------------------------------- (47) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: times after applying outer abstraction to obtain an ITS, resulting in: O(n^3) with polynomial bound: 8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z'' ---------------------------------------- (48) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 7 + z' + 3*z'' }-> eq(z'', times(s2, z')) :|: s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 divides(z', z'') -{ 2 }-> eq(0, times(0, z')) :|: z'' = 0, z' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 5 + 3*z' }-> if(eq(z', times(s3, 1 + (1 + (z'' - 2)))), z', 1 + (z'' - 2)) :|: s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 2 }-> plus(z'', plus(z'', times(z' - 2, z''))) :|: z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] ---------------------------------------- (49) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (50) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 16 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 4*z' + 6*z'' }-> if(s19, z', 1 + (z'' - 2)) :|: s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] ---------------------------------------- (51) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: if after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 Computed SIZE bound using CoFloCo for: pr after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 ---------------------------------------- (52) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 16 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 4*z' + 6*z'' }-> if(s19, z', 1 + (z'' - 2)) :|: s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {if,pr}, {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: ?, size: O(1) [1] pr: runtime: ?, size: O(1) [1] ---------------------------------------- (53) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: if after applying outer abstraction to obtain an ITS, resulting in: O(n^4) with polynomial bound: 19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2 Computed RUNTIME bound using KoAT for: pr after applying outer abstraction to obtain an ITS, resulting in: O(n^4) with polynomial bound: 8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 ---------------------------------------- (54) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> pr(z'', z1) :|: z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 16 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 4*z' + 6*z'' }-> if(s19, z', 1 + (z'' - 2)) :|: s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ 1 }-> pr(1 + (1 + (z' - 2)), 1 + (z' - 2)) :|: z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] ---------------------------------------- (55) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (56) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] ---------------------------------------- (57) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: divides after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 ---------------------------------------- (58) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {divides}, {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] divides: runtime: ?, size: O(1) [1] ---------------------------------------- (59) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: divides after applying outer abstraction to obtain an ITS, resulting in: O(n^3) with polynomial bound: 35 + 27*z' + 22*z'*z'' + 8*z'*z''^2 + 8*z'' ---------------------------------------- (60) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] divides: runtime: O(n^3) [35 + 27*z' + 22*z'*z'' + 8*z'*z''^2 + 8*z''], size: O(1) [1] ---------------------------------------- (61) ResultPropagationProof (UPPER BOUND(ID)) Applied inner abstraction using the recently inferred runtime/size bounds where possible. ---------------------------------------- (62) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] divides: runtime: O(n^3) [35 + 27*z' + 22*z'*z'' + 8*z'*z''^2 + 8*z''], size: O(1) [1] ---------------------------------------- (63) IntTrsBoundProof (UPPER BOUND(ID)) Computed SIZE bound using CoFloCo for: prime after applying outer abstraction to obtain an ITS, resulting in: O(1) with polynomial bound: 1 ---------------------------------------- (64) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: {prime} Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] divides: runtime: O(n^3) [35 + 27*z' + 22*z'*z'' + 8*z'*z''^2 + 8*z''], size: O(1) [1] prime: runtime: ?, size: O(1) [1] ---------------------------------------- (65) IntTrsBoundProof (UPPER BOUND(ID)) Computed RUNTIME bound using KoAT for: prime after applying outer abstraction to obtain an ITS, resulting in: O(n^4) with polynomial bound: 12*z' + 16*z'^2 + 16*z'^4 ---------------------------------------- (66) Obligation: Complexity RNTS consisting of the following rules: div(z', z'') -{ 6 + 3*z' + z'' }-> s' :|: s' >= 0, s' <= z' + 1, z' >= 0, z'' >= 0 div(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 divides(z', z'') -{ 13 + 6*z' }-> s15 :|: s14 >= 0, s14 <= 2 * (0 * z') + 4 * z', s15 >= 0, s15 <= 1, z'' = 0, z' >= 0 divides(z', z'') -{ 18 + 4*s2 + 6*s2*z' + 8*s2^2*z' + 7*z' + 4*z'' }-> s17 :|: s16 >= 0, s16 <= 2 * (s2 * z') + 4 * z', s17 >= 0, s17 <= 1, s2 >= 0, s2 <= z'' + 1, z' >= 0, z'' >= 0 eq(z', z'') -{ 3 + z' }-> s :|: s >= 0, s <= 1, z' - 1 >= 0, z'' - 1 >= 0 eq(z', z'') -{ 1 }-> 1 :|: z'' = 0, z' = 0 eq(z', z'') -{ 1 }-> 0 :|: z'' = 0, z' - 1 >= 0 eq(z', z'') -{ 1 }-> 0 :|: z'' - 1 >= 0, z' = 0 if(z', z'', z1) -{ 9 + 6*z'' + 4*z''*z1 + 12*z''*z1^2 + 8*z''^2 + 16*z''^2*z1^2 + 22*z1 + 12*z1^2 }-> s22 :|: s22 >= 0, s22 <= 1, z'' >= 0, z1 >= 0, z' = 0 if(z', z'', z1) -{ 1 }-> 0 :|: z'' >= 0, z1 >= 0, z' = 1 p(z') -{ 0 }-> 0 :|: z' >= 0 p(z') -{ 1 }-> z' - 1 :|: z' - 1 >= 0 plus(z', z'') -{ 1 }-> z' :|: z'' = 0, z' >= 0 plus(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 0 plus(z', z'') -{ 2*z' + 2*z'' }-> 1 + s4 :|: s4 >= 0, s4 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s5 :|: s5 >= 0, s5 <= z' - 1 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 2 + 2*z'' }-> 1 + s6 :|: s6 >= 0, s6 <= 0 + z'', z' - 1 >= 0, z'' >= 0 plus(z', z'') -{ 1 + 2*z' + 2*z'' }-> 1 + s7 :|: s7 >= 0, s7 <= z' + (z'' - 1), z' >= 0, z'' - 1 >= 0 plus(z', z'') -{ 2 + 2*z' }-> 1 + s8 :|: s8 >= 0, s8 <= z' + 0, z' >= 0, z'' - 1 >= 0 pr(z', z'') -{ 7 + 4*s3 + 6*s3*z'' + 8*s3^2*z'' + 2*z' + -2*z'*z'' + 12*z'*z''^2 + 8*z'^2 + -24*z'^2*z'' + 16*z'^2*z''^2 + 22*z'' + 12*z''^2 }-> s21 :|: s21 >= 0, s21 <= 1, s18 >= 0, s18 <= 2 * (s3 * (1 + (1 + (z'' - 2)))) + 4 * (1 + (1 + (z'' - 2))), s19 >= 0, s19 <= 1, s3 >= 0, s3 <= z', z' >= 0, z'' - 2 >= 0 pr(z', z'') -{ 1 }-> 1 :|: z' >= 0, z'' = 1 + 0 prime(z') -{ -1 + 12*z' + 16*z'^2 + -20*z'^3 + 16*z'^4 }-> s20 :|: s20 >= 0, s20 <= 1, z' - 2 >= 0 quot(z', z'', z1) -{ 2 + 3*z' + z'' }-> s'' :|: s'' >= 0, s'' <= z' - 1 + 1, z1 >= 0, z' - 1 >= 0, z'' - 1 >= 0 quot(z', z'', z1) -{ 1 }-> 0 :|: z1 >= 0, z'' - 1 >= 0, z' = 0 quot(z', z'', z1) -{ 0 }-> 0 :|: z' >= 0, z'' >= 0, z1 >= 0 quot(z', z'', z1) -{ 4 + 3*z' }-> 1 + s1 :|: s1 >= 0, s1 <= z', z'' = 0, z1 - 1 >= 0, z' >= 0 times(z', z'') -{ 3 + 4*z'' }-> s10 :|: s10 >= 0, s10 <= z'' + z'', z' = 1 + (1 + 0), z'' >= 0 times(z', z'') -{ 4 + 2*s11 + 2*s12 + 4*z' + -26*z'*z'' + 8*z'^2*z'' + 30*z'' }-> s13 :|: s11 >= 0, s11 <= 2 * ((z' - 2) * z'') + 4 * z'', s12 >= 0, s12 <= z'' + s11, s13 >= 0, s13 <= z'' + s12, z' - 2 >= 0, z'' >= 0 times(z', z'') -{ 3 + 2*z'' }-> s9 :|: s9 >= 0, s9 <= z'' + 0, z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> z'' :|: z'' >= 0, z' = 1 + 0 times(z', z'') -{ 1 }-> 0 :|: z'' >= 0, z' = 0 Function symbols to be analyzed: Previous analysis results are: eq: runtime: O(n^1) [3 + z'], size: O(1) [1] div: runtime: O(n^1) [3 + 3*z'], size: O(n^1) [z'] quot: runtime: O(n^1) [5 + 3*z' + z''], size: O(n^1) [1 + z'] plus: runtime: O(n^1) [1 + 2*z' + 2*z''], size: O(n^1) [z' + z''] p: runtime: O(1) [1], size: O(n^1) [z'] times: runtime: O(n^3) [8 + 4*z' + 6*z'*z'' + 8*z'^2*z'' + 6*z''], size: O(n^2) [2*z'*z'' + 4*z''] if: runtime: O(n^4) [19 + 8*z'' + 22*z''*z1 + 12*z''*z1^2 + 8*z''^2*z1 + 16*z''^2*z1^2 + 40*z1 + 12*z1^2], size: O(1) [1] pr: runtime: O(n^4) [8 + 6*z' + 4*z'*z'' + 12*z'*z''^2 + 8*z'^2 + 16*z'^2*z''^2 + 22*z'' + 12*z''^2], size: O(1) [1] divides: runtime: O(n^3) [35 + 27*z' + 22*z'*z'' + 8*z'*z''^2 + 8*z''], size: O(1) [1] prime: runtime: O(n^4) [12*z' + 16*z'^2 + 16*z'^4], size: O(1) [1] ---------------------------------------- (67) FinalProof (FINISHED) Computed overall runtime complexity ---------------------------------------- (68) BOUNDS(1, n^4) ---------------------------------------- (69) RenamingProof (BOTH BOUNDS(ID, ID)) Renamed function symbols to avoid clashes with predefined symbol. ---------------------------------------- (70) Obligation: The Runtime Complexity (full) of the given CpxTRS could be proven to be BOUNDS(n^3, INF). The TRS R consists of the following rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) S is empty. Rewrite Strategy: FULL ---------------------------------------- (71) TypeInferenceProof (BOTH BOUNDS(ID, ID)) Infered types. ---------------------------------------- (72) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' ---------------------------------------- (73) OrderProof (LOWER BOUND(ID)) Heuristically decided to analyse the following defined symbols: plus, times, div, quot, eq, pr They will be analysed ascendingly in the following order: plus < times times < div div = quot ---------------------------------------- (74) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: plus, times, div, quot, eq, pr They will be analysed ascendingly in the following order: plus < times times < div div = quot ---------------------------------------- (75) RewriteLemmaProof (LOWER BOUND(ID)) Proved the following rewrite lemma: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) Induction Base: plus(gen_s:0'3_0(a), gen_s:0'3_0(0)) ->_R^Omega(1) gen_s:0'3_0(a) Induction Step: plus(gen_s:0'3_0(a), gen_s:0'3_0(+(n5_0, 1))) ->_R^Omega(1) s(plus(gen_s:0'3_0(a), p(s(gen_s:0'3_0(n5_0))))) ->_R^Omega(1) s(plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0))) ->_IH s(gen_s:0'3_0(+(a, c6_0))) We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). ---------------------------------------- (76) Complex Obligation (BEST) ---------------------------------------- (77) Obligation: Proved the lower bound n^1 for the following obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: plus, times, div, quot, eq, pr They will be analysed ascendingly in the following order: plus < times times < div div = quot ---------------------------------------- (78) LowerBoundPropagationProof (FINISHED) Propagated lower bound. ---------------------------------------- (79) BOUNDS(n^1, INF) ---------------------------------------- (80) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Lemmas: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: times, div, quot, eq, pr They will be analysed ascendingly in the following order: times < div div = quot ---------------------------------------- (81) RewriteLemmaProof (LOWER BOUND(ID)) Proved the following rewrite lemma: times(gen_s:0'3_0(n854_0), gen_s:0'3_0(b)) -> gen_s:0'3_0(*(n854_0, b)), rt in Omega(1 + b*n854_0^2 + n854_0) Induction Base: times(gen_s:0'3_0(0), gen_s:0'3_0(b)) ->_R^Omega(1) 0' Induction Step: times(gen_s:0'3_0(+(n854_0, 1)), gen_s:0'3_0(b)) ->_R^Omega(1) plus(gen_s:0'3_0(b), times(gen_s:0'3_0(n854_0), gen_s:0'3_0(b))) ->_IH plus(gen_s:0'3_0(b), gen_s:0'3_0(*(c855_0, b))) ->_L^Omega(1 + b*n854_0) gen_s:0'3_0(+(*(n854_0, b), b)) We have rt in Omega(n^3) and sz in O(n). Thus, we have irc_R in Omega(n^3). ---------------------------------------- (82) Complex Obligation (BEST) ---------------------------------------- (83) Obligation: Proved the lower bound n^3 for the following obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Lemmas: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: times, div, quot, eq, pr They will be analysed ascendingly in the following order: times < div div = quot ---------------------------------------- (84) LowerBoundPropagationProof (FINISHED) Propagated lower bound. ---------------------------------------- (85) BOUNDS(n^3, INF) ---------------------------------------- (86) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Lemmas: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) times(gen_s:0'3_0(n854_0), gen_s:0'3_0(b)) -> gen_s:0'3_0(*(n854_0, b)), rt in Omega(1 + b*n854_0^2 + n854_0) Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: eq, div, quot, pr They will be analysed ascendingly in the following order: div = quot ---------------------------------------- (87) RewriteLemmaProof (LOWER BOUND(ID)) Proved the following rewrite lemma: eq(gen_s:0'3_0(n1961_0), gen_s:0'3_0(n1961_0)) -> true, rt in Omega(1 + n1961_0) Induction Base: eq(gen_s:0'3_0(0), gen_s:0'3_0(0)) ->_R^Omega(1) true Induction Step: eq(gen_s:0'3_0(+(n1961_0, 1)), gen_s:0'3_0(+(n1961_0, 1))) ->_R^Omega(1) eq(gen_s:0'3_0(n1961_0), gen_s:0'3_0(n1961_0)) ->_IH true We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). ---------------------------------------- (88) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Lemmas: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) times(gen_s:0'3_0(n854_0), gen_s:0'3_0(b)) -> gen_s:0'3_0(*(n854_0, b)), rt in Omega(1 + b*n854_0^2 + n854_0) eq(gen_s:0'3_0(n1961_0), gen_s:0'3_0(n1961_0)) -> true, rt in Omega(1 + n1961_0) Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: pr, div, quot They will be analysed ascendingly in the following order: div = quot ---------------------------------------- (89) RewriteLemmaProof (LOWER BOUND(ID)) Proved the following rewrite lemma: quot(gen_s:0'3_0(n2634_0), gen_s:0'3_0(+(1, n2634_0)), gen_s:0'3_0(c)) -> gen_s:0'3_0(0), rt in Omega(1 + n2634_0) Induction Base: quot(gen_s:0'3_0(0), gen_s:0'3_0(+(1, 0)), gen_s:0'3_0(c)) ->_R^Omega(1) 0' Induction Step: quot(gen_s:0'3_0(+(n2634_0, 1)), gen_s:0'3_0(+(1, +(n2634_0, 1))), gen_s:0'3_0(c)) ->_R^Omega(1) quot(gen_s:0'3_0(n2634_0), gen_s:0'3_0(+(1, n2634_0)), gen_s:0'3_0(c)) ->_IH gen_s:0'3_0(0) We have rt in Omega(n^1) and sz in O(n). Thus, we have irc_R in Omega(n). ---------------------------------------- (90) Obligation: TRS: Rules: p(s(x)) -> x plus(x, 0') -> x plus(0', y) -> y plus(s(x), y) -> s(plus(x, y)) plus(s(x), y) -> s(plus(p(s(x)), y)) plus(x, s(y)) -> s(plus(x, p(s(y)))) times(0', y) -> 0' times(s(0'), y) -> y times(s(x), y) -> plus(y, times(x, y)) div(0', y) -> 0' div(x, y) -> quot(x, y, y) quot(0', s(y), z) -> 0' quot(s(x), s(y), z) -> quot(x, y, z) quot(x, 0', s(z)) -> s(div(x, s(z))) div(div(x, y), z) -> div(x, times(y, z)) eq(0', 0') -> true eq(s(x), 0') -> false eq(0', s(y)) -> false eq(s(x), s(y)) -> eq(x, y) divides(y, x) -> eq(x, times(div(x, y), y)) prime(s(s(x))) -> pr(s(s(x)), s(x)) pr(x, s(0')) -> true pr(x, s(s(y))) -> if(divides(s(s(y)), x), x, s(y)) if(true, x, y) -> false if(false, x, y) -> pr(x, y) Types: p :: s:0' -> s:0' s :: s:0' -> s:0' plus :: s:0' -> s:0' -> s:0' 0' :: s:0' times :: s:0' -> s:0' -> s:0' div :: s:0' -> s:0' -> s:0' quot :: s:0' -> s:0' -> s:0' -> s:0' eq :: s:0' -> s:0' -> true:false true :: true:false false :: true:false divides :: s:0' -> s:0' -> true:false prime :: s:0' -> true:false pr :: s:0' -> s:0' -> true:false if :: true:false -> s:0' -> s:0' -> true:false hole_s:0'1_0 :: s:0' hole_true:false2_0 :: true:false gen_s:0'3_0 :: Nat -> s:0' Lemmas: plus(gen_s:0'3_0(a), gen_s:0'3_0(n5_0)) -> gen_s:0'3_0(+(n5_0, a)), rt in Omega(1 + n5_0) times(gen_s:0'3_0(n854_0), gen_s:0'3_0(b)) -> gen_s:0'3_0(*(n854_0, b)), rt in Omega(1 + b*n854_0^2 + n854_0) eq(gen_s:0'3_0(n1961_0), gen_s:0'3_0(n1961_0)) -> true, rt in Omega(1 + n1961_0) quot(gen_s:0'3_0(n2634_0), gen_s:0'3_0(+(1, n2634_0)), gen_s:0'3_0(c)) -> gen_s:0'3_0(0), rt in Omega(1 + n2634_0) Generator Equations: gen_s:0'3_0(0) <=> 0' gen_s:0'3_0(+(x, 1)) <=> s(gen_s:0'3_0(x)) The following defined symbols remain to be analysed: div They will be analysed ascendingly in the following order: div = quot