Term Rewriting System R:
[X, Y]
minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))
p(s(X)) -> X
div(0, s(Y)) -> 0
div(s(X), s(Y)) -> s(div(minus(X, Y), s(Y)))

Innermost Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

MINUS(s(X), s(Y)) -> P(minus(X, Y))
MINUS(s(X), s(Y)) -> MINUS(X, Y)
DIV(s(X), s(Y)) -> DIV(minus(X, Y), s(Y))
DIV(s(X), s(Y)) -> MINUS(X, Y)

Furthermore, R contains two SCCs.


   R
DPs
       →DP Problem 1
Usable Rules (Innermost)
       →DP Problem 2
UsableRules


Dependency Pair:

MINUS(s(X), s(Y)) -> MINUS(X, Y)


Rules:


minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))
p(s(X)) -> X
div(0, s(Y)) -> 0
div(s(X), s(Y)) -> s(div(minus(X, Y), s(Y)))


Strategy:

innermost




As we are in the innermost case, we can delete all 5 non-usable-rules.


   R
DPs
       →DP Problem 1
UsableRules
           →DP Problem 3
Size-Change Principle
       →DP Problem 2
UsableRules


Dependency Pair:

MINUS(s(X), s(Y)) -> MINUS(X, Y)


Rule:

none


Strategy:

innermost




We number the DPs as follows:
  1. MINUS(s(X), s(Y)) -> MINUS(X, Y)
and get the following Size-Change Graph(s):
{1} , {1}
1>1
2>2

which lead(s) to this/these maximal multigraph(s):
{1} , {1}
1>1
2>2

DP: empty set
Oriented Rules: none

We used the order Homeomorphic Embedding Order with Non-Strict Precedence.
trivial

with Argument Filtering System:
s(x1) -> s(x1)

We obtain no new DP problems.


   R
DPs
       →DP Problem 1
UsableRules
       →DP Problem 2
Usable Rules (Innermost)


Dependency Pair:

DIV(s(X), s(Y)) -> DIV(minus(X, Y), s(Y))


Rules:


minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))
p(s(X)) -> X
div(0, s(Y)) -> 0
div(s(X), s(Y)) -> s(div(minus(X, Y), s(Y)))


Strategy:

innermost




As we are in the innermost case, we can delete all 2 non-usable-rules.


   R
DPs
       →DP Problem 1
UsableRules
       →DP Problem 2
UsableRules
           →DP Problem 4
Negative Polynomial Order


Dependency Pair:

DIV(s(X), s(Y)) -> DIV(minus(X, Y), s(Y))


Rules:


p(s(X)) -> X
minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))


Strategy:

innermost




The following Dependency Pair can be strictly oriented using the given order.

DIV(s(X), s(Y)) -> DIV(minus(X, Y), s(Y))


Moreover, the following usable rules (regarding the implicit AFS) are oriented.

p(s(X)) -> X
minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))


Used ordering:
Polynomial Order with Interpretation:

POL( DIV(x1, x2) ) = x1

POL( s(x1) ) = x1 + 1

POL( minus(x1, x2) ) = x1

POL( p(x1) ) = x1


This results in one new DP problem.


   R
DPs
       →DP Problem 1
UsableRules
       →DP Problem 2
UsableRules
           →DP Problem 4
Neg POLO
             ...
               →DP Problem 5
Dependency Graph


Dependency Pair:


Rules:


p(s(X)) -> X
minus(X, 0) -> X
minus(s(X), s(Y)) -> p(minus(X, Y))


Strategy:

innermost




Using the Dependency Graph resulted in no new DP problems.

Innermost Termination of R successfully shown.
Duration:
0:00 minutes