Certification Problem

Input (TPDB Runtime_Complexity_Innermost_Rewriting/SK90/2.22)

The rewrite relation of the following TRS is considered.

exp(x,0) s(0) (1)
exp(x,s(y)) *(x,exp(x,y)) (2)
*(0,y) 0 (3)
*(s(x),y) +(y,*(x,y)) (4)
-(0,y) 0 (5)
-(x,0) x (6)
-(s(x),s(y)) -(x,y) (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:
exp#(z0,0) c (9)
originates from
exp(z0,0) s(0) (8)
exp#(z0,s(z1)) c1(*#(z0,exp(z0,z1)),exp#(z0,z1)) (11)
originates from
exp(z0,s(z1)) *(z0,exp(z0,z1)) (10)
*#(0,z0) c2 (13)
originates from
*(0,z0) 0 (12)
*#(s(z0),z1) c3(*#(z0,z1)) (15)
originates from
*(s(z0),z1) +(z1,*(z0,z1)) (14)
-#(0,z0) c4 (17)
originates from
-(0,z0) 0 (16)
-#(z0,0) c5 (19)
originates from
-(z0,0) z0 (18)
-#(s(z0),s(z1)) c6(-#(z0,z1)) (21)
originates from
-(s(z0),s(z1)) -(z0,z1) (20)
Moreover, we add the following terms to the innermost strategy.
exp#(z0,0)
exp#(z0,s(z1))
*#(0,z0)
*#(s(z0),z1)
-#(0,z0)
-#(z0,0)
-#(s(z0),s(z1))

1.1 Usable Rules

We remove the following rules since they are not usable.
-(0,z0) 0 (16)
-(z0,0) z0 (18)
-(s(z0),s(z1)) -(z0,z1) (20)

1.1.1 Rule Shifting

The rules
exp#(z0,0) c (9)
exp#(z0,s(z1)) c1(*#(z0,exp(z0,z1)),exp#(z0,z1)) (11)
-#(0,z0) c4 (17)
-#(z0,0) c5 (19)
-#(s(z0),s(z1)) c6(-#(z0,z1)) (21)
are strictly oriented by the following linear polynomial interpretation over the naturals
[c] = 0
[c1(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c2] = 0
[c3(x1)] = 1 · x1 + 0
[c4] = 0
[c5] = 0
[c6(x1)] = 1 · x1 + 0
[exp(x1, x2)] = 1 + 1 · x1 + 1 · x2
[*(x1, x2)] = 1 + 1 · x1
[exp#(x1, x2)] = 1 + 1 · x2
[*#(x1, x2)] = 0
[-#(x1, x2)] = 1 + 1 · x1 + 1 · x2
[0] = 0
[s(x1)] = 1 + 1 · x1
[+(x1, x2)] = 1 + 1 · x2
which has the intended complexity. Here, only the following usable rules have been considered:
exp#(z0,0) c (9)
exp#(z0,s(z1)) c1(*#(z0,exp(z0,z1)),exp#(z0,z1)) (11)
*#(0,z0) c2 (13)
*#(s(z0),z1) c3(*#(z0,z1)) (15)
-#(0,z0) c4 (17)
-#(z0,0) c5 (19)
-#(s(z0),s(z1)) c6(-#(z0,z1)) (21)

1.1.1.1 Rule Shifting

The rules
*#(0,z0) c2 (13)
are strictly oriented by the following linear polynomial interpretation over the naturals
[c] = 0
[c1(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c2] = 0
[c3(x1)] = 1 · x1 + 0
[c4] = 0
[c5] = 0
[c6(x1)] = 1 · x1 + 0
[exp(x1, x2)] = 3 · x1 + 0 + 2 · x2
[*(x1, x2)] = 2 · x1 + 0
[exp#(x1, x2)] = 1 · x2 + 0
[*#(x1, x2)] = 1
[-#(x1, x2)] = 3 · x1 + 0 + 3 · x2
[0] = 2
[s(x1)] = 2 + 1 · x1
[+(x1, x2)] = 2
which has the intended complexity. Here, only the following usable rules have been considered:
exp#(z0,0) c (9)
exp#(z0,s(z1)) c1(*#(z0,exp(z0,z1)),exp#(z0,z1)) (11)
*#(0,z0) c2 (13)
*#(s(z0),z1) c3(*#(z0,z1)) (15)
-#(0,z0) c4 (17)
-#(z0,0) c5 (19)
-#(s(z0),s(z1)) c6(-#(z0,z1)) (21)

1.1.1.1.1 Rule Shifting

The rules
*#(s(z0),z1) c3(*#(z0,z1)) (15)
are strictly oriented by the following non-linear polynomial interpretation over the naturals
[c] = 0
[c1(x1, x2)] = 1 · x1 + 0 + 1 · x2
[c2] = 0
[c3(x1)] = 1 · x1 + 0
[c4] = 0
[c5] = 0
[c6(x1)] = 1 · x1 + 0
[exp(x1, x2)] = 2 · x1 · x1 + 0
[*(x1, x2)] = 1 + 1 · x1 · x1
[exp#(x1, x2)] = 1 · x2 + 0 + 2 · x1 · x2
[*#(x1, x2)] = 2 · x1 + 0
[-#(x1, x2)] = 1 · x1 + 0 + 1 · x2
[0] = 0
[s(x1)] = 2 + 1 · x1
[+(x1, x2)] = 1 + 1 · x1 + 1 · x2
which has the intended complexity. Here, only the following usable rules have been considered:
exp#(z0,0) c (9)
exp#(z0,s(z1)) c1(*#(z0,exp(z0,z1)),exp#(z0,z1)) (11)
*#(0,z0) c2 (13)
*#(s(z0),z1) c3(*#(z0,z1)) (15)
-#(0,z0) c4 (17)
-#(z0,0) c5 (19)
-#(s(z0),s(z1)) c6(-#(z0,z1)) (21)

1.1.1.1.1.1 R is empty

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