The rewrite relation of the following TRS is considered.
The dependency pairs are split into 3
components.
-
The
1st
component contains the
pair
|
if_gcd#(false,s(x),s(y)) |
→ |
gcd#(minus(y,x),s(x)) |
(22) |
|
gcd#(s(x),s(y)) |
→ |
if_gcd#(le(y,x),s(x),s(y)) |
(18) |
|
if_gcd#(true,s(x),s(y)) |
→ |
gcd#(minus(x,y),s(y)) |
(20) |
1.1.1 Reduction Pair Processor with Usable Rules
Using the linear polynomial interpretation over the naturals
| [false] |
= |
2 |
| [le(x1, x2)] |
= |
0 · x1 + 0 · x2 + 3 |
| [s(x1)] |
= |
4 · x1 + 4 |
| [minus(x1, x2)] |
= |
2 · x1 + 0 · x2 + 0 |
| [0] |
= |
0 |
| [gcd#(x1, x2)] |
= |
2 · x1 + 1 · x2 + 6 |
| [if_gcd#(x1, x2, x3)] |
= |
2 · x1 + 2 · x2 + 1 · x3 + 0 |
| [if_minus(x1, x2, x3)] |
= |
0 · x1 + 2 · x2 + 0 · x3 + 0 |
| [true] |
= |
2 |
together with the usable
rules
|
minus(0,y) |
→ |
0 |
(4) |
|
minus(s(x),y) |
→ |
if_minus(le(s(x),y),s(x),y) |
(5) |
|
if_minus(true,s(x),y) |
→ |
0 |
(6) |
|
if_minus(false,s(x),y) |
→ |
s(minus(x,y)) |
(7) |
|
le(s(x),0) |
→ |
false |
(2) |
|
le(s(x),s(y)) |
→ |
le(x,y) |
(3) |
|
le(0,y) |
→ |
true |
(1) |
(w.r.t. the implicit argument filter of the reduction pair),
the
pairs
|
if_gcd#(false,s(x),s(y)) |
→ |
gcd#(minus(y,x),s(x)) |
(22) |
|
if_gcd#(true,s(x),s(y)) |
→ |
gcd#(minus(x,y),s(y)) |
(20) |
could be deleted.
1.1.1.1 Dependency Graph Processor
The dependency pairs are split into 0
components.
-
The
2nd
component contains the
pair
|
minus#(s(x),y) |
→ |
if_minus#(le(s(x),y),s(x),y) |
(15) |
|
if_minus#(false,s(x),y) |
→ |
minus#(x,y) |
(16) |
1.1.2 Size-Change Termination
Using size-change termination in combination with
the subterm criterion
one obtains the following initial size-change graphs.
|
minus#(s(x),y) |
→ |
if_minus#(le(s(x),y),s(x),y) |
(15) |
|
|
| 2 |
≥ |
3 |
| 1 |
≥ |
2 |
|
if_minus#(false,s(x),y) |
→ |
minus#(x,y) |
(16) |
|
|
| 3 |
≥ |
2 |
| 2 |
> |
1 |
As there is no critical graph in the transitive closure, there are no infinite chains.
-
The
3rd
component contains the
pair
|
le#(s(x),s(y)) |
→ |
le#(x,y) |
(13) |
1.1.3 Size-Change Termination
Using size-change termination in combination with
the subterm criterion
one obtains the following initial size-change graphs.
|
le#(s(x),s(y)) |
→ |
le#(x,y) |
(13) |
|
|
| 2 |
> |
2 |
| 1 |
> |
1 |
As there is no critical graph in the transitive closure, there are no infinite chains.