The rewrite relation of the following TRS is considered.
from(X) | → | cons(X,n__from(s(X))) | (1) |
sel(0,cons(X,Y)) | → | X | (2) |
sel(s(X),cons(Y,Z)) | → | sel(X,activate(Z)) | (3) |
from(X) | → | n__from(X) | (4) |
activate(n__from(X)) | → | from(X) | (5) |
activate(X) | → | X | (6) |
|
originates from |
|
||||||||
|
originates from |
|
||||||||
|
originates from |
|
||||||||
|
originates from |
|
||||||||
|
originates from |
|
||||||||
|
originates from |
|
from#(z0) |
from#(z0) |
sel#(0,cons(z0,z1)) |
sel#(s(z0),cons(z1,z2)) |
activate#(n__from(z0)) |
activate#(z0) |
sel(0,cons(z0,z1)) | → | z0 | (11) |
sel(s(z0),cons(z1,z2)) | → | sel(z0,activate(z2)) | (13) |
sel#(0,cons(z0,z1)) | → | c2 | (12) |
sel#(s(z0),cons(z1,z2)) | → | c3(sel#(z0,activate(z2)),activate#(z2)) | (14) |
[c] | = | 0 |
[c1] | = | 0 |
[c2] | = | 0 |
[c3(x1, x2)] | = | 1 · x1 + 0 + 1 · x2 |
[c4(x1)] | = | 1 · x1 + 0 |
[c5] | = | 0 |
[activate(x1)] | = | 0 |
[from(x1)] | = | 1 + 1 · x1 + 1 · x1 · x1 + 1 · x1 · x1 · x1 |
[from#(x1)] | = | 0 |
[sel#(x1, x2)] | = | 1 · x1 · x1 · x1 + 0 |
[activate#(x1)] | = | 0 |
[n__from(x1)] | = | 1 · x1 + 0 |
[cons(x1, x2)] | = | 1 · x1 + 0 |
[s(x1)] | = | 1 + 1 · x1 |
[0] | = | 1 |
from#(z0) | → | c | (8) |
from#(z0) | → | c1 | (10) |
sel#(0,cons(z0,z1)) | → | c2 | (12) |
sel#(s(z0),cons(z1,z2)) | → | c3(sel#(z0,activate(z2)),activate#(z2)) | (14) |
activate#(n__from(z0)) | → | c4(from#(z0)) | (16) |
activate#(z0) | → | c5 | (18) |
from#(z0) | → | c | (8) |
from#(z0) | → | c1 | (10) |
activate#(z0) | → | c5 | (18) |
[c] | = | 0 |
[c1] | = | 0 |
[c2] | = | 0 |
[c3(x1, x2)] | = | 1 · x1 + 0 + 1 · x2 |
[c4(x1)] | = | 1 · x1 + 0 |
[c5] | = | 0 |
[activate(x1)] | = | 1 · x1 + 0 |
[from(x1)] | = | 1 |
[from#(x1)] | = | 1 |
[sel#(x1, x2)] | = | 1 · x1 + 0 + 1 · x2 |
[activate#(x1)] | = | 1 |
[n__from(x1)] | = | 1 |
[cons(x1, x2)] | = | 1 · x2 + 0 |
[s(x1)] | = | 1 + 1 · x1 |
[0] | = | 0 |
from#(z0) | → | c | (8) |
from#(z0) | → | c1 | (10) |
sel#(0,cons(z0,z1)) | → | c2 | (12) |
sel#(s(z0),cons(z1,z2)) | → | c3(sel#(z0,activate(z2)),activate#(z2)) | (14) |
activate#(n__from(z0)) | → | c4(from#(z0)) | (16) |
activate#(z0) | → | c5 | (18) |
from(z0) | → | cons(z0,n__from(s(z0))) | (7) |
from(z0) | → | n__from(z0) | (9) |
activate(n__from(z0)) | → | from(z0) | (15) |
activate(z0) | → | z0 | (17) |
activate#(n__from(z0)) | → | c4(from#(z0)) | (16) |
[c] | = | 0 |
[c1] | = | 0 |
[c2] | = | 0 |
[c3(x1, x2)] | = | 1 · x1 + 0 + 1 · x2 |
[c4(x1)] | = | 1 · x1 + 0 |
[c5] | = | 0 |
[activate(x1)] | = | 1 + 1 · x1 |
[from(x1)] | = | 1 + 1 · x1 |
[from#(x1)] | = | 0 |
[sel#(x1, x2)] | = | 1 · x1 + 0 |
[activate#(x1)] | = | 1 |
[n__from(x1)] | = | 1 · x1 + 0 |
[cons(x1, x2)] | = | 1 · x2 + 0 |
[s(x1)] | = | 1 + 1 · x1 |
[0] | = | 0 |
from#(z0) | → | c | (8) |
from#(z0) | → | c1 | (10) |
sel#(0,cons(z0,z1)) | → | c2 | (12) |
sel#(s(z0),cons(z1,z2)) | → | c3(sel#(z0,activate(z2)),activate#(z2)) | (14) |
activate#(n__from(z0)) | → | c4(from#(z0)) | (16) |
activate#(z0) | → | c5 | (18) |
There are no rules in the TRS R. Hence, R/S has complexity O(1).