Term Rewriting System R:
[Y, X]
minus(n0, Y) -> 0
minus(ns(X), ns(Y)) -> minus(activate(X), activate(Y))
geq(X, n0) -> true
geq(n0, ns(Y)) -> false
geq(ns(X), ns(Y)) -> geq(activate(X), activate(Y))
div(0, ns(Y)) -> 0
div(s(X), ns(Y)) -> if(geq(X, activate(Y)), ns(div(minus(X, activate(Y)), ns(activate(Y)))), n0)
if(true, X, Y) -> activate(X)
if(false, X, Y) -> activate(Y)
0 -> n0
s(X) -> ns(X)
activate(n0) -> 0
activate(ns(X)) -> s(X)
activate(X) -> X

Innermost Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

MINUS(n0, Y) -> 0'
MINUS(ns(X), ns(Y)) -> MINUS(activate(X), activate(Y))
MINUS(ns(X), ns(Y)) -> ACTIVATE(X)
MINUS(ns(X), ns(Y)) -> ACTIVATE(Y)
GEQ(ns(X), ns(Y)) -> GEQ(activate(X), activate(Y))
GEQ(ns(X), ns(Y)) -> ACTIVATE(X)
GEQ(ns(X), ns(Y)) -> ACTIVATE(Y)
DIV(s(X), ns(Y)) -> IF(geq(X, activate(Y)), ns(div(minus(X, activate(Y)), ns(activate(Y)))), n0)
DIV(s(X), ns(Y)) -> GEQ(X, activate(Y))
DIV(s(X), ns(Y)) -> ACTIVATE(Y)
DIV(s(X), ns(Y)) -> DIV(minus(X, activate(Y)), ns(activate(Y)))
DIV(s(X), ns(Y)) -> MINUS(X, activate(Y))
IF(true, X, Y) -> ACTIVATE(X)
IF(false, X, Y) -> ACTIVATE(Y)
ACTIVATE(n0) -> 0'
ACTIVATE(ns(X)) -> S(X)

Furthermore, R contains two SCCs.


   R
DPs
       →DP Problem 1
Narrowing Transformation
       →DP Problem 2
Remaining


Dependency Pair:

MINUS(ns(X), ns(Y)) -> MINUS(activate(X), activate(Y))


Rules:


minus(n0, Y) -> 0
minus(ns(X), ns(Y)) -> minus(activate(X), activate(Y))
geq(X, n0) -> true
geq(n0, ns(Y)) -> false
geq(ns(X), ns(Y)) -> geq(activate(X), activate(Y))
div(0, ns(Y)) -> 0
div(s(X), ns(Y)) -> if(geq(X, activate(Y)), ns(div(minus(X, activate(Y)), ns(activate(Y)))), n0)
if(true, X, Y) -> activate(X)
if(false, X, Y) -> activate(Y)
0 -> n0
s(X) -> ns(X)
activate(n0) -> 0
activate(ns(X)) -> s(X)
activate(X) -> X


Strategy:

innermost




On this DP problem, a Narrowing SCC transformation can be performed.
As a result of transforming the rule

MINUS(ns(X), ns(Y)) -> MINUS(activate(X), activate(Y))
six new Dependency Pairs are created:

MINUS(ns(n0), ns(Y)) -> MINUS(0, activate(Y))
MINUS(ns(ns(X'')), ns(Y)) -> MINUS(s(X''), activate(Y))
MINUS(ns(X''), ns(Y)) -> MINUS(X'', activate(Y))
MINUS(ns(X), ns(n0)) -> MINUS(activate(X), 0)
MINUS(ns(X), ns(ns(X''))) -> MINUS(activate(X), s(X''))
MINUS(ns(X), ns(Y')) -> MINUS(activate(X), Y')

The transformation is resulting in one new DP problem:



   R
DPs
       →DP Problem 1
Nar
       →DP Problem 2
Remaining Obligation(s)




The following remains to be proven:


   R
DPs
       →DP Problem 1
Nar
       →DP Problem 2
Remaining Obligation(s)




The following remains to be proven:

Innermost Termination of R could not be shown.
Duration:
0:02 minutes