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