Term Rewriting System R:
[y, z, x]
app(f, app(app(cons, nil), y)) -> y
app(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> app(app(app(copy, n), y), z)
app(app(app(copy, 0), y), z) -> app(f, z)
app(app(app(copy, app(s, x)), y), z) -> app(app(app(copy, x), y), app(app(cons, app(f, y)), z))

Termination of R to be shown.



   R
Dependency Pair Analysis



R contains the following Dependency Pairs:

APP(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> APP(app(app(copy, n), y), z)
APP(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> APP(app(copy, n), y)
APP(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> APP(copy, n)
APP(app(app(copy, 0), y), z) -> APP(f, z)
APP(app(app(copy, app(s, x)), y), z) -> APP(app(app(copy, x), y), app(app(cons, app(f, y)), z))
APP(app(app(copy, app(s, x)), y), z) -> APP(app(copy, x), y)
APP(app(app(copy, app(s, x)), y), z) -> APP(copy, x)
APP(app(app(copy, app(s, x)), y), z) -> APP(app(cons, app(f, y)), z)
APP(app(app(copy, app(s, x)), y), z) -> APP(cons, app(f, y))
APP(app(app(copy, app(s, x)), y), z) -> APP(f, y)

Furthermore, R contains one SCC.


   R
DPs
       →DP Problem 1
Size-Change Principle


Dependency Pair:

APP(app(app(copy, app(s, x)), y), z) -> APP(app(app(copy, x), y), app(app(cons, app(f, y)), z))


Rules:


app(f, app(app(cons, nil), y)) -> y
app(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> app(app(app(copy, n), y), z)
app(app(app(copy, 0), y), z) -> app(f, z)
app(app(app(copy, app(s, x)), y), z) -> app(app(app(copy, x), y), app(app(cons, app(f, y)), z))





The original DP problem is in applicative form. Its DPs and usable rules are the following.

APP(app(app(copy, app(s, x)), y), z) -> APP(app(app(copy, x), y), app(app(cons, app(f, y)), z))


app(f, app(app(cons, nil), y)) -> y
app(f, app(app(cons, app(f, app(app(cons, nil), y))), z)) -> app(app(app(copy, n), y), z)


It is proper and hence, it can be A-transformed which results in the DP problem

COPY(s(x), y, z) -> COPY(x, y, cons(f(y), z))


f(cons(nil, y)) -> y
f(cons(f(cons(nil, y)), z)) -> copy(n, y, z)


We number the DPs as follows:
  1. COPY(s(x), y, z) -> COPY(x, y, cons(f(y), z))
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:
cons(x1, x2) -> cons(x1, x2)
s(x1) -> s(x1)

We obtain no new DP problems.

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