/export/starexec/sandbox2/solver/bin/starexec_run_complexity /export/starexec/sandbox2/benchmark/theBenchmark.koat /export/starexec/sandbox2/output/output_files -------------------------------------------------------------------------------- WORST_CASE(NON_POLY, ?) proof of /export/starexec/sandbox2/benchmark/theBenchmark.koat # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty The runtime complexity of the given CpxIntTrs could be proven to be BOUNDS(INF, INF). (0) CpxIntTrs (1) Loat Proof [FINISHED, 2129 ms] (2) BOUNDS(INF, INF) ---------------------------------------- (0) Obligation: Complexity Int TRS consisting of the following rules: f0(A, B, C, D) -> Com_1(f6(E, 0, C, D)) :|: TRUE f6(A, B, C, D) -> Com_1(f10(A - 1, B + 1, C, D)) :|: A >= 1 f10(A, B, C, D) -> Com_1(f14(A, B - 1, A - 1, D)) :|: B >= 1 f14(A, B, C, D) -> Com_1(f14(A, B, C - 1, 0)) :|: C >= 1 f14(A, B, C, D) -> Com_1(f14(A - 1, B + 1, C - 1, E)) :|: C >= 1 && 0 >= E + 1 f14(A, B, C, D) -> Com_1(f14(A - 1, B + 1, C - 1, E)) :|: C >= 1 && E >= 1 f14(A, B, C, D) -> Com_1(f10(A, B, C, D)) :|: 0 >= C f10(A, B, C, D) -> Com_1(f6(A, B, C, D)) :|: 0 >= B f6(A, B, C, D) -> Com_1(f25(A, B, C, D)) :|: 0 >= A The start-symbols are:[f0_4] ---------------------------------------- (1) Loat Proof (FINISHED) ### Pre-processing the ITS problem ### Initial linear ITS problem Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 8: f6 -> f25 : [ 0>=A ], cost: 1 2: f10 -> f14 : B'=-1+B, C'=-1+A, [ B>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 3: f14 -> f14 : C'=-1+C, D'=0, [ C>=1 ], cost: 1 4: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_1, [ C>=1 && 0>=1+free_1 ], cost: 1 5: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_2, [ C>=1 && free_2>=1 ], cost: 1 6: f14 -> f10 : [ 0>=C ], cost: 1 Removed unreachable and leaf rules: Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 2: f10 -> f14 : B'=-1+B, C'=-1+A, [ B>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 3: f14 -> f14 : C'=-1+C, D'=0, [ C>=1 ], cost: 1 4: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_1, [ C>=1 && 0>=1+free_1 ], cost: 1 5: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_2, [ C>=1 && free_2>=1 ], cost: 1 6: f14 -> f10 : [ 0>=C ], cost: 1 ### Simplification by acceleration and chaining ### Accelerating simple loops of location 3. Accelerating the following rules: 3: f14 -> f14 : C'=-1+C, D'=0, [ C>=1 ], cost: 1 4: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_1, [ C>=1 && 0>=1+free_1 ], cost: 1 5: f14 -> f14 : A'=-1+A, B'=1+B, C'=-1+C, D'=free_2, [ C>=1 && free_2>=1 ], cost: 1 Accelerated rule 3 with metering function C, yielding the new rule 9. Accelerated rule 4 with metering function C, yielding the new rule 10. Accelerated rule 5 with metering function C, yielding the new rule 11. Removing the simple loops: 3 4 5. Accelerated all simple loops using metering functions (where possible): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 2: f10 -> f14 : B'=-1+B, C'=-1+A, [ B>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 6: f14 -> f10 : [ 0>=C ], cost: 1 9: f14 -> f14 : C'=0, D'=0, [ C>=1 ], cost: C 10: f14 -> f14 : A'=-C+A, B'=C+B, C'=0, D'=free_1, [ C>=1 && 0>=1+free_1 ], cost: C 11: f14 -> f14 : A'=-C+A, B'=C+B, C'=0, D'=free_2, [ C>=1 && free_2>=1 ], cost: C Chained accelerated rules (with incoming rules): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 2: f10 -> f14 : B'=-1+B, C'=-1+A, [ B>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 12: f10 -> f14 : B'=-1+B, C'=0, D'=0, [ B>=1 && -1+A>=1 ], cost: A 13: f10 -> f14 : A'=1, B'=-2+A+B, C'=0, D'=free_1, [ B>=1 && -1+A>=1 && 0>=1+free_1 ], cost: A 14: f10 -> f14 : A'=1, B'=-2+A+B, C'=0, D'=free_2, [ B>=1 && -1+A>=1 && free_2>=1 ], cost: A 6: f14 -> f10 : [ 0>=C ], cost: 1 Eliminated locations (on tree-shaped paths): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 15: f10 -> f10 : B'=-1+B, C'=-1+A, [ B>=1 && 0>=-1+A ], cost: 2 16: f10 -> f10 : B'=-1+B, C'=0, D'=0, [ B>=1 && -1+A>=1 ], cost: 1+A 17: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_1, [ B>=1 && -1+A>=1 && 0>=1+free_1 ], cost: 1+A 18: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_2, [ B>=1 && -1+A>=1 && free_2>=1 ], cost: 1+A Accelerating simple loops of location 2. Accelerating the following rules: 15: f10 -> f10 : B'=-1+B, C'=-1+A, [ B>=1 && 0>=-1+A ], cost: 2 16: f10 -> f10 : B'=-1+B, C'=0, D'=0, [ B>=1 && -1+A>=1 ], cost: 1+A 17: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_1, [ B>=1 && -1+A>=1 && 0>=1+free_1 ], cost: 1+A 18: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_2, [ B>=1 && -1+A>=1 && free_2>=1 ], cost: 1+A Accelerated rule 15 with metering function B, yielding the new rule 19. Accelerated rule 16 with metering function B, yielding the new rule 20. Found no metering function for rule 17. Found no metering function for rule 18. Removing the simple loops: 15 16. Accelerated all simple loops using metering functions (where possible): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 7: f10 -> f6 : [ 0>=B ], cost: 1 17: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_1, [ B>=1 && -1+A>=1 && 0>=1+free_1 ], cost: 1+A 18: f10 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_2, [ B>=1 && -1+A>=1 && free_2>=1 ], cost: 1+A 19: f10 -> f10 : B'=0, C'=-1+A, [ B>=1 && 0>=-1+A ], cost: 2*B 20: f10 -> f10 : B'=0, C'=0, D'=0, [ B>=1 && -1+A>=1 ], cost: A*B+B Chained accelerated rules (with incoming rules): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 1: f6 -> f10 : A'=-1+A, B'=1+B, [ A>=1 ], cost: 1 21: f6 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_1, [ 1+B>=1 && -2+A>=1 && 0>=1+free_1 ], cost: 1+A 22: f6 -> f10 : A'=1, B'=-2+A+B, C'=0, D'=free_2, [ 1+B>=1 && -2+A>=1 && free_2>=1 ], cost: 1+A 23: f6 -> f10 : A'=-1+A, B'=0, C'=-2+A, [ A>=1 && 1+B>=1 && 0>=-2+A ], cost: 3+2*B 24: f6 -> f10 : A'=-1+A, B'=0, C'=0, D'=0, [ 1+B>=1 && -2+A>=1 ], cost: 2+(-1+A)*(1+B)+B 7: f10 -> f6 : [ 0>=B ], cost: 1 Eliminated locations (on tree-shaped paths): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 25: f6 -> f6 : A'=-1+A, B'=1+B, [ A>=1 && 0>=1+B ], cost: 2 26: f6 -> f6 : A'=-1+A, B'=0, C'=-2+A, [ A>=1 && 1+B>=1 && 0>=-2+A ], cost: 4+2*B 27: f6 -> f6 : A'=-1+A, B'=0, C'=0, D'=0, [ 1+B>=1 && -2+A>=1 ], cost: 3+(-1+A)*(1+B)+B 28: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && 0>=1+free_1 ], cost: 1+A 29: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && free_2>=1 ], cost: 1+A Accelerating simple loops of location 1. Accelerating the following rules: 25: f6 -> f6 : A'=-1+A, B'=1+B, [ A>=1 && 0>=1+B ], cost: 2 26: f6 -> f6 : A'=-1+A, B'=0, C'=-2+A, [ A>=1 && 1+B>=1 && 0>=-2+A ], cost: 4+2*B 27: f6 -> f6 : A'=-1+A, B'=0, C'=0, D'=0, [ 1+B>=1 && -2+A>=1 ], cost: 3+(-1+A)*(1+B)+B Accelerated rule 25 with NONTERM (after adding A<=B), yielding the new rule 30. Accelerated rule 25 with backward acceleration, yielding the new rule 31. Accelerated rule 25 with backward acceleration, yielding the new rule 32. Accelerated rule 26 with metering function A, yielding the new rule 33. Accelerated rule 27 with metering function -2+A, yielding the new rule 34. Removing the simple loops: 25 26 27. Accelerated all simple loops using metering functions (where possible): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 28: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && 0>=1+free_1 ], cost: 1+A 29: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && free_2>=1 ], cost: 1+A 30: f6 -> [8] : [ A>=1 && 0>=1+B && A<=B ], cost: INF 31: f6 -> f6 : A'=0, B'=A+B, [ A>=1 && 0>=1+B && 0>=A+B ], cost: 2*A 32: f6 -> f6 : A'=A+B, B'=0, [ A>=1 && 0>=1+B && 1+A+B>=1 ], cost: -2*B 33: f6 -> f6 : A'=0, B'=0, C'=-1, [ A>=1 && 1+B>=1 && 0>=-2+A ], cost: 4*A 34: f6 -> f6 : A'=2, B'=0, C'=0, D'=0, [ 1+B>=1 && -2+A>=1 ], cost: -5-1/2*(-2+A)^2+5/2*A+A*(-2+A) Chained accelerated rules (with incoming rules): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 35: f0 -> f6 : A'=0, B'=0, C'=-1, [ free>=1 && 0>=-2+free ], cost: 1+4*free 36: f0 -> f6 : A'=2, B'=0, C'=0, D'=0, [ -2+free>=1 ], cost: -4+5/2*free-1/2*(-2+free)^2+free*(-2+free) 28: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && 0>=1+free_1 ], cost: 1+A 29: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && free_2>=1 ], cost: 1+A Removed unreachable locations (and leaf rules with constant cost): Start location: f0 0: f0 -> f6 : A'=free, B'=0, [], cost: 1 35: f0 -> f6 : A'=0, B'=0, C'=-1, [ free>=1 && 0>=-2+free ], cost: 1+4*free 36: f0 -> f6 : A'=2, B'=0, C'=0, D'=0, [ -2+free>=1 ], cost: -4+5/2*free-1/2*(-2+free)^2+free*(-2+free) 28: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && 0>=1+free_1 ], cost: 1+A 29: f6 -> [7] : [ 1+B>=1 && -2+A>=1 && free_2>=1 ], cost: 1+A Eliminated locations (on tree-shaped paths): Start location: f0 37: f0 -> [7] : A'=free, B'=0, [ -2+free>=1 && 0>=1+free_1 ], cost: 2+free 38: f0 -> [7] : A'=free, B'=0, [ -2+free>=1 && free_2>=1 ], cost: 2+free 39: f0 -> [9] : [ free>=1 && 0>=-2+free ], cost: 1+4*free 40: f0 -> [9] : [ -2+free>=1 ], cost: -4+5/2*free-1/2*(-2+free)^2+free*(-2+free) ### Computing asymptotic complexity ### Fully simplified ITS problem Start location: f0 37: f0 -> [7] : A'=free, B'=0, [ -2+free>=1 && 0>=1+free_1 ], cost: 2+free 38: f0 -> [7] : A'=free, B'=0, [ -2+free>=1 && free_2>=1 ], cost: 2+free 39: f0 -> [9] : [ free>=1 && 0>=-2+free ], cost: 1+4*free 40: f0 -> [9] : [ -2+free>=1 ], cost: -4+5/2*free-1/2*(-2+free)^2+free*(-2+free) Computing asymptotic complexity for rule 37 Solved the limit problem by the following transformations: Created initial limit problem: -free_1 (+/+!), 2+free (+), -2+free (+/+!) [not solved] removing all constraints (solved by SMT) resulting limit problem: [solved] applying transformation rule (C) using substitution {free==n,free_1==-1} resulting limit problem: [solved] Solution: free / n free_1 / -1 Resulting cost 2+n has complexity: Unbounded Found new complexity Unbounded. Obtained the following overall complexity (w.r.t. the length of the input n): Complexity: Unbounded Cpx degree: Unbounded Solved cost: 2+n Rule cost: 2+free Rule guard: [ -2+free>=1 && 0>=1+free_1 ] WORST_CASE(INF,?) ---------------------------------------- (2) BOUNDS(INF, INF)