Termination of the following Term Rewriting System could not be shown:

Context-sensitive rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The replacement map contains the following entries:

p: {1}
0: empty set
s: {1}
leq: {1, 2}
true: empty set
false: empty set
if: {1}
diff: {1, 2}


CSR
  ↳ CSRInnermostProof

Context-sensitive rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The replacement map contains the following entries:

p: {1}
0: empty set
s: {1}
leq: {1, 2}
true: empty set
false: empty set
if: {1}
diff: {1, 2}

The CSR is orthogonal. By [10] we can switch to innermost.

↳ CSR
  ↳ CSRInnermostProof
CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Context-sensitive rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The replacement map contains the following entries:

p: {1}
0: empty set
s: {1}
leq: {1, 2}
true: empty set
false: empty set
if: {1}
diff: {1, 2}

Innermost Strategy.

Using Improved CS-DPs we result in the following initial Q-CSDP problem.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
QCSDP
          ↳ QCSDependencyGraphProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, LEQ, DIFF, P} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The ordinary context-sensitive dependency pairs DPo are:

LEQ(s(X), s(Y)) → LEQ(X, Y)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
DIFF(X, Y) → LEQ(X, Y)

The collapsing dependency pairs are DPc:

IF(true, X, Y) → X
IF(false, X, Y) → Y


The hidden terms of R are:

diff(p(X), Y)
p(X)

Every hiding context is built from:

p on positions {1}
diff on positions {1, 2}
s on positions {1}

Hence, the new unhiding pairs DPu are :

IF(true, X, Y) → U(X)
IF(false, X, Y) → U(Y)
U(p(x_0)) → U(x_0)
U(diff(x_0, x_1)) → U(x_0)
U(diff(x_0, x_1)) → U(x_1)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
U(p(X)) → P(X)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


The approximation of the Context-Sensitive Dependency Graph contains 2 SCCs with 2 less nodes.


↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
QCSDP
                ↳ QCSDPSubtermProof
              ↳ QCSDP
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, LEQ} are replacing on all positions.
For all symbols f in {if} we have µ(f) = {1}.

The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


We use the subterm processor [20].


The following pairs can be oriented strictly and are deleted.


LEQ(s(X), s(Y)) → LEQ(X, Y)
The remaining pairs can at least be oriented weakly.
none
Used ordering: Combined order from the following AFS and order.
LEQ(x1, x2)  =  x1

Subterm Order


↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
                ↳ QCSDPSubtermProof
QCSDP
                    ↳ PIsEmptyProof
              ↳ QCSDP
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff} are replacing on all positions.
For all symbols f in {if} we have µ(f) = {1}.

The TRS P consists of the following rules:
none

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


The TRS P is empty. Hence, there is no (P,Q,R,µ)-chain.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
QCSDP
                ↳ QCSDPReductionPairProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(true, X, Y) → U(X)
U(p(x_0)) → U(x_0)
U(diff(x_0, x_1)) → U(x_0)
U(diff(x_0, x_1)) → U(x_1)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
IF(false, X, Y) → U(Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using the order
Polynomial interpretation with max and min functions [25]:

POL(0) = 0   
POL(DIFF(x1, x2)) = 1 + x1 + x2   
POL(IF(x1, x2, x3)) = x2 + x3   
POL(U(x1)) = x1   
POL(diff(x1, x2)) = 1 + x1 + x2   
POL(false) = 0   
POL(if(x1, x2, x3)) = x2 + max(x2, x3)   
POL(leq(x1, x2)) = 0   
POL(p(x1)) = x1   
POL(s(x1)) = x1   
POL(true) = 0   

the following usable rules

leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
p(0) → 0
p(s(X)) → X
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))
if(true, X, Y) → X
if(false, X, Y) → Y

could all be oriented weakly.
Furthermore, the pairs

U(diff(x_0, x_1)) → U(x_0)
U(diff(x_0, x_1)) → U(x_1)

could be oriented strictly and thus removed.
The pairs

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(true, X, Y) → U(X)
U(p(x_0)) → U(x_0)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
IF(false, X, Y) → U(Y)

could only be oriented weakly and must be analyzed further.


↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
QCSDP
                    ↳ QCSDPReductionPairProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(true, X, Y) → U(X)
U(p(x_0)) → U(x_0)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
IF(false, X, Y) → U(Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using the order
Polynomial Order [21,25] with Interpretation:

POL( DIFF(x1, x2) ) = max{0, -1}


POL( if(x1, ..., x3) ) = 2x2 + 2x3


POL( diff(x1, x2) ) = 0


POL( U(x1) ) = x1


POL( true ) = max{0, -1}


POL( false ) = max{0, -1}


POL( s(x1) ) = 2x1


POL( p(x1) ) = x1 + 1


POL( IF(x1, ..., x3) ) = 2x2 + 2x3


POL( 0 ) = max{0, -1}


POL( leq(x1, x2) ) = max{0, -1}



the following usable rules

leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
p(0) → 0
p(s(X)) → X
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))
if(true, X, Y) → X
if(false, X, Y) → Y

could all be oriented weakly.
Furthermore, the pairs

U(p(x_0)) → U(x_0)

could be oriented strictly and thus removed.
The pairs

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(true, X, Y) → U(X)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
IF(false, X, Y) → U(Y)

could only be oriented weakly and must be analyzed further.


↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
QCSDP
                        ↳ QCSDPInstantiationProcessor
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(true, X, Y) → U(X)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
IF(false, X, Y) → U(Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using the Context-Sensitive Instantiation Processor
the pair IF(true, X, Y) → U(X)
was transformed to the following new pairs:

IF(true, 0, s(diff(p(z0), z1))) → U(0)



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
QCSDP
                            ↳ QCSDependencyGraphProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

IF(true, 0, s(diff(p(z0), z1))) → U(0)
IF(false, X, Y) → U(Y)
U(diff(p(X), Y)) → DIFF(p(X), Y)
U(s(x_0)) → U(x_0)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


The approximation of the Context-Sensitive Dependency Graph contains 1 SCC with 1 less node.
The rules IF(true, 0, s(diff(p(z0), z1))) → U(0) and U(s(x0)) → U(x0) form no chain, because ECapµ(U(0)) = U(0) does not unify with U(s(x0)). The rules IF(true, 0, s(diff(p(z0), z1))) → U(0) and U(diff(p(x0), x1)) → DIFF(p(x0), x1) form no chain, because ECapµ(U(0)) = U(0) does not unify with U(diff(p(x0), x1)).

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
QCSDP
                                ↳ QCSDPInstantiationProcessor
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

IF(false, X, Y) → U(Y)
U(s(x_0)) → U(x_0)
U(diff(p(X), Y)) → DIFF(p(X), Y)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using the Context-Sensitive Instantiation Processor
the pair IF(false, X, Y) → U(Y)
was transformed to the following new pairs:

IF(false, 0, s(diff(p(z0), z1))) → U(s(diff(p(z0), z1)))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
                              ↳ QCSDP
                                ↳ QCSDPInstantiationProcessor
QCSDP
                                    ↳ QCSDPForwardInstantiationProcessor
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

U(diff(p(X), Y)) → DIFF(p(X), Y)
U(s(x_0)) → U(x_0)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(false, 0, s(diff(p(z0), z1))) → U(s(diff(p(z0), z1)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using the Context-Sensitive Forward Instantiation Processor
the pair U(s(x_0)) → U(x_0)
was transformed to the following new pairs:

U(s(s(z0))) → U(s(z0))
U(s(diff(p(z0), z1))) → U(diff(p(z0), z1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
                              ↳ QCSDP
                                ↳ QCSDPInstantiationProcessor
                                  ↳ QCSDP
                                    ↳ QCSDPForwardInstantiationProcessor
QCSDP
                                        ↳ QCSDependencyGraphProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

U(s(diff(p(z0), z1))) → U(diff(p(z0), z1))
U(diff(p(X), Y)) → DIFF(p(X), Y)
U(s(s(z0))) → U(s(z0))
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(false, 0, s(diff(p(z0), z1))) → U(s(diff(p(z0), z1)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


The approximation of the Context-Sensitive Dependency Graph contains 2 SCCs.
The rules IF(false, 0, s(diff(p(z0), z1))) → U(s(diff(p(z0), z1))) and U(s(s(x0))) → U(s(x0)) form no chain, because ECapµ(U(s(diff(p(z0), z1)))) = U(s(diff(p(z0), z1))) does not unify with U(s(s(x0))). The rules U(s(s(z0))) → U(s(z0)) and U(diff(p(x0), x1)) → DIFF(p(x0), x1) form no chain, because ECapµ(U(s(z0))) = U(s(z0)) does not unify with U(diff(p(x0), x1)). The rules U(s(diff(p(z0), z1))) → U(diff(p(z0), z1)) and U(s(diff(p(x0), x1))) → U(diff(p(x0), x1)) form no chain, because ECapµ(U(diff(p(z0), z1))) = U(diff(p(z0), z1)) does not unify with U(s(diff(p(x0), x1))).

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
                              ↳ QCSDP
                                ↳ QCSDPInstantiationProcessor
                                  ↳ QCSDP
                                    ↳ QCSDPForwardInstantiationProcessor
                                      ↳ QCSDP
                                        ↳ QCSDependencyGraphProof
                                          ↳ AND
QCSDP
                                              ↳ QCSDPSubtermProof
                                            ↳ QCSDP
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff} are replacing on all positions.
For all symbols f in {if} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

U(s(s(z0))) → U(s(z0))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


We use the subterm processor [20].


The following pairs can be oriented strictly and are deleted.


U(s(s(z0))) → U(s(z0))
The remaining pairs can at least be oriented weakly.
none
Used ordering: Combined order from the following AFS and order.
U(x1)  =  x1

Subterm Order


↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
                              ↳ QCSDP
                                ↳ QCSDPInstantiationProcessor
                                  ↳ QCSDP
                                    ↳ QCSDPForwardInstantiationProcessor
                                      ↳ QCSDP
                                        ↳ QCSDependencyGraphProof
                                          ↳ AND
                                            ↳ QCSDP
                                              ↳ QCSDPSubtermProof
QCSDP
                                                  ↳ PIsEmptyProof
                                            ↳ QCSDP
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff} are replacing on all positions.
For all symbols f in {if} we have µ(f) = {1}.

The TRS P consists of the following rules:
none

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


The TRS P is empty. Hence, there is no (P,Q,R,µ)-chain.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
        ↳ QCSDP
          ↳ QCSDependencyGraphProof
            ↳ AND
              ↳ QCSDP
              ↳ QCSDP
                ↳ QCSDPReductionPairProof
                  ↳ QCSDP
                    ↳ QCSDPReductionPairProof
                      ↳ QCSDP
                        ↳ QCSDPInstantiationProcessor
                          ↳ QCSDP
                            ↳ QCSDependencyGraphProof
                              ↳ QCSDP
                                ↳ QCSDPInstantiationProcessor
                                  ↳ QCSDP
                                    ↳ QCSDPForwardInstantiationProcessor
                                      ↳ QCSDP
                                        ↳ QCSDependencyGraphProof
                                          ↳ AND
                                            ↳ QCSDP
QCSDP
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q-restricted context-sensitive dependency pair problem:
The symbols in {p, s, leq, diff, DIFF} are replacing on all positions.
For all symbols f in {if, IF} we have µ(f) = {1}.
The symbols in {U} are not replacing on any position.

The TRS P consists of the following rules:

DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
IF(false, 0, s(diff(p(z0), z1))) → U(s(diff(p(z0), z1)))
U(s(diff(p(z0), z1))) → U(diff(p(z0), z1))
U(diff(p(X), Y)) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


We applied the Zantema transformation [34] to transform the context-sensitive TRS to a usual TRS.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
QTRS
          ↳ DependencyPairsProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q restricted rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))
a(x) → x
s(x1) → sInact(x1)
a(sInact(x1)) → s(x1)
00Inact
a(0Inact) → 0

Q is empty.

Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

IF(true, X, Y) → A(X)
IF(false, X, Y) → A(Y)
DIFF(X, Y) → DIFF(p(X), Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
DIFF(X, Y) → P(X)
DIFF(X, Y) → LEQ(X, Y)
A(sInact(x1)) → S(x1)
A(0Inact) → 01
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))
a(x) → x
s(x1) → sInact(x1)
a(sInact(x1)) → s(x1)
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
QDP
              ↳ DependencyGraphProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

IF(true, X, Y) → A(X)
IF(false, X, Y) → A(Y)
DIFF(X, Y) → DIFF(p(X), Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
DIFF(X, Y) → P(X)
DIFF(X, Y) → LEQ(X, Y)
A(sInact(x1)) → S(x1)
A(0Inact) → 01
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))
a(x) → x
s(x1) → sInact(x1)
a(sInact(x1)) → s(x1)
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 2 SCCs with 7 less nodes.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))
a(x) → x
s(x1) → sInact(x1)
a(sInact(x1)) → s(x1)
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We can use the usable rules and reduction pair processor [15] with the Ce-compatible extension of the polynomial order that maps every function symbol to the sum of its argument. Then, we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QDPSizeChangeProof
                  ↳ QDP
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

R is empty.
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
QDP
                    ↳ UsableRulesProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diff(p(X), Y)))
a(x) → x
s(x1) → sInact(x1)
a(sInact(x1)) → s(x1)
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We can use the usable rules and reduction pair processor [15] with the Ce-compatible extension of the polynomial order that maps every function symbol to the sum of its argument. Then, we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ UsableRulesReductionPairsProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
00Inact

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By using the usable rules with reduction pair processor [15] with a polynomial ordering [25], all dependency pairs and the corresponding usable rules [17] can be oriented non-strictly. All non-usable rules are removed, and those dependency pairs and usable rules that have been oriented strictly or contain non-usable symbols in their left-hand side are removed as well.

No dependency pairs are removed.

The following rules are removed from R:

p(s(X)) → X
Used ordering: POLO with Polynomial interpretation [25]:

POL(0) = 0   
POL(0Inact) = 0   
POL(DIFF(x1, x2)) = 2·x1 + x2   
POL(p(x1)) = x1   
POL(s(x1)) = x1   



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ UsableRulesReductionPairsProof
QDP
                            ↳ RuleRemovalProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
00Inact

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By using the rule removal processor [15] with the following polynomial ordering [25], at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented.

Strictly oriented rules of the TRS R:

00Inact

Used ordering: POLO with Polynomial interpretation [25]:

POL(0) = 2   
POL(0Inact) = 1   
POL(DIFF(x1, x2)) = 2·x1 + x2   
POL(p(x1)) = x1   



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ UsableRulesReductionPairsProof
                          ↳ QDP
                            ↳ RuleRemovalProof
QDP
                                ↳ MNOCProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the modular non-overlap check [15] to enlarge Q to all left-hand sides of R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ UsableRulesReductionPairsProof
                          ↳ QDP
                            ↳ RuleRemovalProof
                              ↳ QDP
                                ↳ MNOCProof
QDP
                                    ↳ MNOCProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

The set Q consists of the following terms:

p(0)

We have to consider all minimal (P,Q,R)-chains.
We use the modular non-overlap check [17] to decrease Q to the empty set.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ UsableRulesReductionPairsProof
                          ↳ QDP
                            ↳ RuleRemovalProof
                              ↳ QDP
                                ↳ MNOCProof
                                  ↳ QDP
                                    ↳ MNOCProof
QDP
                                        ↳ NonTerminationProof
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0


s = DIFF(X, Y) evaluates to t =DIFF(p(X), Y)

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from DIFF(X, Y) to DIFF(p(X), Y).




We applied the Innermost Giesl Middeldorp transformation [10] to transform the context-sensitive TRS to a usual TRS.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
QTRS
          ↳ DependencyPairsProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q restricted rewrite system:
The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))


Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
DIFF(active(x1), x2) → DIFF(x1, x2)
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(x1)) → ACTIVE(p(mark(x1)))
P(mark(x1)) → P(x1)
ACTIVE(diff(X, Y)) → LEQ(X, Y)
ACTIVE(p(0)) → MARK(0)
LEQ(mark(x1), x2) → LEQ(x1, x2)
ACTIVE(diff(X, Y)) → P(X)
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(true) → ACTIVE(true)
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(s(x1)) → ACTIVE(s(mark(x1)))
DIFF(mark(x1), x2) → DIFF(x1, x2)
LEQ(x1, mark(x2)) → LEQ(x1, x2)
MARK(leq(x1, x2)) → MARK(x1)
LEQ(x1, active(x2)) → LEQ(x1, x2)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(p(x1)) → MARK(x1)
ACTIVE(diff(X, Y)) → DIFF(p(X), Y)
ACTIVE(diff(X, Y)) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
DIFF(x1, active(x2)) → DIFF(x1, x2)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(s(x1)) → S(mark(x1))
S(active(x1)) → S(x1)
S(mark(x1)) → S(x1)
MARK(if(x1, x2, x3)) → IF(mark(x1), x2, x3)
MARK(false) → ACTIVE(false)
P(active(x1)) → P(x1)
ACTIVE(leq(s(X), s(Y))) → LEQ(X, Y)
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
IF(mark(x1), x2, x3) → IF(x1, x2, x3)
IF(active(x1), x2, x3) → IF(x1, x2, x3)
MARK(leq(x1, x2)) → LEQ(mark(x1), mark(x2))
ACTIVE(leq(s(X), 0)) → MARK(false)
MARK(p(x1)) → P(mark(x1))
ACTIVE(diff(X, Y)) → S(diff(p(X), Y))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
DIFF(x1, mark(x2)) → DIFF(x1, x2)
LEQ(active(x1), x2) → LEQ(x1, x2)
MARK(diff(x1, x2)) → DIFF(mark(x1), mark(x2))
MARK(0) → ACTIVE(0)
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
ACTIVE(if(true, X, Y)) → MARK(X)
ACTIVE(leq(0, Y)) → MARK(true)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
QDP
              ↳ DependencyGraphProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
DIFF(active(x1), x2) → DIFF(x1, x2)
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(x1)) → ACTIVE(p(mark(x1)))
P(mark(x1)) → P(x1)
ACTIVE(diff(X, Y)) → LEQ(X, Y)
ACTIVE(p(0)) → MARK(0)
LEQ(mark(x1), x2) → LEQ(x1, x2)
ACTIVE(diff(X, Y)) → P(X)
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(true) → ACTIVE(true)
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(s(x1)) → ACTIVE(s(mark(x1)))
DIFF(mark(x1), x2) → DIFF(x1, x2)
LEQ(x1, mark(x2)) → LEQ(x1, x2)
MARK(leq(x1, x2)) → MARK(x1)
LEQ(x1, active(x2)) → LEQ(x1, x2)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(p(x1)) → MARK(x1)
ACTIVE(diff(X, Y)) → DIFF(p(X), Y)
ACTIVE(diff(X, Y)) → IF(leq(X, Y), 0, s(diff(p(X), Y)))
DIFF(x1, active(x2)) → DIFF(x1, x2)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(s(x1)) → S(mark(x1))
S(active(x1)) → S(x1)
S(mark(x1)) → S(x1)
MARK(if(x1, x2, x3)) → IF(mark(x1), x2, x3)
MARK(false) → ACTIVE(false)
P(active(x1)) → P(x1)
ACTIVE(leq(s(X), s(Y))) → LEQ(X, Y)
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
IF(mark(x1), x2, x3) → IF(x1, x2, x3)
IF(active(x1), x2, x3) → IF(x1, x2, x3)
MARK(leq(x1, x2)) → LEQ(mark(x1), mark(x2))
ACTIVE(leq(s(X), 0)) → MARK(false)
MARK(p(x1)) → P(mark(x1))
ACTIVE(diff(X, Y)) → S(diff(p(X), Y))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
DIFF(x1, mark(x2)) → DIFF(x1, x2)
LEQ(active(x1), x2) → LEQ(x1, x2)
MARK(diff(x1, x2)) → DIFF(mark(x1), mark(x2))
MARK(0) → ACTIVE(0)
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
ACTIVE(if(true, X, Y)) → MARK(X)
ACTIVE(leq(0, Y)) → MARK(true)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 6 SCCs with 17 less nodes.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(x1, active(x2)) → DIFF(x1, x2)
DIFF(active(x1), x2) → DIFF(x1, x2)
DIFF(x1, mark(x2)) → DIFF(x1, x2)
DIFF(mark(x1), x2) → DIFF(x1, x2)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QReductionProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(x1, active(x2)) → DIFF(x1, x2)
DIFF(active(x1), x2) → DIFF(x1, x2)
DIFF(x1, mark(x2)) → DIFF(x1, x2)
DIFF(mark(x1), x2) → DIFF(x1, x2)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(active(x0))
p(mark(x0))
s(active(x0))
s(mark(x0))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ QReductionProof
QDP
                            ↳ QDPSizeChangeProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(x1, active(x2)) → DIFF(x1, x2)
DIFF(active(x1), x2) → DIFF(x1, x2)
DIFF(x1, mark(x2)) → DIFF(x1, x2)
DIFF(mark(x1), x2) → DIFF(x1, x2)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
mark(0)
mark(s(x0))
mark(leq(x0, x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
mark(diff(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

IF(active(x1), x2, x3) → IF(x1, x2, x3)
IF(mark(x1), x2, x3) → IF(x1, x2, x3)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QReductionProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

IF(active(x1), x2, x3) → IF(x1, x2, x3)
IF(mark(x1), x2, x3) → IF(x1, x2, x3)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(active(x0))
p(mark(x0))
s(active(x0))
s(mark(x0))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ QReductionProof
QDP
                            ↳ QDPSizeChangeProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

IF(mark(x1), x2, x3) → IF(x1, x2, x3)
IF(active(x1), x2, x3) → IF(x1, x2, x3)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
mark(0)
mark(s(x0))
mark(leq(x0, x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
mark(diff(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(active(x1), x2) → LEQ(x1, x2)
LEQ(x1, mark(x2)) → LEQ(x1, x2)
LEQ(x1, active(x2)) → LEQ(x1, x2)
LEQ(mark(x1), x2) → LEQ(x1, x2)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QReductionProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(active(x1), x2) → LEQ(x1, x2)
LEQ(x1, mark(x2)) → LEQ(x1, x2)
LEQ(x1, active(x2)) → LEQ(x1, x2)
LEQ(mark(x1), x2) → LEQ(x1, x2)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(active(x0))
p(mark(x0))
s(active(x0))
s(mark(x0))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ QReductionProof
QDP
                            ↳ QDPSizeChangeProof
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(active(x1), x2) → LEQ(x1, x2)
LEQ(x1, mark(x2)) → LEQ(x1, x2)
LEQ(x1, active(x2)) → LEQ(x1, x2)
LEQ(mark(x1), x2) → LEQ(x1, x2)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
mark(0)
mark(s(x0))
mark(leq(x0, x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
mark(diff(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

S(active(x1)) → S(x1)
S(mark(x1)) → S(x1)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QReductionProof
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

S(active(x1)) → S(x1)
S(mark(x1)) → S(x1)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(active(x0))
p(mark(x0))
s(active(x0))
s(mark(x0))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ QReductionProof
QDP
                            ↳ QDPSizeChangeProof
                  ↳ QDP
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

S(mark(x1)) → S(x1)
S(active(x1)) → S(x1)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
mark(0)
mark(s(x0))
mark(leq(x0, x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
mark(diff(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
QDP
                    ↳ UsableRulesProof
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

P(active(x1)) → P(x1)
P(mark(x1)) → P(x1)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QReductionProof
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

P(active(x1)) → P(x1)
P(mark(x1)) → P(x1)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(active(x0))
p(mark(x0))
s(active(x0))
s(mark(x0))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ QReductionProof
QDP
                            ↳ QDPSizeChangeProof
                  ↳ QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

P(active(x1)) → P(x1)
P(mark(x1)) → P(x1)

R is empty.
The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
mark(0)
mark(s(x0))
mark(leq(x0, x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
mark(diff(x0, x1))

We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
QDP
                    ↳ QDPOrderProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(x1)) → ACTIVE(p(mark(x1)))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(s(x1)) → ACTIVE(s(mark(x1)))
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(x1)) → MARK(x1)
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


MARK(s(x1)) → ACTIVE(s(mark(x1)))
The remaining pairs can at least be oriented weakly.

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(x1)) → ACTIVE(p(mark(x1)))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(x1)) → MARK(x1)
ACTIVE(if(true, X, Y)) → MARK(X)
Used ordering: Polynomial interpretation [25]:

POL(0) = 0   
POL(ACTIVE(x1)) = x1   
POL(MARK(x1)) = 1   
POL(active(x1)) = 0   
POL(diff(x1, x2)) = 1   
POL(false) = 0   
POL(if(x1, x2, x3)) = 1   
POL(leq(x1, x2)) = 1   
POL(mark(x1)) = 0   
POL(p(x1)) = 1   
POL(s(x1)) = 0   
POL(true) = 0   

The following usable rules [17] were oriented:

if(mark(x1), x2, x3) → if(x1, x2, x3)
if(active(x1), x2, x3) → if(x1, x2, x3)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(active(x1), x2) → diff(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
p(mark(x1)) → p(x1)
p(active(x1)) → p(x1)
s(mark(x1)) → s(x1)
s(active(x1)) → s(x1)



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
QDP
                        ↳ Narrowing
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(x1)) → ACTIVE(p(mark(x1)))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(x1)) → MARK(x1)
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By narrowing [15] the rule MARK(p(x1)) → ACTIVE(p(mark(x1))) at position [0] we obtained the following new rules:

MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(p(true)) → ACTIVE(p(active(true)))
MARK(p(false)) → ACTIVE(p(active(false)))
MARK(p(0)) → ACTIVE(p(active(0)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
QDP
                            ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(p(true)) → ACTIVE(p(active(true)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(p(x1)) → MARK(x1)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(false)) → ACTIVE(p(active(false)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(0)) → ACTIVE(p(active(0)))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(p(true)) → ACTIVE(p(active(true))) at position [0] we obtained the following new rules:

MARK(p(true)) → ACTIVE(p(true))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
QDP
                                ↳ DependencyGraphProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(x1, x2)) → MARK(x2)
MARK(diff(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(p(x1)) → MARK(x1)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(true)) → ACTIVE(p(true))
MARK(p(false)) → ACTIVE(p(active(false)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(0)) → ACTIVE(p(active(0)))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 1 SCC with 1 less node.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
QDP
                                    ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(false)) → ACTIVE(p(active(false)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(0)) → ACTIVE(p(active(0)))
MARK(p(x1)) → MARK(x1)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(p(false)) → ACTIVE(p(active(false))) at position [0] we obtained the following new rules:

MARK(p(false)) → ACTIVE(p(false))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
QDP
                                        ↳ DependencyGraphProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(leq(x1, x2)) → MARK(x2)
MARK(diff(x1, x2)) → MARK(x2)
MARK(p(x0)) → ACTIVE(p(x0))
ACTIVE(p(s(X))) → MARK(X)
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(p(false)) → ACTIVE(p(false))
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(0)) → ACTIVE(p(active(0)))
MARK(p(x1)) → MARK(x1)
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 1 SCC with 1 less node.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
QDP
                                            ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(0)) → ACTIVE(p(active(0)))
MARK(p(x1)) → MARK(x1)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(p(0)) → ACTIVE(p(active(0))) at position [0] we obtained the following new rules:

MARK(p(0)) → ACTIVE(p(0))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
QDP
                                                ↳ DependencyGraphProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(x1)) → MARK(x1)
MARK(p(0)) → ACTIVE(p(0))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(leq(x1, x2)) → MARK(x2)
MARK(diff(x1, x2)) → MARK(x2)
MARK(p(x0)) → ACTIVE(p(x0))
ACTIVE(p(s(X))) → MARK(X)
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(x1)) → MARK(x1)
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 1 SCC with 1 less node.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
QDP
                                                    ↳ Narrowing
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2)))
MARK(p(x1)) → MARK(x1)
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By narrowing [15] the rule MARK(leq(x1, x2)) → ACTIVE(leq(mark(x1), mark(x2))) at position [0] we obtained the following new rules:

MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
QDP
                                                        ↳ Narrowing
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(s(x1)) → MARK(x1)
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By narrowing [15] the rule MARK(if(x1, x2, x3)) → ACTIVE(if(mark(x1), x2, x3)) at position [0] we obtained the following new rules:

MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(if(0, y1, y2)) → ACTIVE(if(active(0), y1, y2))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(if(true, y1, y2)) → ACTIVE(if(active(true), y1, y2))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
QDP
                                                            ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(if(0, y1, y2)) → ACTIVE(if(active(0), y1, y2))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(if(true, y1, y2)) → ACTIVE(if(active(true), y1, y2))
MARK(leq(x1, x2)) → MARK(x2)
MARK(diff(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(if(0, y1, y2)) → ACTIVE(if(active(0), y1, y2)) at position [0] we obtained the following new rules:

MARK(if(0, y1, y2)) → ACTIVE(if(0, y1, y2))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
QDP
                                                                ↳ DependencyGraphProof
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(x1)) → MARK(x1)
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(if(true, y1, y2)) → ACTIVE(if(active(true), y1, y2))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(0, y1, y2)) → ACTIVE(if(0, y1, y2))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 1 SCC with 1 less node.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
QDP
                                                                    ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(x1)) → MARK(x1)
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(if(true, y1, y2)) → ACTIVE(if(active(true), y1, y2))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(if(true, y1, y2)) → ACTIVE(if(active(true), y1, y2)) at position [0] we obtained the following new rules:

MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
QDP
                                                                        ↳ Rewriting
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(leq(x1, x2)) → MARK(x2)
MARK(diff(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By rewriting [15] the rule MARK(if(false, y1, y2)) → ACTIVE(if(active(false), y1, y2)) at position [0] we obtained the following new rules:

MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
                                                                      ↳ QDP
                                                                        ↳ Rewriting
QDP
                                                                            ↳ Narrowing
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(s(x1)) → MARK(x1)
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(x1, x2)) → MARK(x1)
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2)))
MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By narrowing [15] the rule MARK(diff(x1, x2)) → ACTIVE(diff(mark(x1), mark(x2))) at position [0] we obtained the following new rules:

MARK(diff(y0, if(x0, x1, x2))) → ACTIVE(diff(mark(y0), active(if(mark(x0), x1, x2))))
MARK(diff(s(x0), y1)) → ACTIVE(diff(active(s(mark(x0))), mark(y1)))
MARK(diff(y0, leq(x0, x1))) → ACTIVE(diff(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(diff(if(x0, x1, x2), y1)) → ACTIVE(diff(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(diff(x0, y1)) → ACTIVE(diff(x0, mark(y1)))
MARK(diff(diff(x0, x1), y1)) → ACTIVE(diff(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(diff(y0, p(x0))) → ACTIVE(diff(mark(y0), active(p(mark(x0)))))
MARK(diff(y0, diff(x0, x1))) → ACTIVE(diff(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(y0, x1)) → ACTIVE(diff(mark(y0), x1))
MARK(diff(leq(x0, x1), y1)) → ACTIVE(diff(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(diff(y0, s(x0))) → ACTIVE(diff(mark(y0), active(s(mark(x0)))))
MARK(diff(y0, false)) → ACTIVE(diff(mark(y0), active(false)))
MARK(diff(false, y1)) → ACTIVE(diff(active(false), mark(y1)))
MARK(diff(p(x0), y1)) → ACTIVE(diff(active(p(mark(x0))), mark(y1)))
MARK(diff(y0, true)) → ACTIVE(diff(mark(y0), active(true)))
MARK(diff(true, y1)) → ACTIVE(diff(active(true), mark(y1)))
MARK(diff(0, y1)) → ACTIVE(diff(active(0), mark(y1)))
MARK(diff(y0, 0)) → ACTIVE(diff(mark(y0), active(0)))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
                                                                      ↳ QDP
                                                                        ↳ Rewriting
                                                                          ↳ QDP
                                                                            ↳ Narrowing
QDP
                                                                                ↳ ForwardInstantiation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(y0, if(x0, x1, x2))) → ACTIVE(diff(mark(y0), active(if(mark(x0), x1, x2))))
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(diff(s(x0), y1)) → ACTIVE(diff(active(s(mark(x0))), mark(y1)))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(diff(x0, x1), y1)) → ACTIVE(diff(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(diff(y0, diff(x0, x1))) → ACTIVE(diff(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(y0, x1)) → ACTIVE(diff(mark(y0), x1))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(diff(false, y1)) → ACTIVE(diff(active(false), mark(y1)))
MARK(diff(y0, false)) → ACTIVE(diff(mark(y0), active(false)))
MARK(leq(x1, x2)) → MARK(x1)
MARK(diff(true, y1)) → ACTIVE(diff(active(true), mark(y1)))
MARK(diff(y0, true)) → ACTIVE(diff(mark(y0), active(true)))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(diff(y0, leq(x0, x1))) → ACTIVE(diff(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(y0, s(x0))) → ACTIVE(diff(mark(y0), active(s(mark(x0)))))
MARK(diff(leq(x0, x1), y1)) → ACTIVE(diff(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(x1)) → MARK(x1)
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(diff(x0, y1)) → ACTIVE(diff(x0, mark(y1)))
MARK(diff(y0, p(x0))) → ACTIVE(diff(mark(y0), active(p(mark(x0)))))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(diff(p(x0), y1)) → ACTIVE(diff(active(p(mark(x0))), mark(y1)))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(diff(y0, 0)) → ACTIVE(diff(mark(y0), active(0)))
MARK(diff(0, y1)) → ACTIVE(diff(active(0), mark(y1)))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(diff(if(x0, x1, x2), y1)) → ACTIVE(diff(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))
ACTIVE(if(true, X, Y)) → MARK(X)

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By forward instantiating [14] the rule MARK(s(x1)) → MARK(x1) we obtained the following new rules:

MARK(s(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(s(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(s(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(s(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(s(s(y_0))) → MARK(s(y_0))
MARK(s(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(s(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(s(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(s(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(s(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(s(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(s(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(s(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(s(p(y_0))) → MARK(p(y_0))
MARK(s(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(s(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(s(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(s(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(s(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(s(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(s(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(s(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(s(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(s(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(s(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(s(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(s(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(s(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(s(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(s(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(s(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(s(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(s(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(s(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(s(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(s(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(s(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(s(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(s(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(s(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(s(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(s(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(s(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(s(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(s(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(s(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(s(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(s(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
                                                                      ↳ QDP
                                                                        ↳ Rewriting
                                                                          ↳ QDP
                                                                            ↳ Narrowing
                                                                              ↳ QDP
                                                                                ↳ ForwardInstantiation
QDP
                                                                                    ↳ ForwardInstantiation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(diff(y0, if(x0, x1, x2))) → ACTIVE(diff(mark(y0), active(if(mark(x0), x1, x2))))
MARK(diff(s(x0), y1)) → ACTIVE(diff(active(s(mark(x0))), mark(y1)))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(s(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(s(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(leq(x1, x2)) → MARK(x2)
MARK(s(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
ACTIVE(p(s(X))) → MARK(X)
MARK(diff(diff(x0, x1), y1)) → ACTIVE(diff(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(diff(y0, diff(x0, x1))) → ACTIVE(diff(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(y0, x1)) → ACTIVE(diff(mark(y0), x1))
MARK(s(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(diff(false, y1)) → ACTIVE(diff(active(false), mark(y1)))
MARK(diff(y0, false)) → ACTIVE(diff(mark(y0), active(false)))
MARK(s(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(x1)) → MARK(x1)
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(s(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(s(p(y_0))) → MARK(p(y_0))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(diff(y0, leq(x0, x1))) → ACTIVE(diff(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(s(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(s(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(diff(y0, s(x0))) → ACTIVE(diff(mark(y0), active(s(mark(x0)))))
MARK(s(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(s(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(s(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(s(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(s(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(s(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(s(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(diff(x0, y1)) → ACTIVE(diff(x0, mark(y1)))
MARK(diff(y0, p(x0))) → ACTIVE(diff(mark(y0), active(p(mark(x0)))))
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(s(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(s(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(diff(if(x0, x1, x2), y1)) → ACTIVE(diff(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(s(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))
MARK(s(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(s(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(s(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(s(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(s(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(s(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(s(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(s(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(s(s(y_0))) → MARK(s(y_0))
MARK(s(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(s(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(leq(x1, x2)) → MARK(x1)
MARK(diff(true, y1)) → ACTIVE(diff(active(true), mark(y1)))
MARK(diff(y0, true)) → ACTIVE(diff(mark(y0), active(true)))
MARK(s(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(s(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(s(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(s(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(diff(leq(x0, x1), y1)) → ACTIVE(diff(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(s(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(s(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(s(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(s(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(s(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(diff(p(x0), y1)) → ACTIVE(diff(active(p(mark(x0))), mark(y1)))
MARK(diff(y0, 0)) → ACTIVE(diff(mark(y0), active(0)))
MARK(diff(0, y1)) → ACTIVE(diff(active(0), mark(y1)))
MARK(s(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(s(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(s(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(s(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(s(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(s(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(s(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(s(diff(y_0, y_1))) → MARK(diff(y_0, y_1))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By forward instantiating [14] the rule MARK(p(x1)) → MARK(x1) we obtained the following new rules:

MARK(p(s(if(if(y_0, y_1, y_2), y_3, y_4)))) → MARK(s(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(p(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(p(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(p(s(leq(diff(y_0, y_1), y_2)))) → MARK(s(leq(diff(y_0, y_1), y_2)))
MARK(p(s(if(false, y_0, y_1)))) → MARK(s(if(false, y_0, y_1)))
MARK(p(s(diff(y_0, false)))) → MARK(s(diff(y_0, false)))
MARK(p(s(diff(false, y_0)))) → MARK(s(diff(false, y_0)))
MARK(p(s(if(diff(y_0, y_1), y_2, y_3)))) → MARK(s(if(diff(y_0, y_1), y_2, y_3)))
MARK(p(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(p(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(p(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(p(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(p(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(p(s(diff(p(y_0), y_1)))) → MARK(s(diff(p(y_0), y_1)))
MARK(p(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(p(s(leq(y_0, s(y_1))))) → MARK(s(leq(y_0, s(y_1))))
MARK(p(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(p(s(if(true, y_0, y_1)))) → MARK(s(if(true, y_0, y_1)))
MARK(p(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(p(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(p(s(p(if(y_0, y_1, y_2))))) → MARK(s(p(if(y_0, y_1, y_2))))
MARK(p(p(y_0))) → MARK(p(y_0))
MARK(p(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(p(s(leq(y_0, leq(y_1, y_2))))) → MARK(s(leq(y_0, leq(y_1, y_2))))
MARK(p(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(p(s(diff(if(y_0, y_1, y_2), y_3)))) → MARK(s(diff(if(y_0, y_1, y_2), y_3)))
MARK(p(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(p(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(p(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(p(s(diff(y_0, p(y_1))))) → MARK(s(diff(y_0, p(y_1))))
MARK(p(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(p(s(leq(s(y_0), y_1)))) → MARK(s(leq(s(y_0), y_1)))
MARK(p(s(s(y_0)))) → MARK(s(s(y_0)))
MARK(p(s(diff(s(y_0), y_1)))) → MARK(s(diff(s(y_0), y_1)))
MARK(p(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(p(s(leq(true, y_0)))) → MARK(s(leq(true, y_0)))
MARK(p(s(leq(y_0, true)))) → MARK(s(leq(y_0, true)))
MARK(p(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(p(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(p(s(leq(if(y_0, y_1, y_2), y_3)))) → MARK(s(leq(if(y_0, y_1, y_2), y_3)))
MARK(p(s(leq(y_0, p(y_1))))) → MARK(s(leq(y_0, p(y_1))))
MARK(p(s(p(p(y_0))))) → MARK(s(p(p(y_0))))
MARK(p(s(leq(y_0, diff(y_1, y_2))))) → MARK(s(leq(y_0, diff(y_1, y_2))))
MARK(p(s(diff(y_0, true)))) → MARK(s(diff(y_0, true)))
MARK(p(s(diff(true, y_0)))) → MARK(s(diff(true, y_0)))
MARK(p(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(p(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(p(s(diff(0, y_0)))) → MARK(s(diff(0, y_0)))
MARK(p(s(diff(y_0, 0)))) → MARK(s(diff(y_0, 0)))
MARK(p(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(p(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(p(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(p(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(p(s(leq(leq(y_0, y_1), y_2)))) → MARK(s(leq(leq(y_0, y_1), y_2)))
MARK(p(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(p(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(p(s(if(s(y_0), y_1, y_2)))) → MARK(s(if(s(y_0), y_1, y_2)))
MARK(p(s(p(leq(y_0, y_1))))) → MARK(s(p(leq(y_0, y_1))))
MARK(p(s(leq(y_0, y_1)))) → MARK(s(leq(y_0, y_1)))
MARK(p(s(leq(false, y_0)))) → MARK(s(leq(false, y_0)))
MARK(p(s(leq(y_0, false)))) → MARK(s(leq(y_0, false)))
MARK(p(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(p(s(if(leq(y_0, y_1), y_2, y_3)))) → MARK(s(if(leq(y_0, y_1), y_2, y_3)))
MARK(p(s(if(y_0, y_1, y_2)))) → MARK(s(if(y_0, y_1, y_2)))
MARK(p(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(p(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(p(s(leq(y_0, if(y_1, y_2, y_3))))) → MARK(s(leq(y_0, if(y_1, y_2, y_3))))
MARK(p(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(p(s(diff(leq(y_0, y_1), y_2)))) → MARK(s(diff(leq(y_0, y_1), y_2)))
MARK(p(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(p(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(s(diff(y_0, diff(y_1, y_2))))) → MARK(s(diff(y_0, diff(y_1, y_2))))
MARK(p(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(p(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(p(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(p(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(p(s(diff(diff(y_0, y_1), y_2)))) → MARK(s(diff(diff(y_0, y_1), y_2)))
MARK(p(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(p(s(p(s(y_0))))) → MARK(s(p(s(y_0))))
MARK(p(s(p(diff(y_0, y_1))))) → MARK(s(p(diff(y_0, y_1))))
MARK(p(s(diff(y_0, y_1)))) → MARK(s(diff(y_0, y_1)))
MARK(p(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(p(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(p(s(diff(y_0, s(y_1))))) → MARK(s(diff(y_0, s(y_1))))
MARK(p(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(p(s(leq(p(y_0), y_1)))) → MARK(s(leq(p(y_0), y_1)))
MARK(p(s(if(p(y_0), y_1, y_2)))) → MARK(s(if(p(y_0), y_1, y_2)))
MARK(p(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(p(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(p(s(p(y_0)))) → MARK(s(p(y_0)))
MARK(p(s(diff(y_0, if(y_1, y_2, y_3))))) → MARK(s(diff(y_0, if(y_1, y_2, y_3))))
MARK(p(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(p(s(leq(y_0, 0)))) → MARK(s(leq(y_0, 0)))
MARK(p(s(leq(0, y_0)))) → MARK(s(leq(0, y_0)))
MARK(p(s(diff(y_0, leq(y_1, y_2))))) → MARK(s(diff(y_0, leq(y_1, y_2))))
MARK(p(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
                                                                      ↳ QDP
                                                                        ↳ Rewriting
                                                                          ↳ QDP
                                                                            ↳ Narrowing
                                                                              ↳ QDP
                                                                                ↳ ForwardInstantiation
                                                                                  ↳ QDP
                                                                                    ↳ ForwardInstantiation
QDP
                                                                                        ↳ ForwardInstantiation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(s(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(s(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(diff(x1, x2)) → MARK(x2)
MARK(diff(y0, diff(x0, x1))) → ACTIVE(diff(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(diff(y0, x1)) → ACTIVE(diff(mark(y0), x1))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(diff(false, y1)) → ACTIVE(diff(active(false), mark(y1)))
MARK(diff(y0, false)) → ACTIVE(diff(mark(y0), active(false)))
MARK(p(s(if(diff(y_0, y_1), y_2, y_3)))) → MARK(s(if(diff(y_0, y_1), y_2, y_3)))
MARK(p(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(p(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(s(p(y_0))) → MARK(p(y_0))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(p(s(leq(y_0, s(y_1))))) → MARK(s(leq(y_0, s(y_1))))
MARK(p(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(p(s(p(if(y_0, y_1, y_2))))) → MARK(s(p(if(y_0, y_1, y_2))))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(p(p(y_0))) → MARK(p(y_0))
MARK(p(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(p(s(leq(y_0, leq(y_1, y_2))))) → MARK(s(leq(y_0, leq(y_1, y_2))))
MARK(s(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(s(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(s(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(s(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(diff(x0, y1)) → ACTIVE(diff(x0, mark(y1)))
MARK(diff(y0, p(x0))) → ACTIVE(diff(mark(y0), active(p(mark(x0)))))
MARK(p(s(diff(y_0, p(y_1))))) → MARK(s(diff(y_0, p(y_1))))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(s(s(y_0)))) → MARK(s(s(y_0)))
MARK(s(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(p(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(p(s(leq(true, y_0)))) → MARK(s(leq(true, y_0)))
MARK(p(s(leq(y_0, true)))) → MARK(s(leq(y_0, true)))
MARK(diff(if(x0, x1, x2), y1)) → ACTIVE(diff(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(p(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(p(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(s(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))
MARK(p(s(leq(if(y_0, y_1, y_2), y_3)))) → MARK(s(leq(if(y_0, y_1, y_2), y_3)))
MARK(p(s(leq(y_0, p(y_1))))) → MARK(s(leq(y_0, p(y_1))))
MARK(p(s(p(p(y_0))))) → MARK(s(p(p(y_0))))
MARK(s(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(s(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(s(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(p(s(diff(y_0, true)))) → MARK(s(diff(y_0, true)))
MARK(p(s(diff(true, y_0)))) → MARK(s(diff(true, y_0)))
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(p(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(p(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(p(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(p(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(leq(x1, x2)) → MARK(x1)
MARK(diff(true, y1)) → ACTIVE(diff(active(true), mark(y1)))
MARK(diff(y0, true)) → ACTIVE(diff(mark(y0), active(true)))
MARK(p(s(p(leq(y_0, y_1))))) → MARK(s(p(leq(y_0, y_1))))
MARK(p(s(leq(y_0, y_1)))) → MARK(s(leq(y_0, y_1)))
MARK(p(s(leq(false, y_0)))) → MARK(s(leq(false, y_0)))
MARK(p(s(leq(y_0, false)))) → MARK(s(leq(y_0, false)))
MARK(p(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(p(s(if(leq(y_0, y_1), y_2, y_3)))) → MARK(s(if(leq(y_0, y_1), y_2, y_3)))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(p(s(if(y_0, y_1, y_2)))) → MARK(s(if(y_0, y_1, y_2)))
MARK(p(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(diff(leq(x0, x1), y1)) → ACTIVE(diff(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(s(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(p(s(leq(y_0, if(y_1, y_2, y_3))))) → MARK(s(leq(y_0, if(y_1, y_2, y_3))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
MARK(p(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(s(diff(y_0, diff(y_1, y_2))))) → MARK(s(diff(y_0, diff(y_1, y_2))))
MARK(p(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(p(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(s(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(s(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(p(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(p(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(p(s(diff(diff(y_0, y_1), y_2)))) → MARK(s(diff(diff(y_0, y_1), y_2)))
MARK(p(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(p(s(p(diff(y_0, y_1))))) → MARK(s(p(diff(y_0, y_1))))
MARK(p(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(diff(p(x0), y1)) → ACTIVE(diff(active(p(mark(x0))), mark(y1)))
MARK(s(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(p(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(s(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(p(s(if(p(y_0), y_1, y_2)))) → MARK(s(if(p(y_0), y_1, y_2)))
MARK(p(s(leq(p(y_0), y_1)))) → MARK(s(leq(p(y_0), y_1)))
MARK(p(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(p(s(p(y_0)))) → MARK(s(p(y_0)))
MARK(p(s(diff(y_0, if(y_1, y_2, y_3))))) → MARK(s(diff(y_0, if(y_1, y_2, y_3))))
MARK(p(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(s(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(p(s(diff(y_0, leq(y_1, y_2))))) → MARK(s(diff(y_0, leq(y_1, y_2))))
MARK(s(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(p(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(diff(y0, if(x0, x1, x2))) → ACTIVE(diff(mark(y0), active(if(mark(x0), x1, x2))))
MARK(diff(s(x0), y1)) → ACTIVE(diff(active(s(mark(x0))), mark(y1)))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(p(s(if(if(y_0, y_1, y_2), y_3, y_4)))) → MARK(s(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(leq(x1, x2)) → MARK(x2)
MARK(s(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(p(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(p(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(p(s(leq(diff(y_0, y_1), y_2)))) → MARK(s(leq(diff(y_0, y_1), y_2)))
ACTIVE(p(s(X))) → MARK(X)
MARK(p(s(if(false, y_0, y_1)))) → MARK(s(if(false, y_0, y_1)))
MARK(diff(diff(x0, x1), y1)) → ACTIVE(diff(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(s(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(p(s(diff(y_0, false)))) → MARK(s(diff(y_0, false)))
MARK(p(s(diff(false, y_0)))) → MARK(s(diff(false, y_0)))
MARK(s(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(p(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(s(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(p(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(p(s(diff(p(y_0), y_1)))) → MARK(s(diff(p(y_0), y_1)))
MARK(diff(y0, leq(x0, x1))) → ACTIVE(diff(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(p(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(p(s(if(true, y_0, y_1)))) → MARK(s(if(true, y_0, y_1)))
MARK(s(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(s(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(diff(y0, s(x0))) → ACTIVE(diff(mark(y0), active(s(mark(x0)))))
MARK(p(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(s(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(s(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(s(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(s(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(p(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(p(s(diff(if(y_0, y_1, y_2), y_3)))) → MARK(s(diff(if(y_0, y_1, y_2), y_3)))
MARK(p(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(p(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(p(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(s(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(p(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(p(s(leq(s(y_0), y_1)))) → MARK(s(leq(s(y_0), y_1)))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(p(s(diff(s(y_0), y_1)))) → MARK(s(diff(s(y_0), y_1)))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(p(s(leq(y_0, diff(y_1, y_2))))) → MARK(s(leq(y_0, diff(y_1, y_2))))
MARK(s(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(p(s(diff(0, y_0)))) → MARK(s(diff(0, y_0)))
MARK(p(s(diff(y_0, 0)))) → MARK(s(diff(y_0, 0)))
MARK(s(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(s(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(p(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(s(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(s(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(s(y_0))) → MARK(s(y_0))
MARK(p(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(p(s(leq(leq(y_0, y_1), y_2)))) → MARK(s(leq(leq(y_0, y_1), y_2)))
MARK(s(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(p(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(s(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(p(s(if(s(y_0), y_1, y_2)))) → MARK(s(if(s(y_0), y_1, y_2)))
MARK(s(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(s(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(s(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(s(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(p(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(p(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(p(s(diff(leq(y_0, y_1), y_2)))) → MARK(s(diff(leq(y_0, y_1), y_2)))
MARK(p(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(p(s(p(s(y_0))))) → MARK(s(p(s(y_0))))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(p(s(diff(y_0, y_1)))) → MARK(s(diff(y_0, y_1)))
MARK(s(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(s(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(diff(y0, 0)) → ACTIVE(diff(mark(y0), active(0)))
MARK(diff(0, y1)) → ACTIVE(diff(active(0), mark(y1)))
MARK(p(s(diff(y_0, s(y_1))))) → MARK(s(diff(y_0, s(y_1))))
MARK(p(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(s(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(p(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(p(s(leq(0, y_0)))) → MARK(s(leq(0, y_0)))
MARK(p(s(leq(y_0, 0)))) → MARK(s(leq(y_0, 0)))
MARK(s(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(s(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(s(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
By forward instantiating [14] the rule MARK(leq(x1, x2)) → MARK(x1) we obtained the following new rules:

MARK(leq(p(s(leq(leq(y_0, y_1), y_2))), x1)) → MARK(p(s(leq(leq(y_0, y_1), y_2))))
MARK(leq(s(diff(s(y_0), y_1)), x1)) → MARK(s(diff(s(y_0), y_1)))
MARK(leq(p(leq(p(y_0), y_1)), x1)) → MARK(p(leq(p(y_0), y_1)))
MARK(leq(p(s(diff(false, y_0))), x1)) → MARK(p(s(diff(false, y_0))))
MARK(leq(p(s(diff(y_0, false))), x1)) → MARK(p(s(diff(y_0, false))))
MARK(leq(s(leq(true, y_0)), x1)) → MARK(s(leq(true, y_0)))
MARK(leq(s(leq(y_0, true)), x1)) → MARK(s(leq(y_0, true)))
MARK(leq(s(if(y_0, y_1, y_2)), x1)) → MARK(s(if(y_0, y_1, y_2)))
MARK(leq(s(diff(0, y_0)), x1)) → MARK(s(diff(0, y_0)))
MARK(leq(s(diff(y_0, 0)), x1)) → MARK(s(diff(y_0, 0)))
MARK(leq(p(diff(y_0, p(y_1))), x1)) → MARK(p(diff(y_0, p(y_1))))
MARK(leq(s(diff(y_0, if(y_1, y_2, y_3))), x1)) → MARK(s(diff(y_0, if(y_1, y_2, y_3))))
MARK(leq(p(s(diff(y_0, 0))), x1)) → MARK(p(s(diff(y_0, 0))))
MARK(leq(p(s(diff(0, y_0))), x1)) → MARK(p(s(diff(0, y_0))))
MARK(leq(p(leq(false, y_0)), x1)) → MARK(p(leq(false, y_0)))
MARK(leq(p(leq(y_0, false)), x1)) → MARK(p(leq(y_0, false)))
MARK(leq(diff(leq(y_0, y_1), y_2), x1)) → MARK(diff(leq(y_0, y_1), y_2))
MARK(leq(p(s(if(diff(y_0, y_1), y_2, y_3))), x1)) → MARK(p(s(if(diff(y_0, y_1), y_2, y_3))))
MARK(leq(leq(y_0, diff(y_1, y_2)), x1)) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(leq(p(s(p(leq(y_0, y_1)))), x1)) → MARK(p(s(p(leq(y_0, y_1)))))
MARK(leq(p(diff(y_0, s(y_1))), x1)) → MARK(p(diff(y_0, s(y_1))))
MARK(leq(diff(true, y_0), x1)) → MARK(diff(true, y_0))
MARK(leq(diff(y_0, true), x1)) → MARK(diff(y_0, true))
MARK(leq(leq(y_0, leq(y_1, y_2)), x1)) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(leq(diff(false, y_0), x1)) → MARK(diff(false, y_0))
MARK(leq(diff(y_0, false), x1)) → MARK(diff(y_0, false))
MARK(leq(p(s(diff(leq(y_0, y_1), y_2))), x1)) → MARK(p(s(diff(leq(y_0, y_1), y_2))))
MARK(leq(leq(diff(y_0, y_1), y_2), x1)) → MARK(leq(diff(y_0, y_1), y_2))
MARK(leq(p(s(p(y_0))), x1)) → MARK(p(s(p(y_0))))
MARK(leq(p(leq(leq(y_0, y_1), y_2)), x1)) → MARK(p(leq(leq(y_0, y_1), y_2)))
MARK(leq(p(s(leq(y_0, leq(y_1, y_2)))), x1)) → MARK(p(s(leq(y_0, leq(y_1, y_2)))))
MARK(leq(p(leq(y_0, s(y_1))), x1)) → MARK(p(leq(y_0, s(y_1))))
MARK(leq(p(s(leq(p(y_0), y_1))), x1)) → MARK(p(s(leq(p(y_0), y_1))))
MARK(leq(p(s(diff(if(y_0, y_1, y_2), y_3))), x1)) → MARK(p(s(diff(if(y_0, y_1, y_2), y_3))))
MARK(leq(leq(leq(y_0, y_1), y_2), x1)) → MARK(leq(leq(y_0, y_1), y_2))
MARK(leq(p(diff(y_0, y_1)), x1)) → MARK(p(diff(y_0, y_1)))
MARK(leq(s(p(s(y_0))), x1)) → MARK(s(p(s(y_0))))
MARK(leq(p(s(if(leq(y_0, y_1), y_2, y_3))), x1)) → MARK(p(s(if(leq(y_0, y_1), y_2, y_3))))
MARK(leq(p(diff(y_0, true)), x1)) → MARK(p(diff(y_0, true)))
MARK(leq(p(diff(true, y_0)), x1)) → MARK(p(diff(true, y_0)))
MARK(leq(s(diff(y_0, leq(y_1, y_2))), x1)) → MARK(s(diff(y_0, leq(y_1, y_2))))
MARK(leq(s(if(if(y_0, y_1, y_2), y_3, y_4)), x1)) → MARK(s(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(leq(p(s(diff(y_0, if(y_1, y_2, y_3)))), x1)) → MARK(p(s(diff(y_0, if(y_1, y_2, y_3)))))
MARK(leq(diff(y_0, diff(y_1, y_2)), x1)) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(leq(p(s(diff(p(y_0), y_1))), x1)) → MARK(p(s(diff(p(y_0), y_1))))
MARK(leq(p(s(diff(diff(y_0, y_1), y_2))), x1)) → MARK(p(s(diff(diff(y_0, y_1), y_2))))
MARK(leq(p(if(diff(y_0, y_1), y_2, y_3)), x1)) → MARK(p(if(diff(y_0, y_1), y_2, y_3)))
MARK(leq(p(s(diff(y_0, leq(y_1, y_2)))), x1)) → MARK(p(s(diff(y_0, leq(y_1, y_2)))))
MARK(leq(p(s(leq(y_0, false))), x1)) → MARK(p(s(leq(y_0, false))))
MARK(leq(p(s(leq(false, y_0))), x1)) → MARK(p(s(leq(false, y_0))))
MARK(leq(p(if(true, y_0, y_1)), x1)) → MARK(p(if(true, y_0, y_1)))
MARK(leq(s(leq(diff(y_0, y_1), y_2)), x1)) → MARK(s(leq(diff(y_0, y_1), y_2)))
MARK(leq(p(p(diff(y_0, y_1))), x1)) → MARK(p(p(diff(y_0, y_1))))
MARK(leq(leq(s(y_0), y_1), x1)) → MARK(leq(s(y_0), y_1))
MARK(leq(diff(y_0, y_1), x1)) → MARK(diff(y_0, y_1))
MARK(leq(p(diff(leq(y_0, y_1), y_2)), x1)) → MARK(p(diff(leq(y_0, y_1), y_2)))
MARK(leq(if(s(y_0), y_1, y_2), x1)) → MARK(if(s(y_0), y_1, y_2))
MARK(leq(p(p(y_0)), x1)) → MARK(p(p(y_0)))
MARK(leq(if(y_0, y_1, y_2), x1)) → MARK(if(y_0, y_1, y_2))
MARK(leq(s(if(false, y_0, y_1)), x1)) → MARK(s(if(false, y_0, y_1)))
MARK(leq(diff(y_0, if(y_1, y_2, y_3)), x1)) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(leq(s(diff(y_0, false)), x1)) → MARK(s(diff(y_0, false)))
MARK(leq(s(diff(false, y_0)), x1)) → MARK(s(diff(false, y_0)))
MARK(leq(p(s(diff(true, y_0))), x1)) → MARK(p(s(diff(true, y_0))))
MARK(leq(p(s(diff(y_0, true))), x1)) → MARK(p(s(diff(y_0, true))))
MARK(leq(p(if(y_0, y_1, y_2)), x1)) → MARK(p(if(y_0, y_1, y_2)))
MARK(leq(s(leq(leq(y_0, y_1), y_2)), x1)) → MARK(s(leq(leq(y_0, y_1), y_2)))
MARK(leq(if(leq(y_0, y_1), y_2, y_3), x1)) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(leq(leq(y_0, if(y_1, y_2, y_3)), x1)) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(leq(p(s(diff(y_0, s(y_1)))), x1)) → MARK(p(s(diff(y_0, s(y_1)))))
MARK(leq(p(leq(true, y_0)), x1)) → MARK(p(leq(true, y_0)))
MARK(leq(p(leq(y_0, true)), x1)) → MARK(p(leq(y_0, true)))
MARK(leq(s(if(true, y_0, y_1)), x1)) → MARK(s(if(true, y_0, y_1)))
MARK(leq(p(leq(s(y_0), y_1)), x1)) → MARK(p(leq(s(y_0), y_1)))
MARK(leq(p(leq(y_0, p(y_1))), x1)) → MARK(p(leq(y_0, p(y_1))))
MARK(leq(p(p(s(y_0))), x1)) → MARK(p(p(s(y_0))))
MARK(leq(p(leq(y_0, 0)), x1)) → MARK(p(leq(y_0, 0)))
MARK(leq(p(leq(0, y_0)), x1)) → MARK(p(leq(0, y_0)))
MARK(leq(p(s(leq(y_0, diff(y_1, y_2)))), x1)) → MARK(p(s(leq(y_0, diff(y_1, y_2)))))
MARK(leq(s(leq(y_0, diff(y_1, y_2))), x1)) → MARK(s(leq(y_0, diff(y_1, y_2))))
MARK(leq(s(diff(y_0, p(y_1))), x1)) → MARK(s(diff(y_0, p(y_1))))
MARK(leq(p(diff(s(y_0), y_1)), x1)) → MARK(p(diff(s(y_0), y_1)))
MARK(leq(s(leq(y_0, p(y_1))), x1)) → MARK(s(leq(y_0, p(y_1))))
MARK(leq(p(leq(y_0, if(y_1, y_2, y_3))), x1)) → MARK(p(leq(y_0, if(y_1, y_2, y_3))))
MARK(leq(p(s(leq(s(y_0), y_1))), x1)) → MARK(p(s(leq(s(y_0), y_1))))
MARK(leq(s(diff(leq(y_0, y_1), y_2)), x1)) → MARK(s(diff(leq(y_0, y_1), y_2)))
MARK(leq(diff(y_0, p(y_1)), x1)) → MARK(diff(y_0, p(y_1)))
MARK(leq(s(leq(y_0, leq(y_1, y_2))), x1)) → MARK(s(leq(y_0, leq(y_1, y_2))))
MARK(leq(s(leq(p(y_0), y_1)), x1)) → MARK(s(leq(p(y_0), y_1)))
MARK(leq(p(s(leq(y_0, p(y_1)))), x1)) → MARK(p(s(leq(y_0, p(y_1)))))
MARK(leq(diff(p(y_0), y_1), x1)) → MARK(diff(p(y_0), y_1))
MARK(leq(p(s(leq(0, y_0))), x1)) → MARK(p(s(leq(0, y_0))))
MARK(leq(p(s(leq(y_0, 0))), x1)) → MARK(p(s(leq(y_0, 0))))
MARK(leq(p(s(leq(diff(y_0, y_1), y_2))), x1)) → MARK(p(s(leq(diff(y_0, y_1), y_2))))
MARK(leq(if(true, y_0, y_1), x1)) → MARK(if(true, y_0, y_1))
MARK(leq(if(if(y_0, y_1, y_2), y_3, y_4), x1)) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(leq(p(y_0), x1)) → MARK(p(y_0))
MARK(leq(leq(0, y_0), x1)) → MARK(leq(0, y_0))
MARK(leq(leq(y_0, 0), x1)) → MARK(leq(y_0, 0))
MARK(leq(p(s(if(p(y_0), y_1, y_2))), x1)) → MARK(p(s(if(p(y_0), y_1, y_2))))
MARK(leq(s(leq(false, y_0)), x1)) → MARK(s(leq(false, y_0)))
MARK(leq(s(leq(y_0, false)), x1)) → MARK(s(leq(y_0, false)))
MARK(leq(s(leq(s(y_0), y_1)), x1)) → MARK(s(leq(s(y_0), y_1)))
MARK(leq(p(diff(y_0, if(y_1, y_2, y_3))), x1)) → MARK(p(diff(y_0, if(y_1, y_2, y_3))))
MARK(leq(diff(y_0, 0), x1)) → MARK(diff(y_0, 0))
MARK(leq(diff(0, y_0), x1)) → MARK(diff(0, y_0))
MARK(leq(leq(y_0, true), x1)) → MARK(leq(y_0, true))
MARK(leq(leq(true, y_0), x1)) → MARK(leq(true, y_0))
MARK(leq(p(leq(diff(y_0, y_1), y_2)), x1)) → MARK(p(leq(diff(y_0, y_1), y_2)))
MARK(leq(p(diff(y_0, false)), x1)) → MARK(p(diff(y_0, false)))
MARK(leq(p(diff(false, y_0)), x1)) → MARK(p(diff(false, y_0)))
MARK(leq(p(if(s(y_0), y_1, y_2)), x1)) → MARK(p(if(s(y_0), y_1, y_2)))
MARK(leq(diff(s(y_0), y_1), x1)) → MARK(diff(s(y_0), y_1))
MARK(leq(s(leq(y_0, 0)), x1)) → MARK(s(leq(y_0, 0)))
MARK(leq(s(leq(0, y_0)), x1)) → MARK(s(leq(0, y_0)))
MARK(leq(p(s(if(false, y_0, y_1))), x1)) → MARK(p(s(if(false, y_0, y_1))))
MARK(leq(s(p(p(y_0))), x1)) → MARK(s(p(p(y_0))))
MARK(leq(p(leq(if(y_0, y_1, y_2), y_3)), x1)) → MARK(p(leq(if(y_0, y_1, y_2), y_3)))
MARK(leq(s(diff(y_0, y_1)), x1)) → MARK(s(diff(y_0, y_1)))
MARK(leq(s(p(leq(y_0, y_1))), x1)) → MARK(s(p(leq(y_0, y_1))))
MARK(leq(if(false, y_0, y_1), x1)) → MARK(if(false, y_0, y_1))
MARK(leq(s(diff(y_0, true)), x1)) → MARK(s(diff(y_0, true)))
MARK(leq(s(diff(true, y_0)), x1)) → MARK(s(diff(true, y_0)))
MARK(leq(p(s(diff(y_0, p(y_1)))), x1)) → MARK(p(s(diff(y_0, p(y_1)))))
MARK(leq(p(diff(y_0, leq(y_1, y_2))), x1)) → MARK(p(diff(y_0, leq(y_1, y_2))))
MARK(leq(p(if(if(y_0, y_1, y_2), y_3, y_4)), x1)) → MARK(p(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(leq(p(s(if(true, y_0, y_1))), x1)) → MARK(p(s(if(true, y_0, y_1))))
MARK(leq(s(if(leq(y_0, y_1), y_2, y_3)), x1)) → MARK(s(if(leq(y_0, y_1), y_2, y_3)))
MARK(leq(p(if(p(y_0), y_1, y_2)), x1)) → MARK(p(if(p(y_0), y_1, y_2)))
MARK(leq(diff(if(y_0, y_1, y_2), y_3), x1)) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(leq(if(diff(y_0, y_1), y_2, y_3), x1)) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(leq(leq(y_0, false), x1)) → MARK(leq(y_0, false))
MARK(leq(leq(false, y_0), x1)) → MARK(leq(false, y_0))
MARK(leq(if(p(y_0), y_1, y_2), x1)) → MARK(if(p(y_0), y_1, y_2))
MARK(leq(s(if(p(y_0), y_1, y_2)), x1)) → MARK(s(if(p(y_0), y_1, y_2)))
MARK(leq(p(s(leq(if(y_0, y_1, y_2), y_3))), x1)) → MARK(p(s(leq(if(y_0, y_1, y_2), y_3))))
MARK(leq(diff(y_0, s(y_1)), x1)) → MARK(diff(y_0, s(y_1)))
MARK(leq(p(leq(y_0, diff(y_1, y_2))), x1)) → MARK(p(leq(y_0, diff(y_1, y_2))))
MARK(leq(s(diff(y_0, s(y_1))), x1)) → MARK(s(diff(y_0, s(y_1))))
MARK(leq(p(s(diff(y_0, y_1))), x1)) → MARK(p(s(diff(y_0, y_1))))
MARK(leq(p(s(diff(y_0, diff(y_1, y_2)))), x1)) → MARK(p(s(diff(y_0, diff(y_1, y_2)))))
MARK(leq(p(s(p(diff(y_0, y_1)))), x1)) → MARK(p(s(p(diff(y_0, y_1)))))
MARK(leq(p(p(if(y_0, y_1, y_2))), x1)) → MARK(p(p(if(y_0, y_1, y_2))))
MARK(leq(leq(y_0, y_1), x1)) → MARK(leq(y_0, y_1))
MARK(leq(p(diff(p(y_0), y_1)), x1)) → MARK(p(diff(p(y_0), y_1)))
MARK(leq(p(s(leq(y_0, s(y_1)))), x1)) → MARK(p(s(leq(y_0, s(y_1)))))
MARK(leq(p(s(leq(y_0, true))), x1)) → MARK(p(s(leq(y_0, true))))
MARK(leq(p(s(leq(true, y_0))), x1)) → MARK(p(s(leq(true, y_0))))
MARK(leq(p(s(p(if(y_0, y_1, y_2)))), x1)) → MARK(p(s(p(if(y_0, y_1, y_2)))))
MARK(leq(p(s(if(if(y_0, y_1, y_2), y_3, y_4))), x1)) → MARK(p(s(if(if(y_0, y_1, y_2), y_3, y_4))))
MARK(leq(p(diff(0, y_0)), x1)) → MARK(p(diff(0, y_0)))
MARK(leq(p(diff(y_0, 0)), x1)) → MARK(p(diff(y_0, 0)))
MARK(leq(p(s(s(y_0))), x1)) → MARK(p(s(s(y_0))))
MARK(leq(p(leq(y_0, y_1)), x1)) → MARK(p(leq(y_0, y_1)))
MARK(leq(s(diff(p(y_0), y_1)), x1)) → MARK(s(diff(p(y_0), y_1)))
MARK(leq(s(p(y_0)), x1)) → MARK(s(p(y_0)))
MARK(leq(p(s(p(s(y_0)))), x1)) → MARK(p(s(p(s(y_0)))))
MARK(leq(p(diff(diff(y_0, y_1), y_2)), x1)) → MARK(p(diff(diff(y_0, y_1), y_2)))
MARK(leq(s(p(if(y_0, y_1, y_2))), x1)) → MARK(s(p(if(y_0, y_1, y_2))))
MARK(leq(p(s(if(s(y_0), y_1, y_2))), x1)) → MARK(p(s(if(s(y_0), y_1, y_2))))
MARK(leq(p(if(leq(y_0, y_1), y_2, y_3)), x1)) → MARK(p(if(leq(y_0, y_1), y_2, y_3)))
MARK(leq(s(leq(if(y_0, y_1, y_2), y_3)), x1)) → MARK(s(leq(if(y_0, y_1, y_2), y_3)))
MARK(leq(leq(p(y_0), y_1), x1)) → MARK(leq(p(y_0), y_1))
MARK(leq(s(leq(y_0, y_1)), x1)) → MARK(s(leq(y_0, y_1)))
MARK(leq(p(p(leq(y_0, y_1))), x1)) → MARK(p(p(leq(y_0, y_1))))
MARK(leq(p(s(leq(y_0, y_1))), x1)) → MARK(p(s(leq(y_0, y_1))))
MARK(leq(p(s(p(p(y_0)))), x1)) → MARK(p(s(p(p(y_0)))))
MARK(leq(s(leq(y_0, s(y_1))), x1)) → MARK(s(leq(y_0, s(y_1))))
MARK(leq(p(s(diff(s(y_0), y_1))), x1)) → MARK(p(s(diff(s(y_0), y_1))))
MARK(leq(p(if(false, y_0, y_1)), x1)) → MARK(p(if(false, y_0, y_1)))
MARK(leq(leq(if(y_0, y_1, y_2), y_3), x1)) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(leq(s(if(s(y_0), y_1, y_2)), x1)) → MARK(s(if(s(y_0), y_1, y_2)))
MARK(leq(p(diff(y_0, diff(y_1, y_2))), x1)) → MARK(p(diff(y_0, diff(y_1, y_2))))
MARK(leq(s(diff(if(y_0, y_1, y_2), y_3)), x1)) → MARK(s(diff(if(y_0, y_1, y_2), y_3)))
MARK(leq(p(s(if(y_0, y_1, y_2))), x1)) → MARK(p(s(if(y_0, y_1, y_2))))
MARK(leq(leq(y_0, s(y_1)), x1)) → MARK(leq(y_0, s(y_1)))
MARK(leq(p(s(y_0)), x1)) → MARK(p(s(y_0)))
MARK(leq(p(diff(if(y_0, y_1, y_2), y_3)), x1)) → MARK(p(diff(if(y_0, y_1, y_2), y_3)))
MARK(leq(leq(y_0, p(y_1)), x1)) → MARK(leq(y_0, p(y_1)))
MARK(leq(diff(diff(y_0, y_1), y_2), x1)) → MARK(diff(diff(y_0, y_1), y_2))
MARK(leq(p(s(leq(y_0, if(y_1, y_2, y_3)))), x1)) → MARK(p(s(leq(y_0, if(y_1, y_2, y_3)))))
MARK(leq(s(p(diff(y_0, y_1))), x1)) → MARK(s(p(diff(y_0, y_1))))
MARK(leq(s(if(diff(y_0, y_1), y_2, y_3)), x1)) → MARK(s(if(diff(y_0, y_1), y_2, y_3)))
MARK(leq(diff(y_0, leq(y_1, y_2)), x1)) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(leq(s(leq(y_0, if(y_1, y_2, y_3))), x1)) → MARK(s(leq(y_0, if(y_1, y_2, y_3))))
MARK(leq(s(s(y_0)), x1)) → MARK(s(s(y_0)))
MARK(leq(s(diff(diff(y_0, y_1), y_2)), x1)) → MARK(s(diff(diff(y_0, y_1), y_2)))
MARK(leq(p(p(p(y_0))), x1)) → MARK(p(p(p(y_0))))
MARK(leq(s(diff(y_0, diff(y_1, y_2))), x1)) → MARK(s(diff(y_0, diff(y_1, y_2))))
MARK(leq(p(leq(y_0, leq(y_1, y_2))), x1)) → MARK(p(leq(y_0, leq(y_1, y_2))))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                  ↳ QDP
                    ↳ QDPOrderProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Rewriting
                              ↳ QDP
                                ↳ DependencyGraphProof
                                  ↳ QDP
                                    ↳ Rewriting
                                      ↳ QDP
                                        ↳ DependencyGraphProof
                                          ↳ QDP
                                            ↳ Rewriting
                                              ↳ QDP
                                                ↳ DependencyGraphProof
                                                  ↳ QDP
                                                    ↳ Narrowing
                                                      ↳ QDP
                                                        ↳ Narrowing
                                                          ↳ QDP
                                                            ↳ Rewriting
                                                              ↳ QDP
                                                                ↳ DependencyGraphProof
                                                                  ↳ QDP
                                                                    ↳ Rewriting
                                                                      ↳ QDP
                                                                        ↳ Rewriting
                                                                          ↳ QDP
                                                                            ↳ Narrowing
                                                                              ↳ QDP
                                                                                ↳ ForwardInstantiation
                                                                                  ↳ QDP
                                                                                    ↳ ForwardInstantiation
                                                                                      ↳ QDP
                                                                                        ↳ ForwardInstantiation
QDP
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

MARK(leq(s(diff(s(y_0), y_1)), x1)) → MARK(s(diff(s(y_0), y_1)))
MARK(s(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(s(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(leq(s(diff(0, y_0)), x1)) → MARK(s(diff(0, y_0)))
MARK(leq(s(diff(y_0, 0)), x1)) → MARK(s(diff(y_0, 0)))
MARK(leq(s(diff(y_0, if(y_1, y_2, y_3))), x1)) → MARK(s(diff(y_0, if(y_1, y_2, y_3))))
MARK(leq(p(s(diff(y_0, 0))), x1)) → MARK(p(s(diff(y_0, 0))))
MARK(leq(p(s(diff(0, y_0))), x1)) → MARK(p(s(diff(0, y_0))))
MARK(diff(y0, x1)) → ACTIVE(diff(mark(y0), x1))
MARK(diff(false, y1)) → ACTIVE(diff(active(false), mark(y1)))
MARK(diff(y0, false)) → ACTIVE(diff(mark(y0), active(false)))
MARK(leq(y0, x1)) → ACTIVE(leq(mark(y0), x1))
MARK(s(p(y_0))) → MARK(p(y_0))
MARK(leq(diff(true, y_0), x1)) → MARK(diff(true, y_0))
MARK(leq(diff(y_0, true), x1)) → MARK(diff(y_0, true))
MARK(p(s(leq(y_0, s(y_1))))) → MARK(s(leq(y_0, s(y_1))))
MARK(leq(diff(false, y_0), x1)) → MARK(diff(false, y_0))
MARK(leq(diff(y_0, false), x1)) → MARK(diff(y_0, false))
MARK(p(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(leq(p(leq(leq(y_0, y_1), y_2)), x1)) → MARK(p(leq(leq(y_0, y_1), y_2)))
MARK(p(s(p(if(y_0, y_1, y_2))))) → MARK(s(p(if(y_0, y_1, y_2))))
MARK(leq(p(s(leq(p(y_0), y_1))), x1)) → MARK(p(s(leq(p(y_0), y_1))))
MARK(leq(y0, p(x0))) → ACTIVE(leq(mark(y0), active(p(mark(x0)))))
MARK(leq(p(s(diff(if(y_0, y_1, y_2), y_3))), x1)) → MARK(p(s(diff(if(y_0, y_1, y_2), y_3))))
MARK(leq(p(diff(y_0, y_1)), x1)) → MARK(p(diff(y_0, y_1)))
MARK(leq(p(diff(y_0, true)), x1)) → MARK(p(diff(y_0, true)))
MARK(leq(p(diff(true, y_0)), x1)) → MARK(p(diff(true, y_0)))
MARK(leq(s(if(if(y_0, y_1, y_2), y_3, y_4)), x1)) → MARK(s(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(leq(p(s(diff(y_0, if(y_1, y_2, y_3)))), x1)) → MARK(p(s(diff(y_0, if(y_1, y_2, y_3)))))
MARK(p(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(leq(p(s(diff(p(y_0), y_1))), x1)) → MARK(p(s(diff(p(y_0), y_1))))
MARK(leq(p(s(diff(diff(y_0, y_1), y_2))), x1)) → MARK(p(s(diff(diff(y_0, y_1), y_2))))
MARK(s(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(s(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(leq(p(s(leq(y_0, false))), x1)) → MARK(p(s(leq(y_0, false))))
MARK(leq(p(s(leq(false, y_0))), x1)) → MARK(p(s(leq(false, y_0))))
MARK(s(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(diff(x0, y1)) → ACTIVE(diff(x0, mark(y1)))
MARK(diff(y0, p(x0))) → ACTIVE(diff(mark(y0), active(p(mark(x0)))))
MARK(leq(p(p(diff(y_0, y_1))), x1)) → MARK(p(p(diff(y_0, y_1))))
MARK(leq(leq(s(y_0), y_1), x1)) → MARK(leq(s(y_0), y_1))
MARK(p(s(diff(y_0, p(y_1))))) → MARK(s(diff(y_0, p(y_1))))
MARK(leq(y0, s(x0))) → ACTIVE(leq(mark(y0), active(s(mark(x0)))))
MARK(p(s(s(y_0)))) → MARK(s(s(y_0)))
MARK(leq(if(s(y_0), y_1, y_2), x1)) → MARK(if(s(y_0), y_1, y_2))
MARK(leq(if(y_0, y_1, y_2), x1)) → MARK(if(y_0, y_1, y_2))
MARK(s(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(leq(s(diff(y_0, false)), x1)) → MARK(s(diff(y_0, false)))
MARK(leq(s(diff(false, y_0)), x1)) → MARK(s(diff(false, y_0)))
MARK(p(s(leq(true, y_0)))) → MARK(s(leq(true, y_0)))
MARK(p(s(leq(y_0, true)))) → MARK(s(leq(y_0, true)))
MARK(diff(if(x0, x1, x2), y1)) → ACTIVE(diff(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(leq(p(s(diff(true, y_0))), x1)) → MARK(p(s(diff(true, y_0))))
MARK(leq(p(s(diff(y_0, true))), x1)) → MARK(p(s(diff(y_0, true))))
MARK(p(x0)) → ACTIVE(p(x0))
MARK(leq(p(if(y_0, y_1, y_2)), x1)) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(leq(if(leq(y_0, y_1), y_2, y_3), x1)) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(if(false, y1, y2)) → ACTIVE(if(false, y1, y2))
MARK(p(s(leq(if(y_0, y_1, y_2), y_3)))) → MARK(s(leq(if(y_0, y_1, y_2), y_3)))
MARK(leq(p(leq(s(y_0), y_1)), x1)) → MARK(p(leq(s(y_0), y_1)))
MARK(leq(p(leq(y_0, p(y_1))), x1)) → MARK(p(leq(y_0, p(y_1))))
MARK(p(s(leq(y_0, p(y_1))))) → MARK(s(leq(y_0, p(y_1))))
MARK(leq(diff(y_0, p(y_1)), x1)) → MARK(diff(y_0, p(y_1)))
MARK(p(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(p(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(p(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(leq(p(s(leq(diff(y_0, y_1), y_2))), x1)) → MARK(p(s(leq(diff(y_0, y_1), y_2))))
MARK(leq(if(if(y_0, y_1, y_2), y_3, y_4), x1)) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(leq(p(y_0), x1)) → MARK(p(y_0))
MARK(leq(leq(y_0, true), x1)) → MARK(leq(y_0, true))
MARK(leq(leq(true, y_0), x1)) → MARK(leq(true, y_0))
MARK(leq(p(leq(diff(y_0, y_1), y_2)), x1)) → MARK(p(leq(diff(y_0, y_1), y_2)))
MARK(leq(p(diff(y_0, false)), x1)) → MARK(p(diff(y_0, false)))
MARK(leq(p(diff(false, y_0)), x1)) → MARK(p(diff(false, y_0)))
MARK(leq(s(p(p(y_0))), x1)) → MARK(s(p(p(y_0))))
MARK(p(s(p(leq(y_0, y_1))))) → MARK(s(p(leq(y_0, y_1))))
MARK(p(s(leq(false, y_0)))) → MARK(s(leq(false, y_0)))
MARK(p(s(leq(y_0, false)))) → MARK(s(leq(y_0, false)))
MARK(leq(p(s(diff(y_0, p(y_1)))), x1)) → MARK(p(s(diff(y_0, p(y_1)))))
MARK(leq(p(diff(y_0, leq(y_1, y_2))), x1)) → MARK(p(diff(y_0, leq(y_1, y_2))))
MARK(p(s(if(y_0, y_1, y_2)))) → MARK(s(if(y_0, y_1, y_2)))
MARK(leq(if(diff(y_0, y_1), y_2, y_3), x1)) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(p(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(p(p(y_0)))) → MARK(p(p(y_0)))
MARK(leq(s(if(p(y_0), y_1, y_2)), x1)) → MARK(s(if(p(y_0), y_1, y_2)))
MARK(p(s(leq(y_0, if(y_1, y_2, y_3))))) → MARK(s(leq(y_0, if(y_1, y_2, y_3))))
MARK(leq(p(s(diff(y_0, y_1))), x1)) → MARK(p(s(diff(y_0, y_1))))
MARK(leq(p(s(diff(y_0, diff(y_1, y_2)))), x1)) → MARK(p(s(diff(y_0, diff(y_1, y_2)))))
MARK(if(if(x0, x1, x2), y1, y2)) → ACTIVE(if(active(if(mark(x0), x1, x2)), y1, y2))
MARK(leq(leq(y_0, y_1), x1)) → MARK(leq(y_0, y_1))
MARK(p(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(p(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(leq(p(s(p(if(y_0, y_1, y_2)))), x1)) → MARK(p(s(p(if(y_0, y_1, y_2)))))
MARK(leq(p(s(if(if(y_0, y_1, y_2), y_3, y_4))), x1)) → MARK(p(s(if(if(y_0, y_1, y_2), y_3, y_4))))
MARK(p(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(leq(s(diff(p(y_0), y_1)), x1)) → MARK(s(diff(p(y_0), y_1)))
MARK(p(s(p(diff(y_0, y_1))))) → MARK(s(p(diff(y_0, y_1))))
MARK(p(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(leq(s(p(if(y_0, y_1, y_2))), x1)) → MARK(s(p(if(y_0, y_1, y_2))))
MARK(s(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(p(s(x0))) → ACTIVE(p(active(s(mark(x0)))))
MARK(p(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(leq(s(leq(y_0, y_1)), x1)) → MARK(s(leq(y_0, y_1)))
MARK(s(leq(y_0, y_1))) → MARK(leq(y_0, y_1))
MARK(p(s(if(p(y_0), y_1, y_2)))) → MARK(s(if(p(y_0), y_1, y_2)))
MARK(leq(p(s(p(p(y_0)))), x1)) → MARK(p(s(p(p(y_0)))))
MARK(p(s(p(y_0)))) → MARK(s(p(y_0)))
MARK(leq(s(leq(y_0, s(y_1))), x1)) → MARK(s(leq(y_0, s(y_1))))
MARK(leq(p(s(diff(s(y_0), y_1))), x1)) → MARK(p(s(diff(s(y_0), y_1))))
MARK(p(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(s(diff(s(y_0), y_1))) → MARK(diff(s(y_0), y_1))
MARK(leq(y0, leq(x0, x1))) → ACTIVE(leq(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(p(if(false, y_0, y_1)), x1)) → MARK(p(if(false, y_0, y_1)))
MARK(leq(leq(if(y_0, y_1, y_2), y_3), x1)) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(leq(p(s(if(y_0, y_1, y_2))), x1)) → MARK(p(s(if(y_0, y_1, y_2))))
MARK(leq(leq(y_0, s(y_1)), x1)) → MARK(leq(y_0, s(y_1)))
MARK(leq(p(s(y_0)), x1)) → MARK(p(s(y_0)))
MARK(leq(p(diff(if(y_0, y_1, y_2), y_3)), x1)) → MARK(p(diff(if(y_0, y_1, y_2), y_3)))
MARK(leq(leq(y_0, p(y_1)), x1)) → MARK(leq(y_0, p(y_1)))
MARK(s(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(leq(s(diff(diff(y_0, y_1), y_2)), x1)) → MARK(s(diff(diff(y_0, y_1), y_2)))
MARK(leq(s(diff(y_0, diff(y_1, y_2))), x1)) → MARK(s(diff(y_0, diff(y_1, y_2))))
MARK(diff(y0, if(x0, x1, x2))) → ACTIVE(diff(mark(y0), active(if(mark(x0), x1, x2))))
MARK(leq(p(s(leq(leq(y_0, y_1), y_2))), x1)) → MARK(p(s(leq(leq(y_0, y_1), y_2))))
MARK(diff(s(x0), y1)) → ACTIVE(diff(active(s(mark(x0))), mark(y1)))
MARK(leq(p(s(diff(false, y_0))), x1)) → MARK(p(s(diff(false, y_0))))
MARK(leq(p(s(diff(y_0, false))), x1)) → MARK(p(s(diff(y_0, false))))
MARK(leq(if(x0, x1, x2), y1)) → ACTIVE(leq(active(if(mark(x0), x1, x2)), mark(y1)))
MARK(p(s(if(if(y_0, y_1, y_2), y_3, y_4)))) → MARK(s(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(p(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(p(leq(y_0, 0))) → MARK(leq(y_0, 0))
ACTIVE(p(s(X))) → MARK(X)
MARK(p(s(if(false, y_0, y_1)))) → MARK(s(if(false, y_0, y_1)))
MARK(diff(diff(x0, x1), y1)) → ACTIVE(diff(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(leq(p(leq(false, y_0)), x1)) → MARK(p(leq(false, y_0)))
MARK(leq(p(leq(y_0, false)), x1)) → MARK(p(leq(y_0, false)))
MARK(s(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(s(diff(leq(y_0, y_1), y_2))) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(leq(p(diff(y_0, s(y_1))), x1)) → MARK(p(diff(y_0, s(y_1))))
MARK(p(diff(diff(y_0, y_1), y_2))) → MARK(diff(diff(y_0, y_1), y_2))
MARK(p(leq(p(y_0), y_1))) → MARK(leq(p(y_0), y_1))
MARK(diff(y0, leq(x0, x1))) → ACTIVE(diff(mark(y0), active(leq(mark(x0), mark(x1)))))
MARK(leq(p(s(diff(leq(y_0, y_1), y_2))), x1)) → MARK(p(s(diff(leq(y_0, y_1), y_2))))
MARK(p(s(if(true, y_0, y_1)))) → MARK(s(if(true, y_0, y_1)))
MARK(leq(p(s(p(y_0))), x1)) → MARK(p(s(p(y_0))))
MARK(leq(p(s(leq(y_0, leq(y_1, y_2)))), x1)) → MARK(p(s(leq(y_0, leq(y_1, y_2)))))
MARK(diff(y0, s(x0))) → ACTIVE(diff(mark(y0), active(s(mark(x0)))))
MARK(p(p(leq(y_0, y_1)))) → MARK(p(leq(y_0, y_1)))
MARK(if(diff(x0, x1), y1, y2)) → ACTIVE(if(active(diff(mark(x0), mark(x1))), y1, y2))
MARK(leq(leq(leq(y_0, y_1), y_2), x1)) → MARK(leq(leq(y_0, y_1), y_2))
MARK(diff(x1, x2)) → MARK(x1)
MARK(if(leq(x0, x1), y1, y2)) → ACTIVE(if(active(leq(mark(x0), mark(x1))), y1, y2))
MARK(leq(diff(y_0, diff(y_1, y_2)), x1)) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(leq(p(s(diff(y_0, leq(y_1, y_2)))), x1)) → MARK(p(s(diff(y_0, leq(y_1, y_2)))))
MARK(leq(s(leq(diff(y_0, y_1), y_2)), x1)) → MARK(s(leq(diff(y_0, y_1), y_2)))
ACTIVE(diff(X, Y)) → MARK(if(leq(X, Y), 0, s(diff(p(X), Y))))
MARK(s(if(true, y_0, y_1))) → MARK(if(true, y_0, y_1))
MARK(p(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(if(p(x0), y1, y2)) → ACTIVE(if(active(p(mark(x0))), y1, y2))
MARK(leq(p(diff(leq(y_0, y_1), y_2)), x1)) → MARK(p(diff(leq(y_0, y_1), y_2)))
MARK(leq(p(p(y_0)), x1)) → MARK(p(p(y_0)))
MARK(leq(diff(y_0, if(y_1, y_2, y_3)), x1)) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(leq(leq(y_0, if(y_1, y_2, y_3)), x1)) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(leq(p(leq(true, y_0)), x1)) → MARK(p(leq(true, y_0)))
MARK(leq(p(leq(y_0, true)), x1)) → MARK(p(leq(y_0, true)))
MARK(leq(s(if(true, y_0, y_1)), x1)) → MARK(s(if(true, y_0, y_1)))
MARK(leq(p(p(s(y_0))), x1)) → MARK(p(p(s(y_0))))
MARK(leq(p(leq(y_0, 0)), x1)) → MARK(p(leq(y_0, 0)))
MARK(leq(p(leq(0, y_0)), x1)) → MARK(p(leq(0, y_0)))
MARK(leq(s(leq(y_0, p(y_1))), x1)) → MARK(s(leq(y_0, p(y_1))))
MARK(leq(s(diff(leq(y_0, y_1), y_2)), x1)) → MARK(s(diff(leq(y_0, y_1), y_2)))
MARK(s(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(p(s(diff(0, y_0)))) → MARK(s(diff(0, y_0)))
MARK(p(s(diff(y_0, 0)))) → MARK(s(diff(y_0, 0)))
MARK(s(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(p(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(s(p(diff(y_0, y_1)))) → MARK(p(diff(y_0, y_1)))
MARK(leq(s(leq(y_0, leq(y_1, y_2))), x1)) → MARK(s(leq(y_0, leq(y_1, y_2))))
MARK(leq(s(leq(p(y_0), y_1)), x1)) → MARK(s(leq(p(y_0), y_1)))
MARK(s(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(s(s(y_0))) → MARK(s(y_0))
MARK(leq(p(s(leq(0, y_0))), x1)) → MARK(p(s(leq(0, y_0))))
MARK(leq(p(s(leq(y_0, 0))), x1)) → MARK(p(s(leq(y_0, 0))))
MARK(leq(leq(0, y_0), x1)) → MARK(leq(0, y_0))
MARK(leq(leq(y_0, 0), x1)) → MARK(leq(y_0, 0))
MARK(leq(p(diff(y_0, if(y_1, y_2, y_3))), x1)) → MARK(p(diff(y_0, if(y_1, y_2, y_3))))
MARK(s(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(p(s(if(s(y_0), y_1, y_2)))) → MARK(s(if(s(y_0), y_1, y_2)))
MARK(leq(s(diff(y_0, y_1)), x1)) → MARK(s(diff(y_0, y_1)))
MARK(s(leq(y_0, s(y_1)))) → MARK(leq(y_0, s(y_1)))
MARK(s(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(leq(if(false, y_0, y_1), x1)) → MARK(if(false, y_0, y_1))
MARK(if(x0, x1, x2)) → ACTIVE(if(x0, x1, x2))
MARK(leq(p(s(if(true, y_0, y_1))), x1)) → MARK(p(s(if(true, y_0, y_1))))
MARK(leq(s(if(leq(y_0, y_1), y_2, y_3)), x1)) → MARK(s(if(leq(y_0, y_1), y_2, y_3)))
MARK(s(diff(y_0, p(y_1)))) → MARK(diff(y_0, p(y_1)))
MARK(leq(diff(y_0, s(y_1)), x1)) → MARK(diff(y_0, s(y_1)))
MARK(p(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(p(s(diff(leq(y_0, y_1), y_2)))) → MARK(s(diff(leq(y_0, y_1), y_2)))
MARK(leq(p(p(if(y_0, y_1, y_2))), x1)) → MARK(p(p(if(y_0, y_1, y_2))))
MARK(p(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(leq(p(diff(p(y_0), y_1)), x1)) → MARK(p(diff(p(y_0), y_1)))
ACTIVE(if(false, X, Y)) → MARK(Y)
MARK(p(leq(x0, x1))) → ACTIVE(p(active(leq(mark(x0), mark(x1)))))
MARK(leq(p(s(leq(y_0, s(y_1)))), x1)) → MARK(p(s(leq(y_0, s(y_1)))))
MARK(s(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(s(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(diff(y0, 0)) → ACTIVE(diff(mark(y0), active(0)))
MARK(diff(0, y1)) → ACTIVE(diff(active(0), mark(y1)))
MARK(p(s(diff(y_0, s(y_1))))) → MARK(s(diff(y_0, s(y_1))))
MARK(leq(p(p(leq(y_0, y_1))), x1)) → MARK(p(p(leq(y_0, y_1))))
MARK(p(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(leq(p(diff(y_0, diff(y_1, y_2))), x1)) → MARK(p(diff(y_0, diff(y_1, y_2))))
MARK(leq(s(diff(if(y_0, y_1, y_2), y_3)), x1)) → MARK(s(diff(if(y_0, y_1, y_2), y_3)))
MARK(p(s(leq(0, y_0)))) → MARK(s(leq(0, y_0)))
MARK(p(s(leq(y_0, 0)))) → MARK(s(leq(y_0, 0)))
MARK(s(leq(0, y_0))) → MARK(leq(0, y_0))
MARK(s(leq(y_0, 0))) → MARK(leq(y_0, 0))
MARK(leq(diff(diff(y_0, y_1), y_2), x1)) → MARK(diff(diff(y_0, y_1), y_2))
MARK(leq(p(s(leq(y_0, if(y_1, y_2, y_3)))), x1)) → MARK(p(s(leq(y_0, if(y_1, y_2, y_3)))))
MARK(leq(s(leq(y_0, if(y_1, y_2, y_3))), x1)) → MARK(s(leq(y_0, if(y_1, y_2, y_3))))
MARK(leq(diff(y_0, leq(y_1, y_2)), x1)) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(leq(p(p(p(y_0))), x1)) → MARK(p(p(p(y_0))))
MARK(leq(p(leq(y_0, leq(y_1, y_2))), x1)) → MARK(p(leq(y_0, leq(y_1, y_2))))
MARK(leq(y0, 0)) → ACTIVE(leq(mark(y0), active(0)))
MARK(leq(0, y1)) → ACTIVE(leq(active(0), mark(y1)))
MARK(leq(s(leq(true, y_0)), x1)) → MARK(s(leq(true, y_0)))
MARK(leq(s(leq(y_0, true)), x1)) → MARK(s(leq(y_0, true)))
MARK(diff(x1, x2)) → MARK(x2)
MARK(diff(y0, diff(x0, x1))) → ACTIVE(diff(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(leq(p(s(if(diff(y_0, y_1), y_2, y_3))), x1)) → MARK(p(s(if(diff(y_0, y_1), y_2, y_3))))
MARK(if(x1, x2, x3)) → MARK(x1)
MARK(leq(leq(y_0, diff(y_1, y_2)), x1)) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(s(if(diff(y_0, y_1), y_2, y_3)))) → MARK(s(if(diff(y_0, y_1), y_2, y_3)))
MARK(p(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(p(leq(true, y_0))) → MARK(leq(true, y_0))
ACTIVE(leq(s(X), s(Y))) → MARK(leq(X, Y))
MARK(p(diff(y_0, y_1))) → MARK(diff(y_0, y_1))
MARK(leq(leq(diff(y_0, y_1), y_2), x1)) → MARK(leq(diff(y_0, y_1), y_2))
MARK(p(p(y_0))) → MARK(p(y_0))
MARK(p(s(leq(y_0, leq(y_1, y_2))))) → MARK(s(leq(y_0, leq(y_1, y_2))))
MARK(s(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(leq(s(x0), y1)) → ACTIVE(leq(active(s(mark(x0))), mark(y1)))
MARK(if(s(x0), y1, y2)) → ACTIVE(if(active(s(mark(x0))), y1, y2))
MARK(p(leq(y_0, p(y_1)))) → MARK(leq(y_0, p(y_1)))
MARK(p(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(p(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(leq(s(leq(leq(y_0, y_1), y_2)), x1)) → MARK(s(leq(leq(y_0, y_1), y_2)))
MARK(leq(p(s(leq(y_0, diff(y_1, y_2)))), x1)) → MARK(p(s(leq(y_0, diff(y_1, y_2)))))
MARK(leq(s(diff(y_0, p(y_1))), x1)) → MARK(s(diff(y_0, p(y_1))))
MARK(p(s(p(p(y_0))))) → MARK(s(p(p(y_0))))
MARK(s(diff(y_0, 0))) → MARK(diff(y_0, 0))
MARK(s(diff(0, y_0))) → MARK(diff(0, y_0))
MARK(leq(p(leq(y_0, if(y_1, y_2, y_3))), x1)) → MARK(p(leq(y_0, if(y_1, y_2, y_3))))
MARK(s(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(leq(p(s(leq(s(y_0), y_1))), x1)) → MARK(p(s(leq(s(y_0), y_1))))
MARK(p(s(diff(y_0, true)))) → MARK(s(diff(y_0, true)))
MARK(p(s(diff(true, y_0)))) → MARK(s(diff(true, y_0)))
ACTIVE(if(true, X, Y)) → MARK(X)
MARK(if(true, y1, y2)) → ACTIVE(if(true, y1, y2))
MARK(leq(p(s(leq(y_0, p(y_1)))), x1)) → MARK(p(s(leq(y_0, p(y_1)))))
MARK(leq(diff(p(y_0), y_1), x1)) → MARK(diff(p(y_0), y_1))
MARK(leq(if(true, y_0, y_1), x1)) → MARK(if(true, y_0, y_1))
MARK(leq(p(s(if(p(y_0), y_1, y_2))), x1)) → MARK(p(s(if(p(y_0), y_1, y_2))))
MARK(leq(s(leq(false, y_0)), x1)) → MARK(s(leq(false, y_0)))
MARK(leq(s(leq(y_0, false)), x1)) → MARK(s(leq(y_0, false)))
MARK(leq(s(leq(s(y_0), y_1)), x1)) → MARK(s(leq(s(y_0), y_1)))
MARK(leq(p(if(s(y_0), y_1, y_2)), x1)) → MARK(p(if(s(y_0), y_1, y_2)))
MARK(leq(s(leq(y_0, 0)), x1)) → MARK(s(leq(y_0, 0)))
MARK(leq(s(leq(0, y_0)), x1)) → MARK(s(leq(0, y_0)))
MARK(p(if(diff(y_0, y_1), y_2, y_3))) → MARK(if(diff(y_0, y_1), y_2, y_3))
MARK(leq(p(s(if(false, y_0, y_1))), x1)) → MARK(p(s(if(false, y_0, y_1))))
MARK(diff(true, y1)) → ACTIVE(diff(active(true), mark(y1)))
MARK(diff(y0, true)) → ACTIVE(diff(mark(y0), active(true)))
MARK(leq(p(leq(if(y_0, y_1, y_2), y_3)), x1)) → MARK(p(leq(if(y_0, y_1, y_2), y_3)))
MARK(p(s(leq(y_0, y_1)))) → MARK(s(leq(y_0, y_1)))
MARK(p(leq(s(y_0), y_1))) → MARK(leq(s(y_0), y_1))
MARK(p(s(if(leq(y_0, y_1), y_2, y_3)))) → MARK(s(if(leq(y_0, y_1), y_2, y_3)))
MARK(leq(s(p(leq(y_0, y_1))), x1)) → MARK(s(p(leq(y_0, y_1))))
MARK(p(diff(x0, x1))) → ACTIVE(p(active(diff(mark(x0), mark(x1)))))
MARK(leq(leq(y_0, false), x1)) → MARK(leq(y_0, false))
MARK(leq(leq(false, y_0), x1)) → MARK(leq(false, y_0))
MARK(diff(leq(x0, x1), y1)) → ACTIVE(diff(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(s(diff(y_0, s(y_1))), x1)) → MARK(s(diff(y_0, s(y_1))))
MARK(s(if(false, y_0, y_1))) → MARK(if(false, y_0, y_1))
MARK(p(leq(y_0, diff(y_1, y_2)))) → MARK(leq(y_0, diff(y_1, y_2)))
MARK(p(s(diff(y_0, diff(y_1, y_2))))) → MARK(s(diff(y_0, diff(y_1, y_2))))
MARK(leq(y0, if(x0, x1, x2))) → ACTIVE(leq(mark(y0), active(if(mark(x0), x1, x2))))
MARK(leq(p(s(leq(y_0, true))), x1)) → MARK(p(s(leq(y_0, true))))
MARK(leq(p(s(leq(true, y_0))), x1)) → MARK(p(s(leq(true, y_0))))
MARK(leq(p(diff(0, y_0)), x1)) → MARK(p(diff(0, y_0)))
MARK(leq(p(diff(y_0, 0)), x1)) → MARK(p(diff(y_0, 0)))
MARK(s(leq(false, y_0))) → MARK(leq(false, y_0))
MARK(s(leq(y_0, false))) → MARK(leq(y_0, false))
MARK(leq(p(leq(y_0, y_1)), x1)) → MARK(p(leq(y_0, y_1)))
MARK(p(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(p(s(diff(diff(y_0, y_1), y_2)))) → MARK(s(diff(diff(y_0, y_1), y_2)))
MARK(p(leq(diff(y_0, y_1), y_2))) → MARK(leq(diff(y_0, y_1), y_2))
MARK(leq(s(p(y_0)), x1)) → MARK(s(p(y_0)))
MARK(leq(p(s(p(s(y_0)))), x1)) → MARK(p(s(p(s(y_0)))))
MARK(diff(p(x0), y1)) → ACTIVE(diff(active(p(mark(x0))), mark(y1)))
MARK(leq(s(leq(if(y_0, y_1, y_2), y_3)), x1)) → MARK(s(leq(if(y_0, y_1, y_2), y_3)))
MARK(leq(leq(p(y_0), y_1), x1)) → MARK(leq(p(y_0), y_1))
MARK(p(s(leq(p(y_0), y_1)))) → MARK(s(leq(p(y_0), y_1)))
MARK(leq(p(s(leq(y_0, y_1))), x1)) → MARK(p(s(leq(y_0, y_1))))
MARK(p(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(p(s(diff(y_0, if(y_1, y_2, y_3))))) → MARK(s(diff(y_0, if(y_1, y_2, y_3))))
MARK(p(s(diff(y_0, leq(y_1, y_2))))) → MARK(s(diff(y_0, leq(y_1, y_2))))
MARK(s(p(if(y_0, y_1, y_2)))) → MARK(p(if(y_0, y_1, y_2)))
MARK(leq(s(p(diff(y_0, y_1))), x1)) → MARK(s(p(diff(y_0, y_1))))
MARK(p(diff(p(y_0), y_1))) → MARK(diff(p(y_0), y_1))
MARK(leq(p(leq(p(y_0), y_1)), x1)) → MARK(p(leq(p(y_0), y_1)))
MARK(leq(s(if(y_0, y_1, y_2)), x1)) → MARK(s(if(y_0, y_1, y_2)))
MARK(leq(x1, x2)) → MARK(x2)
MARK(s(if(leq(y_0, y_1), y_2, y_3))) → MARK(if(leq(y_0, y_1), y_2, y_3))
MARK(leq(p(diff(y_0, p(y_1))), x1)) → MARK(p(diff(y_0, p(y_1))))
MARK(p(s(leq(diff(y_0, y_1), y_2)))) → MARK(s(leq(diff(y_0, y_1), y_2)))
MARK(leq(diff(leq(y_0, y_1), y_2), x1)) → MARK(diff(leq(y_0, y_1), y_2))
MARK(p(s(diff(y_0, false)))) → MARK(s(diff(y_0, false)))
MARK(p(s(diff(false, y_0)))) → MARK(s(diff(false, y_0)))
MARK(leq(p(s(p(leq(y_0, y_1)))), x1)) → MARK(p(s(p(leq(y_0, y_1)))))
MARK(leq(x0, y1)) → ACTIVE(leq(x0, mark(y1)))
MARK(s(leq(y_0, leq(y_1, y_2)))) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(leq(p(x0), y1)) → ACTIVE(leq(active(p(mark(x0))), mark(y1)))
MARK(p(s(diff(p(y_0), y_1)))) → MARK(s(diff(p(y_0), y_1)))
MARK(leq(leq(y_0, leq(y_1, y_2)), x1)) → MARK(leq(y_0, leq(y_1, y_2)))
MARK(leq(diff(x0, x1), y1)) → ACTIVE(leq(active(diff(mark(x0), mark(x1))), mark(y1)))
MARK(p(diff(if(y_0, y_1, y_2), y_3))) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(s(diff(y_0, false))) → MARK(diff(y_0, false))
MARK(s(diff(false, y_0))) → MARK(diff(false, y_0))
MARK(s(leq(if(y_0, y_1, y_2), y_3))) → MARK(leq(if(y_0, y_1, y_2), y_3))
MARK(leq(p(leq(y_0, s(y_1))), x1)) → MARK(p(leq(y_0, s(y_1))))
MARK(leq(s(p(s(y_0))), x1)) → MARK(s(p(s(y_0))))
MARK(leq(p(s(if(leq(y_0, y_1), y_2, y_3))), x1)) → MARK(p(s(if(leq(y_0, y_1), y_2, y_3))))
MARK(leq(s(diff(y_0, leq(y_1, y_2))), x1)) → MARK(s(diff(y_0, leq(y_1, y_2))))
MARK(s(diff(y_0, s(y_1)))) → MARK(diff(y_0, s(y_1)))
MARK(s(leq(true, y_0))) → MARK(leq(true, y_0))
MARK(s(leq(y_0, true))) → MARK(leq(y_0, true))
MARK(leq(p(if(diff(y_0, y_1), y_2, y_3)), x1)) → MARK(p(if(diff(y_0, y_1), y_2, y_3)))
MARK(p(p(s(y_0)))) → MARK(p(s(y_0)))
MARK(p(s(diff(if(y_0, y_1, y_2), y_3)))) → MARK(s(diff(if(y_0, y_1, y_2), y_3)))
MARK(p(diff(true, y_0))) → MARK(diff(true, y_0))
MARK(p(diff(y_0, true))) → MARK(diff(y_0, true))
MARK(p(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(leq(p(if(true, y_0, y_1)), x1)) → MARK(p(if(true, y_0, y_1)))
MARK(p(s(leq(s(y_0), y_1)))) → MARK(s(leq(s(y_0), y_1)))
MARK(leq(diff(y_0, y_1), x1)) → MARK(diff(y_0, y_1))
MARK(p(s(diff(s(y_0), y_1)))) → MARK(s(diff(s(y_0), y_1)))
MARK(p(if(x0, x1, x2))) → ACTIVE(p(active(if(mark(x0), x1, x2))))
MARK(leq(s(if(false, y_0, y_1)), x1)) → MARK(s(if(false, y_0, y_1)))
MARK(leq(p(s(diff(y_0, s(y_1)))), x1)) → MARK(p(s(diff(y_0, s(y_1)))))
MARK(leq(s(leq(y_0, diff(y_1, y_2))), x1)) → MARK(s(leq(y_0, diff(y_1, y_2))))
MARK(leq(p(diff(s(y_0), y_1)), x1)) → MARK(p(diff(s(y_0), y_1)))
MARK(p(s(leq(y_0, diff(y_1, y_2))))) → MARK(s(leq(y_0, diff(y_1, y_2))))
MARK(s(leq(leq(y_0, y_1), y_2))) → MARK(leq(leq(y_0, y_1), y_2))
MARK(p(if(y_0, y_1, y_2))) → MARK(if(y_0, y_1, y_2))
MARK(p(s(leq(leq(y_0, y_1), y_2)))) → MARK(s(leq(leq(y_0, y_1), y_2)))
MARK(s(diff(y_0, if(y_1, y_2, y_3)))) → MARK(diff(y_0, if(y_1, y_2, y_3)))
MARK(leq(diff(y_0, 0), x1)) → MARK(diff(y_0, 0))
MARK(leq(diff(0, y_0), x1)) → MARK(diff(0, y_0))
MARK(p(if(s(y_0), y_1, y_2))) → MARK(if(s(y_0), y_1, y_2))
MARK(leq(diff(s(y_0), y_1), x1)) → MARK(diff(s(y_0), y_1))
MARK(leq(leq(x0, x1), y1)) → ACTIVE(leq(active(leq(mark(x0), mark(x1))), mark(y1)))
MARK(leq(s(diff(y_0, true)), x1)) → MARK(s(diff(y_0, true)))
MARK(leq(s(diff(true, y_0)), x1)) → MARK(s(diff(true, y_0)))
MARK(leq(p(if(if(y_0, y_1, y_2), y_3, y_4)), x1)) → MARK(p(if(if(y_0, y_1, y_2), y_3, y_4)))
MARK(leq(p(if(p(y_0), y_1, y_2)), x1)) → MARK(p(if(p(y_0), y_1, y_2)))
MARK(leq(y0, diff(x0, x1))) → ACTIVE(leq(mark(y0), active(diff(mark(x0), mark(x1)))))
MARK(s(leq(y_0, if(y_1, y_2, y_3)))) → MARK(leq(y_0, if(y_1, y_2, y_3)))
MARK(leq(diff(if(y_0, y_1, y_2), y_3), x1)) → MARK(diff(if(y_0, y_1, y_2), y_3))
MARK(leq(if(p(y_0), y_1, y_2), x1)) → MARK(if(p(y_0), y_1, y_2))
MARK(leq(p(s(leq(if(y_0, y_1, y_2), y_3))), x1)) → MARK(p(s(leq(if(y_0, y_1, y_2), y_3))))
MARK(leq(p(leq(y_0, diff(y_1, y_2))), x1)) → MARK(p(leq(y_0, diff(y_1, y_2))))
MARK(leq(p(s(p(diff(y_0, y_1)))), x1)) → MARK(p(s(p(diff(y_0, y_1)))))
MARK(p(diff(y_0, diff(y_1, y_2)))) → MARK(diff(y_0, diff(y_1, y_2)))
MARK(leq(p(s(s(y_0))), x1)) → MARK(p(s(s(y_0))))
MARK(leq(false, y1)) → ACTIVE(leq(active(false), mark(y1)))
MARK(leq(y0, false)) → ACTIVE(leq(mark(y0), active(false)))
MARK(p(s(p(s(y_0))))) → MARK(s(p(s(y_0))))
MARK(leq(true, y1)) → ACTIVE(leq(active(true), mark(y1)))
MARK(leq(y0, true)) → ACTIVE(leq(mark(y0), active(true)))
MARK(p(s(diff(y_0, y_1)))) → MARK(s(diff(y_0, y_1)))
MARK(leq(p(diff(diff(y_0, y_1), y_2)), x1)) → MARK(p(diff(diff(y_0, y_1), y_2)))
MARK(leq(p(s(if(s(y_0), y_1, y_2))), x1)) → MARK(p(s(if(s(y_0), y_1, y_2))))
MARK(leq(p(if(leq(y_0, y_1), y_2, y_3)), x1)) → MARK(p(if(leq(y_0, y_1), y_2, y_3)))
MARK(p(diff(y_0, leq(y_1, y_2)))) → MARK(diff(y_0, leq(y_1, y_2)))
MARK(s(if(p(y_0), y_1, y_2))) → MARK(if(p(y_0), y_1, y_2))
MARK(leq(s(if(s(y_0), y_1, y_2)), x1)) → MARK(s(if(s(y_0), y_1, y_2)))
MARK(p(p(x0))) → ACTIVE(p(active(p(mark(x0)))))
MARK(s(if(if(y_0, y_1, y_2), y_3, y_4))) → MARK(if(if(y_0, y_1, y_2), y_3, y_4))
MARK(leq(s(if(diff(y_0, y_1), y_2, y_3)), x1)) → MARK(s(if(diff(y_0, y_1), y_2, y_3)))
MARK(leq(s(s(y_0)), x1)) → MARK(s(s(y_0)))

The TRS R consists of the following rules:

active(p(0)) → mark(0)
active(p(s(X))) → mark(X)
active(leq(0, Y)) → mark(true)
active(leq(s(X), 0)) → mark(false)
active(leq(s(X), s(Y))) → mark(leq(X, Y))
active(if(true, X, Y)) → mark(X)
active(if(false, X, Y)) → mark(Y)
active(diff(X, Y)) → mark(if(leq(X, Y), 0, s(diff(p(X), Y))))
mark(p(x1)) → active(p(mark(x1)))
p(active(x1)) → p(x1)
p(mark(x1)) → p(x1)
mark(0) → active(0)
mark(s(x1)) → active(s(mark(x1)))
s(active(x1)) → s(x1)
s(mark(x1)) → s(x1)
mark(leq(x1, x2)) → active(leq(mark(x1), mark(x2)))
leq(active(x1), x2) → leq(x1, x2)
leq(mark(x1), x2) → leq(x1, x2)
leq(x1, active(x2)) → leq(x1, x2)
leq(x1, mark(x2)) → leq(x1, x2)
mark(true) → active(true)
mark(false) → active(false)
mark(if(x1, x2, x3)) → active(if(mark(x1), x2, x3))
if(active(x1), x2, x3) → if(x1, x2, x3)
if(mark(x1), x2, x3) → if(x1, x2, x3)
mark(diff(x1, x2)) → active(diff(mark(x1), mark(x2)))
diff(active(x1), x2) → diff(x1, x2)
diff(mark(x1), x2) → diff(x1, x2)
diff(x1, active(x2)) → diff(x1, x2)
diff(x1, mark(x2)) → diff(x1, x2)

The set Q consists of the following terms:

active(p(0))
active(p(s(x0)))
active(leq(0, x0))
active(leq(s(x0), 0))
active(leq(s(x0), s(x1)))
active(if(true, x0, x1))
active(if(false, x0, x1))
active(diff(x0, x1))
mark(p(x0))
p(active(x0))
p(mark(x0))
mark(0)
mark(s(x0))
s(active(x0))
s(mark(x0))
mark(leq(x0, x1))
leq(active(x0), x1)
leq(mark(x0), x1)
leq(x0, active(x1))
leq(x0, mark(x1))
mark(true)
mark(false)
mark(if(x0, x1, x2))
if(active(x0), x1, x2)
if(mark(x0), x1, x2)
mark(diff(x0, x1))
diff(active(x0), x1)
diff(mark(x0), x1)
diff(x0, active(x1))
diff(x0, mark(x1))

We have to consider all minimal (P,Q,R)-chains.
We applied the Trivial transformation to transform the context-sensitive TRS to a usual TRS.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
QTRS
          ↳ Overlay + Local Confluence
      ↳ Improved Ferreira Ribeiro-Transformation

Q restricted rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

Q is empty.

The TRS is overlay and locally confluent. By [19] we can switch to innermost.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
QTRS
              ↳ DependencyPairsProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q restricted rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)


Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
DIFF(X, Y) → P(X)
DIFF(X, Y) → LEQ(X, Y)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
QDP
                  ↳ DependencyGraphProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
DIFF(X, Y) → P(X)
DIFF(X, Y) → LEQ(X, Y)
DIFF(X, Y) → IF(leq(X, Y), 0, s(diff(p(X), Y)))

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 2 SCCs with 3 less nodes.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
QDP
                        ↳ UsableRulesProof
                      ↳ QDP
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                        ↳ UsableRulesProof
QDP
                            ↳ QReductionProof
                      ↳ QDP
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

R is empty.
The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                        ↳ UsableRulesProof
                          ↳ QDP
                            ↳ QReductionProof
QDP
                                ↳ QDPSizeChangeProof
                      ↳ QDP
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

R is empty.
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
QDP
                        ↳ UsableRulesProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → X
if(false, X, Y) → Y
diff(X, Y) → if(leq(X, Y), 0, s(diff(p(X), Y)))

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                      ↳ QDP
                        ↳ UsableRulesProof
QDP
                            ↳ QReductionProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X

The set Q consists of the following terms:

p(0)
p(s(x0))
leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

leq(0, x0)
leq(s(x0), 0)
leq(s(x0), s(x1))
if(true, x0, x1)
if(false, x0, x1)
diff(x0, x1)



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                      ↳ QDP
                        ↳ UsableRulesProof
                          ↳ QDP
                            ↳ QReductionProof
QDP
                                ↳ UsableRulesReductionPairsProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X

The set Q consists of the following terms:

p(0)
p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
By using the usable rules with reduction pair processor [15] with a polynomial ordering [25], all dependency pairs and the corresponding usable rules [17] can be oriented non-strictly. All non-usable rules are removed, and those dependency pairs and usable rules that have been oriented strictly or contain non-usable symbols in their left-hand side are removed as well.

No dependency pairs are removed.

The following rules are removed from R:

p(s(X)) → X
Used ordering: POLO with Polynomial interpretation [25]:

POL(0) = 0   
POL(DIFF(x1, x2)) = 2·x1 + x2   
POL(p(x1)) = x1   
POL(s(x1)) = x1   



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                      ↳ QDP
                        ↳ UsableRulesProof
                          ↳ QDP
                            ↳ QReductionProof
                              ↳ QDP
                                ↳ UsableRulesReductionPairsProof
QDP
                                    ↳ QReductionProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

The set Q consists of the following terms:

p(0)
p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as they contain symbols which do neither occur in P nor in R.

p(s(x0))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                      ↳ QDP
                        ↳ UsableRulesProof
                          ↳ QDP
                            ↳ QReductionProof
                              ↳ QDP
                                ↳ UsableRulesReductionPairsProof
                                  ↳ QDP
                                    ↳ QReductionProof
QDP
                                        ↳ MNOCProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

The set Q consists of the following terms:

p(0)

We have to consider all (P,Q,R)-chains.
We use the modular non-overlap check [17] to decrease Q to the empty set.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
        ↳ QTRS
          ↳ Overlay + Local Confluence
            ↳ QTRS
              ↳ DependencyPairsProof
                ↳ QDP
                  ↳ DependencyGraphProof
                    ↳ AND
                      ↳ QDP
                      ↳ QDP
                        ↳ UsableRulesProof
                          ↳ QDP
                            ↳ QReductionProof
                              ↳ QDP
                                ↳ UsableRulesReductionPairsProof
                                  ↳ QDP
                                    ↳ QReductionProof
                                      ↳ QDP
                                        ↳ MNOCProof
QDP
                                            ↳ NonTerminationProof
      ↳ Improved Ferreira Ribeiro-Transformation

Q DP problem:
The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0

Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

DIFF(X, Y) → DIFF(p(X), Y)

The TRS R consists of the following rules:

p(0) → 0


s = DIFF(X, Y) evaluates to t =DIFF(p(X), Y)

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from DIFF(X, Y) to DIFF(p(X), Y).




We applied the Improved Ferreira Ribeiro transformation [5,11] to transform the context-sensitive TRS to a usual TRS.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
QTRS
          ↳ DependencyPairsProof

Q restricted rewrite system:
The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.

Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

A(sInact(x1)) → S(a(x1))
A(diffInact(x1, x2)) → A(x2)
DIFF(X, Y) → LEQ(X, Y)
A(0Inact) → 01
IF(true, X, Y) → A(X)
A(diffInact(x1, x2)) → A(x1)
IF(false, X, Y) → A(Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
A(pInact(x1)) → P(a(x1))
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
QDP
              ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

A(sInact(x1)) → S(a(x1))
A(diffInact(x1, x2)) → A(x2)
DIFF(X, Y) → LEQ(X, Y)
A(0Inact) → 01
IF(true, X, Y) → A(X)
A(diffInact(x1, x2)) → A(x1)
IF(false, X, Y) → A(Y)
LEQ(s(X), s(Y)) → LEQ(X, Y)
A(pInact(x1)) → P(a(x1))
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 2 SCCs with 4 less nodes.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
QDP
                    ↳ UsableRulesProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We can use the usable rules and reduction pair processor [15] with the Ce-compatible extension of the polynomial order that maps every function symbol to the sum of its argument. Then, we can delete all non-usable rules [17] from R.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ QDPSizeChangeProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

LEQ(s(X), s(Y)) → LEQ(X, Y)

R is empty.
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
QDP
                    ↳ Instantiation

Q DP problem:
The TRS P consists of the following rules:

IF(true, X, Y) → A(X)
A(diffInact(x1, x2)) → A(x2)
A(diffInact(x1, x2)) → A(x1)
IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By instantiating [15] the rule IF(true, X, Y) → A(X) we obtained the following new rules:

IF(true, 0Inact, sInact(diffInact(pInact(y_3), y_4))) → A(0Inact)



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
QDP
                        ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

A(diffInact(x1, x2)) → A(x1)
A(diffInact(x1, x2)) → A(x2)
IF(false, X, Y) → A(Y)
IF(true, 0Inact, sInact(diffInact(pInact(y_3), y_4))) → A(0Inact)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 1 SCC with 1 less node.

↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
                      ↳ QDP
                        ↳ DependencyGraphProof
QDP
                            ↳ QDPOrderProof

Q DP problem:
The TRS P consists of the following rules:

A(diffInact(x1, x2)) → A(x2)
A(diffInact(x1, x2)) → A(x1)
IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


A(diffInact(x1, x2)) → A(x2)
A(diffInact(x1, x2)) → A(x1)
The remaining pairs can at least be oriented weakly.

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)
Used ordering: Polynomial interpretation [25]:

POL(0) = 0   
POL(0Inact) = 0   
POL(A(x1)) = x1   
POL(DIFF(x1, x2)) = 1 + x1 + x2   
POL(IF(x1, x2, x3)) = x3   
POL(a(x1)) = x1   
POL(diff(x1, x2)) = 1 + x1 + x2   
POL(diffInact(x1, x2)) = 1 + x1 + x2   
POL(false) = 0   
POL(if(x1, x2, x3)) = x2 + x3   
POL(leq(x1, x2)) = 0   
POL(p(x1)) = x1   
POL(pInact(x1)) = x1   
POL(s(x1)) = x1   
POL(sInact(x1)) = x1   
POL(true) = 0   

The following usable rules [17] were oriented:

a(0Inact) → 0
diff(x1, x2) → diffInact(x1, x2)
a(sInact(x1)) → s(a(x1))
00Inact
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
if(false, X, Y) → a(Y)
if(true, X, Y) → a(X)
p(x1) → pInact(x1)
a(x) → x
s(x1) → sInact(x1)
a(pInact(x1)) → p(a(x1))
p(s(X)) → X
p(0) → 0



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
                      ↳ QDP
                        ↳ DependencyGraphProof
                          ↳ QDP
                            ↳ QDPOrderProof
QDP
                                ↳ QDPOrderProof
                                ↳ QDPOrderProof

Q DP problem:
The TRS P consists of the following rules:

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(pInact(x1)) → A(x1)
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


A(pInact(x1)) → A(x1)
The remaining pairs can at least be oriented weakly.

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)
Used ordering: Polynomial interpretation with max and min functions [25]:

POL(0) = 0   
POL(0Inact) = 0   
POL(A(x1)) = x1   
POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = x3   
POL(a(x1)) = 0   
POL(diff(x1, x2)) = 0   
POL(diffInact(x1, x2)) = 0   
POL(false) = 0   
POL(if(x1, x2, x3)) = 0   
POL(leq(x1, x2)) = 0   
POL(p(x1)) = 0   
POL(pInact(x1)) = 1 + x1   
POL(s(x1)) = 0   
POL(sInact(x1)) = x1   
POL(true) = 0   

The following usable rules [17] were oriented: none



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
                      ↳ QDP
                        ↳ DependencyGraphProof
                          ↳ QDP
                            ↳ QDPOrderProof
                              ↳ QDP
                                ↳ QDPOrderProof
QDP
                                    ↳ Instantiation
                                ↳ QDPOrderProof

Q DP problem:
The TRS P consists of the following rules:

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
By instantiating [15] the rule IF(false, X, Y) → A(Y) we obtained the following new rules:

IF(false, 0Inact, sInact(diffInact(pInact(y_3), y_4))) → A(sInact(diffInact(pInact(y_3), y_4)))



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
                      ↳ QDP
                        ↳ DependencyGraphProof
                          ↳ QDP
                            ↳ QDPOrderProof
                              ↳ QDP
                                ↳ QDPOrderProof
                                  ↳ QDP
                                    ↳ Instantiation
QDP
                                ↳ QDPOrderProof

Q DP problem:
The TRS P consists of the following rules:

IF(false, 0Inact, sInact(diffInact(pInact(y_3), y_4))) → A(sInact(diffInact(pInact(y_3), y_4)))
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


A(pInact(x1)) → A(x1)
The remaining pairs can at least be oriented weakly.

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)
Used ordering: Polynomial interpretation [25]:

POL(0) = 0   
POL(0Inact) = 0   
POL(A(x1)) = x1   
POL(DIFF(x1, x2)) = 0   
POL(IF(x1, x2, x3)) = x3   
POL(a(x1)) = 0   
POL(diff(x1, x2)) = 0   
POL(diffInact(x1, x2)) = 0   
POL(false) = 0   
POL(if(x1, x2, x3)) = 0   
POL(leq(x1, x2)) = 0   
POL(p(x1)) = 0   
POL(pInact(x1)) = 1 + x1   
POL(s(x1)) = 0   
POL(sInact(x1)) = x1   
POL(true) = 0   

The following usable rules [17] were oriented: none



↳ CSR
  ↳ CSRInnermostProof
    ↳ CSR
      ↳ CSDependencyPairsProof
      ↳ Zantema-Transformation
      ↳ Innermost Giesl Middeldorp-Transformation
      ↳ Trivial-Transformation
      ↳ Improved Ferreira Ribeiro-Transformation
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ Instantiation
                      ↳ QDP
                        ↳ DependencyGraphProof
                          ↳ QDP
                            ↳ QDPOrderProof
                              ↳ QDP
                                ↳ QDPOrderProof
                                ↳ QDPOrderProof
QDP

Q DP problem:
The TRS P consists of the following rules:

IF(false, X, Y) → A(Y)
DIFF(X, Y) → IF(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
A(diffInact(x1, x2)) → DIFF(a(x1), a(x2))
A(sInact(x1)) → A(x1)

The TRS R consists of the following rules:

p(0) → 0
p(s(X)) → X
leq(0, Y) → true
leq(s(X), 0) → false
leq(s(X), s(Y)) → leq(X, Y)
if(true, X, Y) → a(X)
if(false, X, Y) → a(Y)
diff(X, Y) → if(leq(X, Y), 0Inact, sInact(diffInact(pInact(X), Y)))
a(x) → x
p(x1) → pInact(x1)
a(pInact(x1)) → p(a(x1))
s(x1) → sInact(x1)
a(sInact(x1)) → s(a(x1))
diff(x1, x2) → diffInact(x1, x2)
a(diffInact(x1, x2)) → diff(a(x1), a(x2))
00Inact
a(0Inact) → 0

Q is empty.
We have to consider all minimal (P,Q,R)-chains.