Term Rewriting System R:
[x, y, z]
flatten(nil) -> nil
flatten(unit(x)) -> flatten(x)
flatten(++(x, y)) -> ++(flatten(x), flatten(y))
flatten(++(unit(x), y)) -> ++(flatten(x), flatten(y))
flatten(flatten(x)) -> flatten(x)
rev(nil) -> nil
rev(unit(x)) -> unit(x)
rev(++(x, y)) -> ++(rev(y), rev(x))
rev(rev(x)) -> x
++(x, nil) -> x
++(nil, y) -> y
++(++(x, y), z) -> ++(x, ++(y, z))
Termination of R to be shown.
R
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
flatten(nil) -> nil
++(x, nil) -> x
++(nil, y) -> y
where the Polynomial interpretation:
POL(unit(x1)) | = x1 |
POL(rev(x1)) | = x1 |
POL(flatten(x1)) | = 2·x1 |
POL(++(x1, x2)) | = x1 + x2 |
POL(nil) | = 1 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
rev(nil) -> nil
where the Polynomial interpretation:
POL(rev(x1)) | = 2·x1 |
POL(unit(x1)) | = x1 |
POL(flatten(x1)) | = x1 |
POL(++(x1, x2)) | = x1 + x2 |
POL(nil) | = 1 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
rev(++(x, y)) -> ++(rev(y), rev(x))
where the Polynomial interpretation:
POL(rev(x1)) | = 2·x1 |
POL(unit(x1)) | = x1 |
POL(flatten(x1)) | = x1 |
POL(++(x1, x2)) | = 1 + x1 + x2 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS4
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
flatten(unit(x)) -> flatten(x)
flatten(++(unit(x), y)) -> ++(flatten(x), flatten(y))
where the Polynomial interpretation:
POL(unit(x1)) | = 1 + x1 |
POL(rev(x1)) | = x1 |
POL(flatten(x1)) | = x1 |
POL(++(x1, x2)) | = x1 + x2 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS5
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
flatten(flatten(x)) -> flatten(x)
where the Polynomial interpretation:
POL(rev(x1)) | = x1 |
POL(unit(x1)) | = x1 |
POL(flatten(x1)) | = 1 + 2·x1 |
POL(++(x1, x2)) | = 1 + x1 + x2 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS6
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
rev(rev(x)) -> x
rev(unit(x)) -> unit(x)
where the Polynomial interpretation:
POL(rev(x1)) | = 1 + x1 |
POL(unit(x1)) | = x1 |
POL(flatten(x1)) | = x1 |
POL(++(x1, x2)) | = x1 + x2 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS7
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
flatten(++(x, y)) -> ++(flatten(x), flatten(y))
where the Polynomial interpretation:
POL(flatten(x1)) | = 2·x1 |
POL(++(x1, x2)) | = 1 + x1 + x2 |
was used.
Not all Rules of R can be deleted, so we still have to regard a part of R.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS8
↳Removing Redundant Rules
Removing the following rules from R which fullfill a polynomial ordering:
++(++(x, y), z) -> ++(x, ++(y, z))
where the Polynomial interpretation:
POL(++(x1, x2)) | = 1 + 2·x1 + x2 |
was used.
All Rules of R can be deleted.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS9
↳Overlay and local confluence Check
The TRS is overlay and locally confluent (all critical pairs are trivially joinable).Hence, we can switch to innermost.
R
↳RRRPolo
→TRS2
↳RRRPolo
→TRS3
↳RRRPolo
...
→TRS10
↳Dependency Pair Analysis
R contains no Dependency Pairs and therefore no SCCs.
Termination of R successfully shown.
Duration:
0:00 minutes