YES
The TRS could be proven terminating. The proof took 895 ms.
The following DP Processors were used
Problem 1 was processed with processor DependencyGraph (26ms).
| Problem 2 was processed with processor PolynomialLinearRange4iUR (710ms).
| Problem 3 was processed with processor SubtermCriterion (1ms).
| Problem 4 was processed with processor SubtermCriterion (1ms).
| Problem 5 was processed with processor PolynomialLinearRange4iUR (58ms).
Problem 1: DependencyGraph
Dependency Pair Problem
Dependency Pairs
sum#(app(l, cons(x, cons(y, k)))) | → | app#(l, sum(cons(x, cons(y, k)))) | | sum#(cons(x, cons(y, l))) | → | sum#(cons(plus(x, y), l)) |
sum#(cons(x, cons(y, l))) | → | plus#(x, y) | | 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))) | | plus#(s(x), y) | → | plus#(x, y) |
app#(cons(x, l), k) | → | app#(l, k) |
Rewrite Rules
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))))) |
plus(0, y) | → | y | | plus(s(x), y) | → | s(plus(x, y)) |
Original Signature
Termination of terms over the following signature is verified: app, plus, 0, s, sum, nil, cons
Strategy
The following SCCs where found
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))))) |
plus#(s(x), y) → plus#(x, y) |
app#(cons(x, l), k) → app#(l, k) |
Problem 2: PolynomialLinearRange4iUR
Dependency Pair Problem
Dependency Pairs
sum#(app(l, cons(x, cons(y, k)))) | → | sum#(app(l, sum(cons(x, cons(y, k))))) |
Rewrite Rules
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))))) |
plus(0, y) | → | y | | plus(s(x), y) | → | s(plus(x, y)) |
Original Signature
Termination of terms over the following signature is verified: app, plus, 0, s, sum, nil, cons
Strategy
Polynomial Interpretation
- 0: 3
- app(x,y): y + x + 1
- cons(x,y): y + 1
- nil: 0
- plus(x,y): 3y
- s(x): 2
- sum(x): 1
- sum#(x): x
Improved Usable rules
app(l, nil) | → | l | | app(cons(x, l), k) | → | cons(x, app(l, k)) |
app(nil, k) | → | k | | sum(cons(x, cons(y, l))) | → | sum(cons(plus(x, y), l)) |
sum(cons(x, nil)) | → | cons(x, nil) | | sum(app(l, cons(x, cons(y, k)))) | → | sum(app(l, sum(cons(x, cons(y, k))))) |
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
sum#(app(l, cons(x, cons(y, k)))) | → | sum#(app(l, sum(cons(x, cons(y, k))))) |
Problem 3: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
plus#(s(x), y) | → | plus#(x, y) |
Rewrite Rules
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))))) |
plus(0, y) | → | y | | plus(s(x), y) | → | s(plus(x, y)) |
Original Signature
Termination of terms over the following signature is verified: app, plus, 0, s, sum, nil, cons
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
plus#(s(x), y) | → | plus#(x, y) |
Problem 4: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
app#(cons(x, l), k) | → | app#(l, k) |
Rewrite Rules
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))))) |
plus(0, y) | → | y | | plus(s(x), y) | → | s(plus(x, y)) |
Original Signature
Termination of terms over the following signature is verified: app, plus, 0, s, sum, nil, cons
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
app#(cons(x, l), k) | → | app#(l, k) |
Problem 5: PolynomialLinearRange4iUR
Dependency Pair Problem
Dependency Pairs
sum#(cons(x, cons(y, l))) | → | sum#(cons(plus(x, y), l)) |
Rewrite Rules
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))))) |
plus(0, y) | → | y | | plus(s(x), y) | → | s(plus(x, y)) |
Original Signature
Termination of terms over the following signature is verified: app, plus, 0, s, sum, nil, cons
Strategy
Polynomial Interpretation
- 0: 0
- app(x,y): 0
- cons(x,y): y + 2x + 1
- nil: 0
- plus(x,y): y
- s(x): 0
- sum(x): 0
- sum#(x): x + 1
Improved Usable rules
plus(s(x), y) | → | s(plus(x, y)) | | plus(0, y) | → | y |
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
sum#(cons(x, cons(y, l))) | → | sum#(cons(plus(x, y), l)) |