Term Rewriting System R:
[YS, X, XS, X1, X2, Y, L]
aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))

Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

AAPP(nil, YS) -> MARK(YS)
AAPP(cons(X, XS), YS) -> MARK(X)
AFROM(X) -> MARK(X)
AZWADR(cons(X, XS), cons(Y, YS)) -> AAPP(mark(Y), cons(mark(X), nil))
AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(Y)
AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(X)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))
MARK(app(X1, X2)) -> MARK(X1)
MARK(app(X1, X2)) -> MARK(X2)
MARK(from(X)) -> AFROM(mark(X))
MARK(from(X)) -> MARK(X)
MARK(zWadr(X1, X2)) -> AZWADR(mark(X1), mark(X2))
MARK(zWadr(X1, X2)) -> MARK(X1)
MARK(zWadr(X1, X2)) -> MARK(X2)
MARK(prefix(X)) -> APREFIX(mark(X))
MARK(prefix(X)) -> MARK(X)
MARK(cons(X1, X2)) -> MARK(X1)
MARK(s(X)) -> MARK(X)

Furthermore, R contains one SCC.


   R
DPs
       →DP Problem 1
Negative Polynomial Order


Dependency Pairs:

AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(X)
MARK(s(X)) -> MARK(X)
MARK(cons(X1, X2)) -> MARK(X1)
MARK(prefix(X)) -> MARK(X)
MARK(zWadr(X1, X2)) -> MARK(X2)
MARK(zWadr(X1, X2)) -> MARK(X1)
AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(Y)
AZWADR(cons(X, XS), cons(Y, YS)) -> AAPP(mark(Y), cons(mark(X), nil))
MARK(zWadr(X1, X2)) -> AZWADR(mark(X1), mark(X2))
MARK(from(X)) -> MARK(X)
AFROM(X) -> MARK(X)
MARK(from(X)) -> AFROM(mark(X))
MARK(app(X1, X2)) -> MARK(X2)
MARK(app(X1, X2)) -> MARK(X1)
AAPP(cons(X, XS), YS) -> MARK(X)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))
AAPP(nil, YS) -> MARK(YS)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





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

AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(X)
MARK(cons(X1, X2)) -> MARK(X1)
MARK(prefix(X)) -> MARK(X)
AZWADR(cons(X, XS), cons(Y, YS)) -> MARK(Y)
AZWADR(cons(X, XS), cons(Y, YS)) -> AAPP(mark(Y), cons(mark(X), nil))
MARK(from(X)) -> MARK(X)
MARK(from(X)) -> AFROM(mark(X))
AAPP(cons(X, XS), YS) -> MARK(X)


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

mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))
aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)


Used ordering:
Polynomial Order with Interpretation:

POL( AZWADR(x1, x2) ) = x1 + x2

POL( cons(x1, x2) ) = x1 + 1

POL( MARK(x1) ) = x1

POL( AFROM(x1) ) = x1

POL( app(x1, x2) ) = x1 + x2

POL( AAPP(x1, x2) ) = x1 + x2

POL( mark(x1) ) = x1

POL( from(x1) ) = x1 + 1

POL( prefix(x1) ) = x1 + 1

POL( s(x1) ) = x1

POL( zWadr(x1, x2) ) = x1 + x2

POL( aapp(x1, x2) ) = x1 + x2

POL( afrom(x1) ) = x1 + 1

POL( azWadr(x1, x2) ) = x1 + x2

POL( aprefix(x1) ) = x1 + 1

POL( nil ) = 0


This results in one new DP problem.


   R
DPs
       →DP Problem 1
Neg POLO
           →DP Problem 2
Dependency Graph


Dependency Pairs:

MARK(s(X)) -> MARK(X)
MARK(zWadr(X1, X2)) -> MARK(X2)
MARK(zWadr(X1, X2)) -> MARK(X1)
MARK(zWadr(X1, X2)) -> AZWADR(mark(X1), mark(X2))
AFROM(X) -> MARK(X)
MARK(app(X1, X2)) -> MARK(X2)
MARK(app(X1, X2)) -> MARK(X1)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))
AAPP(nil, YS) -> MARK(YS)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





Using the Dependency Graph the DP problem was split into 1 DP problems.


   R
DPs
       →DP Problem 1
Neg POLO
           →DP Problem 2
DGraph
             ...
               →DP Problem 3
Negative Polynomial Order


Dependency Pairs:

MARK(zWadr(X1, X2)) -> MARK(X2)
MARK(zWadr(X1, X2)) -> MARK(X1)
MARK(app(X1, X2)) -> MARK(X2)
MARK(app(X1, X2)) -> MARK(X1)
AAPP(nil, YS) -> MARK(YS)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))
MARK(s(X)) -> MARK(X)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





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

MARK(zWadr(X1, X2)) -> MARK(X2)
MARK(zWadr(X1, X2)) -> MARK(X1)


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

mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))
aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)


Used ordering:
Polynomial Order with Interpretation:

POL( MARK(x1) ) = x1

POL( zWadr(x1, x2) ) = x1 + x2 + 1

POL( s(x1) ) = x1

POL( app(x1, x2) ) = x1 + x2

POL( AAPP(x1, x2) ) = x2

POL( mark(x1) ) = x1

POL( aapp(x1, x2) ) = x1 + x2

POL( from(x1) ) = 0

POL( afrom(x1) ) = 0

POL( azWadr(x1, x2) ) = x1 + x2 + 1

POL( prefix(x1) ) = 0

POL( aprefix(x1) ) = 0

POL( nil ) = 0

POL( cons(x1, x2) ) = 0


This results in one new DP problem.


   R
DPs
       →DP Problem 1
Neg POLO
           →DP Problem 2
DGraph
             ...
               →DP Problem 4
Negative Polynomial Order


Dependency Pairs:

MARK(app(X1, X2)) -> MARK(X2)
MARK(app(X1, X2)) -> MARK(X1)
AAPP(nil, YS) -> MARK(YS)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))
MARK(s(X)) -> MARK(X)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





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

MARK(app(X1, X2)) -> MARK(X2)
MARK(app(X1, X2)) -> MARK(X1)
MARK(app(X1, X2)) -> AAPP(mark(X1), mark(X2))


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

mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))
aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)


Used ordering:
Polynomial Order with Interpretation:

POL( MARK(x1) ) = x1

POL( app(x1, x2) ) = x1 + x2 + 1

POL( AAPP(x1, x2) ) = x2

POL( mark(x1) ) = x1

POL( s(x1) ) = x1

POL( aapp(x1, x2) ) = x1 + x2 + 1

POL( from(x1) ) = 0

POL( afrom(x1) ) = 0

POL( zWadr(x1, x2) ) = 0

POL( azWadr(x1, x2) ) = 0

POL( prefix(x1) ) = 0

POL( aprefix(x1) ) = 0

POL( nil ) = 0

POL( cons(x1, x2) ) = 0


This results in one new DP problem.


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


Dependency Pairs:

AAPP(nil, YS) -> MARK(YS)
MARK(s(X)) -> MARK(X)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





Using the Dependency Graph the DP problem was split into 1 DP problems.


   R
DPs
       →DP Problem 1
Neg POLO
           →DP Problem 2
DGraph
             ...
               →DP Problem 6
Size-Change Principle


Dependency Pair:

MARK(s(X)) -> MARK(X)


Rules:


aapp(nil, YS) -> mark(YS)
aapp(cons(X, XS), YS) -> cons(mark(X), app(XS, YS))
aapp(X1, X2) -> app(X1, X2)
afrom(X) -> cons(mark(X), from(s(X)))
afrom(X) -> from(X)
azWadr(nil, YS) -> nil
azWadr(XS, nil) -> nil
azWadr(cons(X, XS), cons(Y, YS)) -> cons(aapp(mark(Y), cons(mark(X), nil)), zWadr(XS, YS))
azWadr(X1, X2) -> zWadr(X1, X2)
aprefix(L) -> cons(nil, zWadr(L, prefix(L)))
aprefix(X) -> prefix(X)
mark(app(X1, X2)) -> aapp(mark(X1), mark(X2))
mark(from(X)) -> afrom(mark(X))
mark(zWadr(X1, X2)) -> azWadr(mark(X1), mark(X2))
mark(prefix(X)) -> aprefix(mark(X))
mark(nil) -> nil
mark(cons(X1, X2)) -> cons(mark(X1), X2)
mark(s(X)) -> s(mark(X))





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

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

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.

Termination of R successfully shown.
Duration:
0:04 minutes