Certification Problem

Input (TPDB Runtime_Complexity_Innermost_Rewriting/AG01/#3.8a)

The rewrite relation of the following TRS is considered.

pred(s(x)) x (1)
minus(x,0) x (2)
minus(x,s(y)) pred(minus(x,y)) (3)
quot(0,s(y)) 0 (4)
quot(s(x),s(y)) s(quot(minus(x,y),s(y))) (5)
log(s(0)) 0 (6)
log(s(s(x))) s(log(s(quot(x,s(s(0)))))) (7)
The evaluation strategy is innermost.

Property / Task

Determine bounds on the runtime complexity.

Answer / Result

An upperbound for the complexity is O(n2).

Proof (by AProVE @ termCOMP 2023)

1 Dependency Tuples

We get the following set of dependency tuples:
pred#(s(z0)) c (9)
originates from
pred(s(z0)) z0 (8)
minus#(z0,0) c1 (11)
originates from
minus(z0,0) z0 (10)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
originates from
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
quot#(0,s(z0)) c3 (15)
originates from
quot(0,s(z0)) 0 (14)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
originates from
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
log#(s(0)) c5 (18)
originates from
log(s(0)) 0 (6)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
originates from
log(s(s(z0))) s(log(s(quot(z0,s(s(0)))))) (19)
Moreover, we add the following terms to the innermost strategy.
pred#(s(z0))
minus#(z0,0)
minus#(z0,s(z1))
quot#(0,s(z0))
quot#(s(z0),s(z1))
log#(s(0))
log#(s(s(z0)))

1.1 Usable Rules

We remove the following rules since they are not usable.
log(s(0)) 0 (6)
log(s(s(z0))) s(log(s(quot(z0,s(s(0)))))) (19)

1.1.1 Rule Shifting

The rules
log#(s(0)) c5 (18)
are strictly oriented by the following linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0 + 1 · x2
[pred#(x1)] = 0
[minus#(x1, x2)] = 0
[quot#(x1, x2)] = 1 · x2 + 0
[log#(x1)] = 1 + 1 · x1
[0] = 0
[s(x1)] = 1 · x1 + 0
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1 Rule Shifting

The rules
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
are strictly oriented by the following linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0
[pred#(x1)] = 0
[minus#(x1, x2)] = 0
[quot#(x1, x2)] = 0
[log#(x1)] = 1 · x1 + 0
[0] = 0
[s(x1)] = 1 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1 Rule Shifting

The rules
quot#(0,s(z0)) c3 (15)
are strictly oriented by the following linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0
[pred#(x1)] = 0
[minus#(x1, x2)] = 0
[quot#(x1, x2)] = 1
[log#(x1)] = 1 · x1 + 0
[0] = 1
[s(x1)] = 1 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1.1 Rule Shifting

The rules
minus#(z0,0) c1 (11)
are strictly oriented by the following non-linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0
[pred#(x1)] = 0
[minus#(x1, x2)] = 1
[quot#(x1, x2)] = 1 · x1 + 0 + 2 · x2
[log#(x1)] = 2 · x1 · x1 + 0
[0] = 0
[s(x1)] = 1 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1.1.1 Rule Shifting

The rules
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
are strictly oriented by the following non-linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0
[pred#(x1)] = 0
[minus#(x1, x2)] = 0
[quot#(x1, x2)] = 2 + 1 · x1
[log#(x1)] = 1 · x1 · x1 + 0
[0] = 0
[s(x1)] = 2 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1.1.1.1 Rule Shifting

The rules
pred#(s(z0)) c (9)
are strictly oriented by the following non-linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 · x1 + 0
[pred#(x1)] = 2
[minus#(x1, x2)] = 1 · x2 + 0
[quot#(x1, x2)] = 1 · x1 · x2 + 0
[log#(x1)] = 1 · x1 · x1 + 0
[0] = 0
[s(x1)] = 2 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1.1.1.1.1 Rule Shifting

The rules
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
are strictly oriented by the following non-linear polynomial interpretation over the naturals
[c] = 0
[c1] = 0
[c2(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c3] = 0
[c4(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c5] = 0
[c6(x1, x2)] = 1 · x1 + 0 + 1 · x2
[minus(x1, x2)] = 1 · x1 + 0
[pred(x1)] = 1 · x1 + 0
[quot(x1, x2)] = 1 + 1 · x1
[pred#(x1)] = 0
[minus#(x1, x2)] = 2 · x2 + 0
[quot#(x1, x2)] = 1 · x1 · x2 + 0
[log#(x1)] = 2 · x1 · x1 + 0
[0] = 0
[s(x1)] = 2 + 1 · x1
which has the intended complexity. Here, only the following usable rules have been considered:
pred#(s(z0)) c (9)
minus#(z0,0) c1 (11)
minus#(z0,s(z1)) c2(pred#(minus(z0,z1)),minus#(z0,z1)) (13)
quot#(0,s(z0)) c3 (15)
quot#(s(z0),s(z1)) c4(quot#(minus(z0,z1),s(z1)),minus#(z0,z1)) (17)
log#(s(0)) c5 (18)
log#(s(s(z0))) c6(log#(s(quot(z0,s(s(0))))),quot#(z0,s(s(0)))) (20)
quot(s(z0),s(z1)) s(quot(minus(z0,z1),s(z1))) (16)
minus(z0,s(z1)) pred(minus(z0,z1)) (12)
minus(z0,0) z0 (10)
quot(0,s(z0)) 0 (14)
pred(s(z0)) z0 (8)

1.1.1.1.1.1.1.1.1.1 R is empty

There are no rules in the TRS R. Hence, R/S has complexity O(1).