Term Rewriting System R:
[k, l, x, y]
app(nil, k) -> k
app(l, nil) -> l
app(cons(x, l), k) -> cons(x, app(l, k))
sum(cons(x, nil)) -> cons(x, nil)
sum(cons(x, cons(y, l))) -> sum(cons(plus(x, y), l))
sum(app(l, cons(x, cons(y, k)))) -> sum(app(l, sum(cons(x, cons(y, k)))))
sum(plus(cons(0, x), cons(y, l))) -> pred(sum(cons(s(x), cons(y, l))))
plus(0, y) -> y
plus(s(x), y) -> s(plus(x, y))
pred(cons(s(x), nil)) -> cons(x, nil)

Termination of R to be shown.



   R
Removing Redundant Rules



Removing the following rules from R which fullfill a polynomial ordering:

app(nil, k) -> k
app(l, nil) -> l

where the Polynomial interpretation:
  POL(plus(x1, x2))=  x1 + x2  
  POL(0)=  0  
  POL(cons(x1, x2))=  x1 + x2  
  POL(pred(x1))=  x1  
  POL(nil)=  1  
  POL(sum(x1))=  x1  
  POL(s(x1))=  x1  
  POL(app(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
Removing Redundant Rules



Removing the following rules from R which fullfill a polynomial ordering:

sum(plus(cons(0, x), cons(y, l))) -> pred(sum(cons(s(x), cons(y, l))))
plus(0, y) -> y

where the Polynomial interpretation:
  POL(plus(x1, x2))=  1 + x1 + x2  
  POL(0)=  0  
  POL(cons(x1, x2))=  1 + x1 + x2  
  POL(pred(x1))=  x1  
  POL(nil)=  0  
  POL(sum(x1))=  x1  
  POL(s(x1))=  x1  
  POL(app(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
Removing Redundant Rules



Removing the following rules from R which fullfill a polynomial ordering:

sum(cons(x, cons(y, l))) -> sum(cons(plus(x, y), l))

where the Polynomial interpretation:
  POL(plus(x1, x2))=  x1 + x2  
  POL(cons(x1, x2))=  1 + x1 + x2  
  POL(pred(x1))=  x1  
  POL(nil)=  0  
  POL(sum(x1))=  x1  
  POL(s(x1))=  x1  
  POL(app(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
             ...
               →TRS4
Removing Redundant Rules



Removing the following rules from R which fullfill a polynomial ordering:

plus(s(x), y) -> s(plus(x, y))
pred(cons(s(x), nil)) -> cons(x, nil)

where the Polynomial interpretation:
  POL(plus(x1, x2))=  2·x1 + x2  
  POL(cons(x1, x2))=  x1 + x2  
  POL(pred(x1))=  x1  
  POL(nil)=  0  
  POL(sum(x1))=  x1  
  POL(s(x1))=  1 + x1  
  POL(app(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:

app(cons(x, l), k) -> cons(x, app(l, k))

where the Polynomial interpretation:
  POL(cons(x1, x2))=  1 + x1 + x2  
  POL(nil)=  0  
  POL(sum(x1))=  x1  
  POL(app(x1, x2))=  2·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
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
             ...
               →TRS7
Dependency Pair Analysis



R contains the following Dependency Pairs:

SUM(app(l, cons(x, cons(y, k)))) -> SUM(app(l, sum(cons(x, cons(y, k)))))
SUM(app(l, cons(x, cons(y, k)))) -> SUM(cons(x, cons(y, k)))

R contains no SCCs.

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