YES
The TRS could be proven terminating. The proof took 1322 ms.
The following DP Processors were used
Problem 1 was processed with processor DependencyGraph (340ms).
| Problem 2 was processed with processor SubtermCriterion (34ms).
| Problem 3 was processed with processor SubtermCriterion (0ms).
| | Problem 7 was processed with processor PolynomialLinearRange4iUR (129ms).
| | | Problem 10 was processed with processor DependencyGraph (0ms).
| Problem 4 was processed with processor SubtermCriterion (1ms).
| | Problem 8 was processed with processor DependencyGraph (1ms).
| Problem 5 was processed with processor PolynomialLinearRange4iUR (165ms).
| | Problem 9 was processed with processor PolynomialOrderingProcessor (113ms).
| | | Problem 11 was processed with processor PolynomialOrderingProcessor (57ms).
| Problem 6 was processed with processor SubtermCriterion (1ms).
Problem 1: DependencyGraph
Dependency Pair Problem
Dependency Pairs
divides#(y, x) | → | div#(x, y) | | pr#(x, s(s(y))) | → | divides#(s(s(y)), x) |
times#(s(x), y) | → | times#(x, y) | | div#(div(x, y), z) | → | times#(y, z) |
pr#(x, s(s(y))) | → | if#(divides(s(s(y)), x), x, s(y)) | | divides#(y, x) | → | eq#(x, times(div(x, y), y)) |
quot#(s(x), s(y), z) | → | quot#(x, y, z) | | times#(s(x), y) | → | plus#(y, times(x, y)) |
if#(false, x, y) | → | pr#(x, y) | | divides#(y, x) | → | times#(div(x, y), y) |
plus#(s(x), y) | → | plus#(x, y) | | plus#(s(x), y) | → | plus#(p(s(x)), y) |
quot#(x, 0, s(z)) | → | div#(x, s(z)) | | div#(x, y) | → | quot#(x, y, y) |
eq#(s(x), s(y)) | → | eq#(x, y) | | div#(div(x, y), z) | → | div#(x, times(y, z)) |
prime#(s(s(x))) | → | pr#(s(s(x)), s(x)) | | plus#(s(x), y) | → | p#(s(x)) |
plus#(x, s(y)) | → | p#(s(y)) | | plus#(x, s(y)) | → | plus#(x, p(s(y))) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
The following SCCs where found
if#(false, x, y) → pr#(x, y) | pr#(x, s(s(y))) → if#(divides(s(s(y)), x), x, s(y)) |
plus#(s(x), y) → plus#(p(s(x)), y) | plus#(s(x), y) → plus#(x, y) |
plus#(x, s(y)) → plus#(x, p(s(y))) |
times#(s(x), y) → times#(x, y) |
eq#(s(x), s(y)) → eq#(x, y) |
quot#(x, 0, s(z)) → div#(x, s(z)) | div#(x, y) → quot#(x, y, y) |
div#(div(x, y), z) → div#(x, times(y, z)) | quot#(s(x), s(y), z) → quot#(x, y, z) |
Problem 2: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
times#(s(x), y) | → | times#(x, y) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
times#(s(x), y) | → | times#(x, y) |
Problem 3: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
quot#(x, 0, s(z)) | → | div#(x, s(z)) | | div#(x, y) | → | quot#(x, y, y) |
div#(div(x, y), z) | → | div#(x, times(y, z)) | | quot#(s(x), s(y), z) | → | quot#(x, y, z) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
div#(div(x, y), z) | → | div#(x, times(y, z)) | | quot#(s(x), s(y), z) | → | quot#(x, y, z) |
Problem 7: PolynomialLinearRange4iUR
Dependency Pair Problem
Dependency Pairs
quot#(x, 0, s(z)) | → | div#(x, s(z)) | | div#(x, y) | → | quot#(x, y, y) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Polynomial Interpretation
- 0: 2
- div(x,y): 0
- div#(x,y): 2y
- divides(x,y): 0
- eq(x,y): 0
- false: 0
- if(x,y,z): 0
- p(x): 0
- plus(x,y): 0
- pr(x,y): 0
- prime(x): 0
- quot(x,y,z): 0
- quot#(x,y,z): y
- s(x): 0
- times(x,y): 0
- true: 0
There are no usable rules
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
quot#(x, 0, s(z)) | → | div#(x, s(z)) |
Problem 10: DependencyGraph
Dependency Pair Problem
Dependency Pairs
div#(x, y) | → | quot#(x, y, y) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
There are no SCCs!
Problem 4: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
if#(false, x, y) | → | pr#(x, y) | | pr#(x, s(s(y))) | → | if#(divides(s(s(y)), x), x, s(y)) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
pr#(x, s(s(y))) | → | if#(divides(s(s(y)), x), x, s(y)) |
Problem 8: DependencyGraph
Dependency Pair Problem
Dependency Pairs
if#(false, x, y) | → | pr#(x, y) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
There are no SCCs!
Problem 5: PolynomialLinearRange4iUR
Dependency Pair Problem
Dependency Pairs
plus#(s(x), y) | → | plus#(p(s(x)), y) | | plus#(s(x), y) | → | plus#(x, y) |
plus#(x, s(y)) | → | plus#(x, p(s(y))) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Polynomial Interpretation
- 0: 0
- div(x,y): 0
- divides(x,y): 0
- eq(x,y): 0
- false: 0
- if(x,y,z): 0
- p(x): x
- plus(x,y): 0
- plus#(x,y): x
- pr(x,y): 0
- prime(x): 0
- quot(x,y,z): 0
- s(x): x + 1
- times(x,y): 0
- true: 0
Improved Usable rules
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
plus#(s(x), y) | → | plus#(x, y) |
Problem 9: PolynomialOrderingProcessor
Dependency Pair Problem
Dependency Pairs
plus#(s(x), y) | → | plus#(p(s(x)), y) | | plus#(x, s(y)) | → | plus#(x, p(s(y))) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Polynomial Interpretation
- 0: 0
- div(x,y): -2
- divides(x,y): -2
- eq(x,y): -2
- false: -2
- if(x,y,z): -2
- p(x): x - 1
- plus(x,y): -2
- plus#(x,y): y + 2x - 1
- pr(x,y): -2
- prime(x): -2
- quot(x,y,z): -2
- s(x): x + 1
- times(x,y): -2
- true: -2
Improved Usable rules
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
plus#(s(x), y) | → | plus#(p(s(x)), y) |
Problem 11: PolynomialOrderingProcessor
Dependency Pair Problem
Dependency Pairs
plus#(x, s(y)) | → | plus#(x, p(s(y))) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Polynomial Interpretation
- 0: -1
- div(x,y): -2
- divides(x,y): -2
- eq(x,y): -2
- false: -2
- if(x,y,z): -2
- p(x): x - 1
- plus(x,y): -2
- plus#(x,y): 2y + x + 1
- pr(x,y): -2
- prime(x): -2
- quot(x,y,z): -2
- s(x): 4x + 2
- times(x,y): -2
- true: -2
Improved Usable rules
The following dependency pairs are strictly oriented by an ordering on the given polynomial interpretation, thus they are removed:
plus#(x, s(y)) | → | plus#(x, p(s(y))) |
Problem 6: SubtermCriterion
Dependency Pair Problem
Dependency Pairs
eq#(s(x), s(y)) | → | eq#(x, y) |
Rewrite Rules
p(0) | → | 0 | | p(s(x)) | → | x |
plus(x, 0) | → | x | | plus(0, y) | → | y |
plus(s(x), y) | → | s(plus(x, y)) | | plus(s(x), y) | → | s(plus(p(s(x)), y)) |
plus(x, s(y)) | → | s(plus(x, p(s(y)))) | | times(0, y) | → | 0 |
times(s(0), y) | → | y | | times(s(x), y) | → | plus(y, times(x, y)) |
div(0, y) | → | 0 | | div(x, y) | → | quot(x, y, y) |
quot(0, s(y), z) | → | 0 | | quot(s(x), s(y), z) | → | quot(x, y, z) |
quot(x, 0, s(z)) | → | s(div(x, s(z))) | | div(div(x, y), z) | → | div(x, times(y, z)) |
eq(0, 0) | → | true | | eq(s(x), 0) | → | false |
eq(0, s(y)) | → | false | | eq(s(x), s(y)) | → | eq(x, y) |
divides(y, x) | → | eq(x, times(div(x, y), y)) | | prime(s(s(x))) | → | pr(s(s(x)), s(x)) |
pr(x, s(0)) | → | true | | pr(x, s(s(y))) | → | if(divides(s(s(y)), x), x, s(y)) |
if(true, x, y) | → | false | | if(false, x, y) | → | pr(x, y) |
Original Signature
Termination of terms over the following signature is verified: plus, div, true, divides, prime, 0, s, times, if, p, false, quot, pr, eq
Strategy
Projection
The following projection was used:
Thus, the following dependency pairs are removed:
eq#(s(x), s(y)) | → | eq#(x, y) |