Trying to load file: main.koat Initial Control flow graph problem: Start location: f2 0: f2 -> f300 : [], cost: 1 1: f300 -> f300 : A'=1+A, C'=free, [ free>=1 && B>=1+A ], cost: 1 2: f300 -> f300 : A'=1+A, C'=free_1, [ 0>=1+free_1 && B>=1+A ], cost: 1 3: f300 -> f300 : B'=-1+B, C'=0, [ B>=1+A ], cost: 1 4: f300 -> f1 : D'=free_2, [ A>=B ], cost: 1 Simplified the transitions: Start location: f2 0: f2 -> f300 : [], cost: 1 1: f300 -> f300 : A'=1+A, C'=free, [ free>=1 && B>=1+A ], cost: 1 2: f300 -> f300 : A'=1+A, C'=free_1, [ 0>=1+free_1 && B>=1+A ], cost: 1 3: f300 -> f300 : B'=-1+B, C'=0, [ B>=1+A ], cost: 1 Eliminating 3 self-loops for location f300 Self-Loop 1 has the metering function: B-A, resulting in the new transition 5. Self-Loop 2 has the metering function: B-A, resulting in the new transition 6. Self-Loop 3 has the metering function: B-A, resulting in the new transition 7. Removing the self-loops: 1 2 3. Removed all Self-loops using metering functions (where possible): Start location: f2 0: f2 -> f300 : [], cost: 1 5: f300 -> [3] : A'=B, C'=free, [ free>=1 && B>=1+A ], cost: B-A 6: f300 -> [3] : A'=B, C'=free_1, [ 0>=1+free_1 && B>=1+A ], cost: B-A 7: f300 -> [3] : B'=A, C'=0, [ B>=1+A ], cost: B-A Applied chaining over branches and pruning: Start location: f2 8: f2 -> [3] : A'=B, C'=free, [ free>=1 && B>=1+A ], cost: 1+B-A 9: f2 -> [3] : A'=B, C'=free_1, [ 0>=1+free_1 && B>=1+A ], cost: 1+B-A 10: f2 -> [3] : B'=A, C'=0, [ B>=1+A ], cost: 1+B-A Final control flow graph problem, now checking costs for infinitely many models: Start location: f2 8: f2 -> [3] : A'=B, C'=free, [ free>=1 && B>=1+A ], cost: 1+B-A 9: f2 -> [3] : A'=B, C'=free_1, [ 0>=1+free_1 && B>=1+A ], cost: 1+B-A 10: f2 -> [3] : B'=A, C'=0, [ B>=1+A ], cost: 1+B-A Computing complexity for remaining 3 transitions. Found configuration with infinitely models for cost: 1+B-A and guard: free>=1 && B>=1+A: B: Pos, free: Pos, A: Pos, where: B > A Found new complexity n^1, because: Found infinity configuration. The final runtime is determined by this resulting transition: Final Guard: free>=1 && B>=1+A Final Cost: 1+B-A Obtained the following complexity w.r.t. the length of the input n: Complexity class: n^1 Complexity value: 1 WORST_CASE(Omega(n^1),?)