Initial Problem

Start: l0
Program_Vars: X₀, X₁, X₂
Temp_Vars: D
Locations: l0, l1, l2
Transitions:
t₀: l0(X₀, X₁, X₂) → l1(0, X₁, X₂)
t₁: l1(X₀, X₁, X₂) → l1(X₀, X₁-1, D) :|: 1 ≤ X₁ ∧ 1 ≤ D
t₂: l1(X₀, X₁, X₂) → l1(X₀, X₁-2, D) :|: 1 ≤ X₁ ∧ D ≤ 0
t₃: l1(X₀, X₁, X₂) → l2(X₀, X₁, D) :|: X₁ ≤ 0
t₄: l2(X₀, X₁, X₂) → l2(1, X₁, D) :|: 1 ≤ X₂
t₅: l2(X₀, X₁, X₂) → l2(2, X₁, D) :|: X₂ ≤ 0

Preprocessing

Eliminate variables {X₀} that do not contribute to the problem

Found invariant X₁ ≤ 0 for location l2

Problem after Preprocessing

Start: l0
Program_Vars: X₁, X₂
Temp_Vars: D
Locations: l0, l1, l2
Transitions:
t₁₄: l0(X₁, X₂) → l1(X₁, X₂)
t₁₅: l1(X₁, X₂) → l1(X₁-1, D) :|: 1 ≤ X₁ ∧ 1 ≤ D
t₁₆: l1(X₁, X₂) → l1(X₁-2, D) :|: 1 ≤ X₁ ∧ D ≤ 0
t₁₇: l1(X₁, X₂) → l2(X₁, D) :|: X₁ ≤ 0
t₁₈: l2(X₁, X₂) → l2(X₁, D) :|: 1 ≤ X₂ ∧ X₁ ≤ 0
t₁₉: l2(X₁, X₂) → l2(X₁, D) :|: X₂ ≤ 0 ∧ X₁ ≤ 0

MPRF for transition t₁₅: l1(X₁, X₂) → l1(X₁-1, D) :|: 1 ≤ X₁ ∧ 1 ≤ D of depth 1:

new bound:

X₁ {O(n)}

MPRF:

l1 [X₁ ]

MPRF for transition t₁₆: l1(X₁, X₂) → l1(X₁-2, D) :|: 1 ≤ X₁ ∧ D ≤ 0 of depth 1:

new bound:

X₁ {O(n)}

MPRF:

l1 [X₁ ]

Analysing control-flow refined program

Found invariant X₁ ≤ 0 for location l2

CFR did not improve the program. Rolling back

All Bounds

Timebounds

Overall timebound:inf {Infinity}
t₁₄: 1 {O(1)}
t₁₅: X₁ {O(n)}
t₁₆: X₁ {O(n)}
t₁₇: 1 {O(1)}
t₁₈: inf {Infinity}
t₁₉: inf {Infinity}

Costbounds

Overall costbound: inf {Infinity}
t₁₄: 1 {O(1)}
t₁₅: X₁ {O(n)}
t₁₆: X₁ {O(n)}
t₁₇: 1 {O(1)}
t₁₈: inf {Infinity}
t₁₉: inf {Infinity}

Sizebounds

t₁₄, X₁: X₁ {O(n)}
t₁₄, X₂: X₂ {O(n)}
t₁₅, X₁: 2⋅X₁ {O(n)}
t₁₆, X₁: 2⋅X₁ {O(n)}
t₁₇, X₁: 5⋅X₁ {O(n)}
t₁₈, X₁: 10⋅X₁ {O(n)}
t₁₉, X₁: 10⋅X₁ {O(n)}