(0) Obligation:

JBC Problem based on JBC Program:
Manifest-Version: 1.0 Created-By: 1.6.0_22 (Sun Microsystems Inc.) Main-Class: TwoWay/TwoWay
package TwoWay;

public class Random {
static String[] args;
static int index = 0;

public static int random() {
final String string = args[index];
index++;
return string.length();
}
}


package TwoWay;

public class TwoWay {
public static void main(String[] args) {
Random.args = args;
twoWay(true, Random.random());
}

public static int twoWay(boolean terminate, int n) {
if (n < 0) {
return 1;
} else {
int m = n;
if (terminate) {
m--;
} else {
m++;
}
return m*twoWay(terminate, m);
}
}
}


(1) JBCToGraph (SOUND transformation)

Constructed TerminationGraph.

(2) Obligation:

Termination Graph based on JBC Program:
TwoWay.TwoWay.main([Ljava/lang/String;)V: Graph of 107 nodes with 0 SCCs.

TwoWay.TwoWay.twoWay(ZI)I: Graph of 30 nodes with 0 SCCs.


(3) TerminationGraphToSCCProof (SOUND transformation)

Splitted TerminationGraph to 1 SCCs.

(4) Obligation:

SCC of termination graph based on JBC Program.
SCC contains nodes from the following methods: TwoWay.TwoWay.twoWay(ZI)I
SCC calls the following helper methods: TwoWay.TwoWay.twoWay(ZI)I
Performed SCC analyses: UsedFieldsAnalysis

(5) SCCToIDPv1Proof (SOUND transformation)

Transformed FIGraph SCCs to IDPs. Log:

Generated 15 rules for P and 16 rules for R.


P rules:
285_0_twoWay_GE(EOS(STATIC_285), matching1, i32, i32) → 289_0_twoWay_GE(EOS(STATIC_289), 1, i32, i32) | =(matching1, 1)
289_0_twoWay_GE(EOS(STATIC_289), matching1, i32, i32) → 293_0_twoWay_Load(EOS(STATIC_293), 1, i32) | &&(>=(i32, 0), =(matching1, 1))
293_0_twoWay_Load(EOS(STATIC_293), matching1, i32) → 298_0_twoWay_Store(EOS(STATIC_298), 1, i32) | =(matching1, 1)
298_0_twoWay_Store(EOS(STATIC_298), matching1, i32) → 304_0_twoWay_Load(EOS(STATIC_304), 1, i32) | =(matching1, 1)
304_0_twoWay_Load(EOS(STATIC_304), matching1, i32) → 313_0_twoWay_EQ(EOS(STATIC_313), 1, i32, 1) | =(matching1, 1)
313_0_twoWay_EQ(EOS(STATIC_313), matching1, i32, matching2) → 316_0_twoWay_Inc(EOS(STATIC_316), 1, i32) | &&(&&(>(1, 0), =(matching1, 1)), =(matching2, 1))
316_0_twoWay_Inc(EOS(STATIC_316), matching1, i32) → 319_0_twoWay_JMP(EOS(STATIC_319), 1, +(i32, -1)) | &&(>=(i32, 0), =(matching1, 1))
319_0_twoWay_JMP(EOS(STATIC_319), matching1, i36) → 321_0_twoWay_Load(EOS(STATIC_321), 1, i36) | =(matching1, 1)
321_0_twoWay_Load(EOS(STATIC_321), matching1, i36) → 323_0_twoWay_Load(EOS(STATIC_323), 1, i36, i36) | =(matching1, 1)
323_0_twoWay_Load(EOS(STATIC_323), matching1, i36, i36) → 325_0_twoWay_Load(EOS(STATIC_325), i36, i36, 1) | =(matching1, 1)
325_0_twoWay_Load(EOS(STATIC_325), i36, i36, matching1) → 327_0_twoWay_InvokeMethod(EOS(STATIC_327), i36, 1, i36) | =(matching1, 1)
327_0_twoWay_InvokeMethod(EOS(STATIC_327), i36, matching1, i36) → 329_1_twoWay_InvokeMethod(329_0_twoWay_Load(EOS(STATIC_329), 1, i36), i36, 1, i36) | =(matching1, 1)
329_0_twoWay_Load(EOS(STATIC_329), matching1, i36) → 331_0_twoWay_Load(EOS(STATIC_331), 1, i36) | =(matching1, 1)
331_0_twoWay_Load(EOS(STATIC_331), matching1, i36) → 279_0_twoWay_Load(EOS(STATIC_279), 1, i36) | =(matching1, 1)
279_0_twoWay_Load(EOS(STATIC_279), matching1, i28) → 285_0_twoWay_GE(EOS(STATIC_285), 1, i28, i28) | =(matching1, 1)
R rules:
285_0_twoWay_GE(EOS(STATIC_285), matching1, matching2, matching3) → 287_0_twoWay_GE(EOS(STATIC_287), 1, -1, -1) | &&(&&(=(matching1, 1), =(matching2, -1)), =(matching3, -1))
287_0_twoWay_GE(EOS(STATIC_287), matching1, matching2, matching3) → 291_0_twoWay_ConstantStackPush(EOS(STATIC_291), 1, -1) | &&(&&(&&(<(-1, 0), =(matching1, 1)), =(matching2, -1)), =(matching3, -1))
291_0_twoWay_ConstantStackPush(EOS(STATIC_291), matching1, matching2) → 295_0_twoWay_Return(EOS(STATIC_295), 1, -1, 1) | &&(=(matching1, 1), =(matching2, -1))
329_1_twoWay_InvokeMethod(295_0_twoWay_Return(EOS(STATIC_295), matching1, matching2, matching3), matching4, matching5, matching6) → 339_0_twoWay_Return(EOS(STATIC_339), -1, 1, -1, 1, -1, 1) | &&(&&(&&(&&(&&(=(matching1, 1), =(matching2, -1)), =(matching3, 1)), =(matching4, -1)), =(matching5, 1)), =(matching6, -1))
329_1_twoWay_InvokeMethod(343_0_twoWay_Return(EOS(STATIC_343), matching1), i48, matching2, i48) → 355_0_twoWay_Return(EOS(STATIC_355), i48, 1, i48, -1) | &&(=(matching1, -1), =(matching2, 1))
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(EOS(STATIC_365), i51), i61, matching1, i61) → 394_0_twoWay_Return(EOS(STATIC_394), i61, 1, i61, i51) | =(matching1, 1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(EOS(STATIC_406), i76), i85, matching1, i85) → 425_0_twoWay_Return(EOS(STATIC_425), i85, 1, i85, i76) | =(matching1, 1)
339_0_twoWay_Return(EOS(STATIC_339), matching1, matching2, matching3, matching4, matching5, matching6) → 341_0_twoWay_IntArithmetic(EOS(STATIC_341), -1, 1) | &&(&&(&&(&&(&&(=(matching1, -1), =(matching2, 1)), =(matching3, -1)), =(matching4, 1)), =(matching5, -1)), =(matching6, 1))
341_0_twoWay_IntArithmetic(EOS(STATIC_341), matching1, matching2) → 343_0_twoWay_Return(EOS(STATIC_343), -1) | &&(=(matching1, -1), =(matching2, 1))
343_0_twoWay_Return(EOS(STATIC_343), matching1) → 365_0_twoWay_Return(EOS(STATIC_365), -1) | =(matching1, -1)
355_0_twoWay_Return(EOS(STATIC_355), i48, matching1, i48, matching2) → 395_0_twoWay_Return(EOS(STATIC_395), i48, 1, i48, -1) | &&(=(matching1, 1), =(matching2, -1))
365_0_twoWay_Return(EOS(STATIC_365), i51) → 406_0_twoWay_Return(EOS(STATIC_406), i51)
394_0_twoWay_Return(EOS(STATIC_394), i61, matching1, i61, i51) → 395_0_twoWay_Return(EOS(STATIC_395), i61, 1, i61, i51) | =(matching1, 1)
395_0_twoWay_Return(EOS(STATIC_395), i71, matching1, i71, i70) → 400_0_twoWay_IntArithmetic(EOS(STATIC_400), i71, i70) | =(matching1, 1)
400_0_twoWay_IntArithmetic(EOS(STATIC_400), i71, i70) → 406_0_twoWay_Return(EOS(STATIC_406), *(i71, i70)) | <(i70, 1)
425_0_twoWay_Return(EOS(STATIC_425), i85, matching1, i85, i76) → 395_0_twoWay_Return(EOS(STATIC_395), i85, 1, i85, i76) | =(matching1, 1)

Combined rules. Obtained 1 conditional rules for P and 5 conditional rules for R.


P rules:
285_0_twoWay_GE(EOS(STATIC_285), 1, x1, x1) → 329_1_twoWay_InvokeMethod(285_0_twoWay_GE(EOS(STATIC_285), 1, +(x1, -1), +(x1, -1)), +(x1, -1), 1, +(x1, -1)) | >(+(x1, 1), 0)
R rules:
285_0_twoWay_GE(EOS(STATIC_285), 1, -1, -1) → 295_0_twoWay_Return(EOS(STATIC_295), 1, -1, 1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return(EOS(STATIC_295), 1, -1, 1), -1, 1, -1) → 406_0_twoWay_Return(EOS(STATIC_406), -1)
329_1_twoWay_InvokeMethod(343_0_twoWay_Return(EOS(STATIC_343), -1), x1, 1, x1) → 406_0_twoWay_Return(EOS(STATIC_406), *(x1, -1))
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(EOS(STATIC_365), x0), x1, 1, x1) → 406_0_twoWay_Return(EOS(STATIC_406), *(x1, x0)) | <(x0, 1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(EOS(STATIC_406), x0), x1, 1, x1) → 406_0_twoWay_Return(EOS(STATIC_406), *(x1, x0)) | <(x0, 1)

Filtered ground terms:



329_1_twoWay_InvokeMethod(x1, x2, x3, x4) → 329_1_twoWay_InvokeMethod(x1, x2, x4)
285_0_twoWay_GE(x1, x2, x3, x4) → 285_0_twoWay_GE(x3, x4)
Cond_285_0_twoWay_GE(x1, x2, x3, x4, x5) → Cond_285_0_twoWay_GE(x1, x4, x5)
406_0_twoWay_Return(x1, x2) → 406_0_twoWay_Return(x2)
Cond_329_1_twoWay_InvokeMethod1(x1, x2, x3, x4, x5) → Cond_329_1_twoWay_InvokeMethod1(x1, x2, x3, x5)
Cond_329_1_twoWay_InvokeMethod(x1, x2, x3, x4, x5) → Cond_329_1_twoWay_InvokeMethod(x1, x2, x3, x5)
365_0_twoWay_Return(x1, x2) → 365_0_twoWay_Return(x2)
343_0_twoWay_Return(x1, x2) → 343_0_twoWay_Return
295_0_twoWay_Return(x1, x2, x3, x4) → 295_0_twoWay_Return

Filtered duplicate args:



285_0_twoWay_GE(x1, x2) → 285_0_twoWay_GE(x2)
Cond_285_0_twoWay_GE(x1, x2, x3) → Cond_285_0_twoWay_GE(x1, x3)
329_1_twoWay_InvokeMethod(x1, x2, x3) → 329_1_twoWay_InvokeMethod(x1, x3)
Cond_329_1_twoWay_InvokeMethod(x1, x2, x3, x4) → Cond_329_1_twoWay_InvokeMethod(x1, x2, x4)
Cond_329_1_twoWay_InvokeMethod1(x1, x2, x3, x4) → Cond_329_1_twoWay_InvokeMethod1(x1, x2, x4)

Combined rules. Obtained 1 conditional rules for P and 5 conditional rules for R.


P rules:
285_0_twoWay_GE(x1) → 329_1_twoWay_InvokeMethod(285_0_twoWay_GE(+(x1, -1)), +(x1, -1)) | >(x1, -1)
R rules:
285_0_twoWay_GE(-1) → 295_0_twoWay_Return
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, -1) → 406_0_twoWay_Return(-1)
329_1_twoWay_InvokeMethod(343_0_twoWay_Return, x1) → 406_0_twoWay_Return(*(x1, -1))
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(*(x1, x0)) | <(x0, 1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(*(x1, x0)) | <(x0, 1)

Performed bisimulation on rules. Used the following equivalence classes: {[295_0_twoWay_Return, 343_0_twoWay_Return]=295_0_twoWay_Return}


Finished conversion. Obtained 2 rules for P and 7 rules for R. System has predefined symbols.


P rules:
285_0_TWOWAY_GE(x1) → COND_285_0_TWOWAY_GE(>(x1, -1), x1)
COND_285_0_TWOWAY_GE(TRUE, x1) → 285_0_TWOWAY_GE(+(x1, -1))
R rules:
285_0_twoWay_GE(-1) → 295_0_twoWay_Return
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, -1) → 406_0_twoWay_Return(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x1) → 406_0_twoWay_Return(*(x1, -1))
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod(<(x0, 1), 365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(*(x1, x0))
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod1(<(x0, 1), 406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(*(x1, x0))

(6) Obligation:

IDP problem:
The following function symbols are pre-defined:
!=~Neq: (Integer, Integer) -> Boolean
*~Mul: (Integer, Integer) -> Integer
>=~Ge: (Integer, Integer) -> Boolean
-1~UnaryMinus: (Integer) -> Integer
|~Bwor: (Integer, Integer) -> Integer
/~Div: (Integer, Integer) -> Integer
=~Eq: (Integer, Integer) -> Boolean
~Bwxor: (Integer, Integer) -> Integer
||~Lor: (Boolean, Boolean) -> Boolean
!~Lnot: (Boolean) -> Boolean
<~Lt: (Integer, Integer) -> Boolean
-~Sub: (Integer, Integer) -> Integer
<=~Le: (Integer, Integer) -> Boolean
>~Gt: (Integer, Integer) -> Boolean
~~Bwnot: (Integer) -> Integer
%~Mod: (Integer, Integer) -> Integer
&~Bwand: (Integer, Integer) -> Integer
+~Add: (Integer, Integer) -> Integer
&&~Land: (Boolean, Boolean) -> Boolean


The following domains are used:

Integer


The ITRS R consists of the following rules:
285_0_twoWay_GE(-1) → 295_0_twoWay_Return
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, -1) → 406_0_twoWay_Return(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x1) → 406_0_twoWay_Return(x1 * -1)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod(x0 < 1, 365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod1(x0 < 1, 406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)

The integer pair graph contains the following rules and edges:
(0): 285_0_TWOWAY_GE(x1[0]) → COND_285_0_TWOWAY_GE(x1[0] > -1, x1[0])
(1): COND_285_0_TWOWAY_GE(TRUE, x1[1]) → 285_0_TWOWAY_GE(x1[1] + -1)

(0) -> (1), if (x1[0] > -1x1[0]* x1[1])


(1) -> (0), if (x1[1] + -1* x1[0])



The set Q consists of the following terms:
285_0_twoWay_GE(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x0)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1)

(7) IDPNonInfProof (SOUND transformation)

Used the following options for this NonInfProof:
IDPGPoloSolver: Range: [(-1,2)] IsNat: false Interpretation Shape Heuristic: aprove.DPFramework.IDPProblem.Processors.nonInf.poly.IdpCand1ShapeHeuristic@6a688d6f Constraint Generator: NonInfConstraintGenerator: PathGenerator: MetricPathGenerator: Max Left Steps: 0 Max Right Steps: 0

The constraints were generated the following way:
The DP Problem is simplified using the Induction Calculus [NONINF] with the following steps:
Note that final constraints are written in bold face.


For Pair 285_0_TWOWAY_GE(x1) → COND_285_0_TWOWAY_GE(>(x1, -1), x1) the following chains were created:
  • We consider the chain 285_0_TWOWAY_GE(x1[0]) → COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0]), COND_285_0_TWOWAY_GE(TRUE, x1[1]) → 285_0_TWOWAY_GE(+(x1[1], -1)) which results in the following constraint:

    (1)    (>(x1[0], -1)=TRUEx1[0]=x1[1]285_0_TWOWAY_GE(x1[0])≥NonInfC∧285_0_TWOWAY_GE(x1[0])≥COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])∧(UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥))



    We simplified constraint (1) using rule (IV) which results in the following new constraint:

    (2)    (>(x1[0], -1)=TRUE285_0_TWOWAY_GE(x1[0])≥NonInfC∧285_0_TWOWAY_GE(x1[0])≥COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])∧(UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥))



    We simplified constraint (2) using rule (POLY_CONSTRAINTS) which results in the following new constraint:

    (3)    (x1[0] ≥ 0 ⇒ (UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥)∧[(-1)Bound*bni_16] + [(2)bni_16]x1[0] ≥ 0∧[(-1)bso_17] ≥ 0)



    We simplified constraint (3) using rule (IDP_POLY_SIMPLIFY) which results in the following new constraint:

    (4)    (x1[0] ≥ 0 ⇒ (UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥)∧[(-1)Bound*bni_16] + [(2)bni_16]x1[0] ≥ 0∧[(-1)bso_17] ≥ 0)



    We simplified constraint (4) using rule (POLY_REMOVE_MIN_MAX) which results in the following new constraint:

    (5)    (x1[0] ≥ 0 ⇒ (UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥)∧[(-1)Bound*bni_16] + [(2)bni_16]x1[0] ≥ 0∧[(-1)bso_17] ≥ 0)







For Pair COND_285_0_TWOWAY_GE(TRUE, x1) → 285_0_TWOWAY_GE(+(x1, -1)) the following chains were created:
  • We consider the chain COND_285_0_TWOWAY_GE(TRUE, x1[1]) → 285_0_TWOWAY_GE(+(x1[1], -1)) which results in the following constraint:

    (6)    (COND_285_0_TWOWAY_GE(TRUE, x1[1])≥NonInfC∧COND_285_0_TWOWAY_GE(TRUE, x1[1])≥285_0_TWOWAY_GE(+(x1[1], -1))∧(UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥))



    We simplified constraint (6) using rule (POLY_CONSTRAINTS) which results in the following new constraint:

    (7)    ((UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥)∧[bni_18] = 0∧[2 + (-1)bso_19] ≥ 0)



    We simplified constraint (7) using rule (IDP_POLY_SIMPLIFY) which results in the following new constraint:

    (8)    ((UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥)∧[bni_18] = 0∧[2 + (-1)bso_19] ≥ 0)



    We simplified constraint (8) using rule (POLY_REMOVE_MIN_MAX) which results in the following new constraint:

    (9)    ((UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥)∧[bni_18] = 0∧[2 + (-1)bso_19] ≥ 0)



    We simplified constraint (9) using rule (IDP_UNRESTRICTED_VARS) which results in the following new constraint:

    (10)    ((UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥)∧[bni_18] = 0∧0 = 0∧[2 + (-1)bso_19] ≥ 0)







To summarize, we get the following constraints P for the following pairs.
  • 285_0_TWOWAY_GE(x1) → COND_285_0_TWOWAY_GE(>(x1, -1), x1)
    • (x1[0] ≥ 0 ⇒ (UIncreasing(COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])), ≥)∧[(-1)Bound*bni_16] + [(2)bni_16]x1[0] ≥ 0∧[(-1)bso_17] ≥ 0)

  • COND_285_0_TWOWAY_GE(TRUE, x1) → 285_0_TWOWAY_GE(+(x1, -1))
    • ((UIncreasing(285_0_TWOWAY_GE(+(x1[1], -1))), ≥)∧[bni_18] = 0∧0 = 0∧[2 + (-1)bso_19] ≥ 0)




The constraints for P> respective Pbound are constructed from P where we just replace every occurence of "t ≥ s" in P by "t > s" respective "t ≥ c". Here c stands for the fresh constant used for Pbound.
Using the following integer polynomial ordering the resulting constraints can be solved
Polynomial interpretation over integers[POLO]:

POL(TRUE) = 0   
POL(FALSE) = 0   
POL(285_0_twoWay_GE(x1)) = [-1]   
POL(-1) = [-1]   
POL(295_0_twoWay_Return) = [-1]   
POL(329_1_twoWay_InvokeMethod(x1, x2)) = [-1] + [-1]x2 + [-1]x1   
POL(406_0_twoWay_Return(x1)) = x1   
POL(*(x1, x2)) = x1·x2   
POL(365_0_twoWay_Return(x1)) = x1   
POL(Cond_329_1_twoWay_InvokeMethod(x1, x2, x3)) = [-1] + [-1]x3 + [-1]x2   
POL(<(x1, x2)) = [-1]   
POL(1) = [1]   
POL(Cond_329_1_twoWay_InvokeMethod1(x1, x2, x3)) = [-1] + [-1]x3 + [-1]x2   
POL(285_0_TWOWAY_GE(x1)) = [2]x1   
POL(COND_285_0_TWOWAY_GE(x1, x2)) = [2]x2   
POL(>(x1, x2)) = [-1]   
POL(+(x1, x2)) = x1 + x2   

The following pairs are in P>:

COND_285_0_TWOWAY_GE(TRUE, x1[1]) → 285_0_TWOWAY_GE(+(x1[1], -1))

The following pairs are in Pbound:

285_0_TWOWAY_GE(x1[0]) → COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])

The following pairs are in P:

285_0_TWOWAY_GE(x1[0]) → COND_285_0_TWOWAY_GE(>(x1[0], -1), x1[0])

There are no usable rules.

(8) Complex Obligation (AND)

(9) Obligation:

IDP problem:
The following function symbols are pre-defined:
!=~Neq: (Integer, Integer) -> Boolean
*~Mul: (Integer, Integer) -> Integer
>=~Ge: (Integer, Integer) -> Boolean
-1~UnaryMinus: (Integer) -> Integer
|~Bwor: (Integer, Integer) -> Integer
/~Div: (Integer, Integer) -> Integer
=~Eq: (Integer, Integer) -> Boolean
~Bwxor: (Integer, Integer) -> Integer
||~Lor: (Boolean, Boolean) -> Boolean
!~Lnot: (Boolean) -> Boolean
<~Lt: (Integer, Integer) -> Boolean
-~Sub: (Integer, Integer) -> Integer
<=~Le: (Integer, Integer) -> Boolean
>~Gt: (Integer, Integer) -> Boolean
~~Bwnot: (Integer) -> Integer
%~Mod: (Integer, Integer) -> Integer
&~Bwand: (Integer, Integer) -> Integer
+~Add: (Integer, Integer) -> Integer
&&~Land: (Boolean, Boolean) -> Boolean


The following domains are used:

Integer


The ITRS R consists of the following rules:
285_0_twoWay_GE(-1) → 295_0_twoWay_Return
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, -1) → 406_0_twoWay_Return(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x1) → 406_0_twoWay_Return(x1 * -1)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod(x0 < 1, 365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod1(x0 < 1, 406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)

The integer pair graph contains the following rules and edges:
(0): 285_0_TWOWAY_GE(x1[0]) → COND_285_0_TWOWAY_GE(x1[0] > -1, x1[0])


The set Q consists of the following terms:
285_0_twoWay_GE(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x0)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1)

(10) IDependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 0 SCCs with 1 less node.

(11) TRUE

(12) Obligation:

IDP problem:
The following function symbols are pre-defined:
!=~Neq: (Integer, Integer) -> Boolean
*~Mul: (Integer, Integer) -> Integer
>=~Ge: (Integer, Integer) -> Boolean
-1~UnaryMinus: (Integer) -> Integer
|~Bwor: (Integer, Integer) -> Integer
/~Div: (Integer, Integer) -> Integer
=~Eq: (Integer, Integer) -> Boolean
~Bwxor: (Integer, Integer) -> Integer
||~Lor: (Boolean, Boolean) -> Boolean
!~Lnot: (Boolean) -> Boolean
<~Lt: (Integer, Integer) -> Boolean
-~Sub: (Integer, Integer) -> Integer
<=~Le: (Integer, Integer) -> Boolean
>~Gt: (Integer, Integer) -> Boolean
~~Bwnot: (Integer) -> Integer
%~Mod: (Integer, Integer) -> Integer
&~Bwand: (Integer, Integer) -> Integer
+~Add: (Integer, Integer) -> Integer
&&~Land: (Boolean, Boolean) -> Boolean


The following domains are used:

Integer


The ITRS R consists of the following rules:
285_0_twoWay_GE(-1) → 295_0_twoWay_Return
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, -1) → 406_0_twoWay_Return(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x1) → 406_0_twoWay_Return(x1 * -1)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod(x0 < 1, 365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1) → Cond_329_1_twoWay_InvokeMethod1(x0 < 1, 406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1) → 406_0_twoWay_Return(x1 * x0)

The integer pair graph contains the following rules and edges:
(1): COND_285_0_TWOWAY_GE(TRUE, x1[1]) → 285_0_TWOWAY_GE(x1[1] + -1)


The set Q consists of the following terms:
285_0_twoWay_GE(-1)
329_1_twoWay_InvokeMethod(295_0_twoWay_Return, x0)
329_1_twoWay_InvokeMethod(365_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod(TRUE, 365_0_twoWay_Return(x0), x1)
329_1_twoWay_InvokeMethod(406_0_twoWay_Return(x0), x1)
Cond_329_1_twoWay_InvokeMethod1(TRUE, 406_0_twoWay_Return(x0), x1)

(13) IDependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 0 SCCs with 1 less node.

(14) TRUE