(0) Obligation:
Runtime Complexity TRS:
The TRS R consists of the following rules:
terms(N) → cons(recip(sqr(N)), n__terms(s(N)))
sqr(0) → 0
sqr(s(X)) → s(n__add(sqr(activate(X)), dbl(activate(X))))
dbl(0) → 0
dbl(s(X)) → s(n__s(n__dbl(activate(X))))
add(0, X) → X
add(s(X), Y) → s(n__add(activate(X), Y))
first(0, X) → nil
first(s(X), cons(Y, Z)) → cons(Y, n__first(activate(X), activate(Z)))
terms(X) → n__terms(X)
add(X1, X2) → n__add(X1, X2)
s(X) → n__s(X)
dbl(X) → n__dbl(X)
first(X1, X2) → n__first(X1, X2)
activate(n__terms(X)) → terms(X)
activate(n__add(X1, X2)) → add(X1, X2)
activate(n__s(X)) → s(X)
activate(n__dbl(X)) → dbl(X)
activate(n__first(X1, X2)) → first(X1, X2)
activate(X) → X
Rewrite Strategy: INNERMOST
(1) CpxTrsToCdtProof (BOTH BOUNDS(ID, ID) transformation)
Converted Cpx (relative) TRS to CDT
(2) Obligation:
Complexity Dependency Tuples Problem
Rules:
terms(z0) → cons(recip(sqr(z0)), n__terms(s(z0)))
terms(z0) → n__terms(z0)
sqr(0) → 0
sqr(s(z0)) → s(n__add(sqr(activate(z0)), dbl(activate(z0))))
dbl(0) → 0
dbl(s(z0)) → s(n__s(n__dbl(activate(z0))))
dbl(z0) → n__dbl(z0)
add(0, z0) → z0
add(s(z0), z1) → s(n__add(activate(z0), z1))
add(z0, z1) → n__add(z0, z1)
first(0, z0) → nil
first(s(z0), cons(z1, z2)) → cons(z1, n__first(activate(z0), activate(z2)))
first(z0, z1) → n__first(z0, z1)
s(z0) → n__s(z0)
activate(n__terms(z0)) → terms(z0)
activate(n__add(z0, z1)) → add(z0, z1)
activate(n__s(z0)) → s(z0)
activate(n__dbl(z0)) → dbl(z0)
activate(n__first(z0, z1)) → first(z0, z1)
activate(z0) → z0
Tuples:
TERMS(z0) → c(SQR(z0), S(z0))
TERMS(z0) → c1
SQR(0) → c2
SQR(s(z0)) → c3(S(n__add(sqr(activate(z0)), dbl(activate(z0)))), SQR(activate(z0)), ACTIVATE(z0), DBL(activate(z0)), ACTIVATE(z0))
DBL(0) → c4
DBL(s(z0)) → c5(S(n__s(n__dbl(activate(z0)))), ACTIVATE(z0))
DBL(z0) → c6
ADD(0, z0) → c7
ADD(s(z0), z1) → c8(S(n__add(activate(z0), z1)), ACTIVATE(z0))
ADD(z0, z1) → c9
FIRST(0, z0) → c10
FIRST(s(z0), cons(z1, z2)) → c11(ACTIVATE(z0), ACTIVATE(z2))
FIRST(z0, z1) → c12
S(z0) → c13
ACTIVATE(n__terms(z0)) → c14(TERMS(z0))
ACTIVATE(n__add(z0, z1)) → c15(ADD(z0, z1))
ACTIVATE(n__s(z0)) → c16(S(z0))
ACTIVATE(n__dbl(z0)) → c17(DBL(z0))
ACTIVATE(n__first(z0, z1)) → c18(FIRST(z0, z1))
ACTIVATE(z0) → c19
S tuples:
TERMS(z0) → c(SQR(z0), S(z0))
TERMS(z0) → c1
SQR(0) → c2
SQR(s(z0)) → c3(S(n__add(sqr(activate(z0)), dbl(activate(z0)))), SQR(activate(z0)), ACTIVATE(z0), DBL(activate(z0)), ACTIVATE(z0))
DBL(0) → c4
DBL(s(z0)) → c5(S(n__s(n__dbl(activate(z0)))), ACTIVATE(z0))
DBL(z0) → c6
ADD(0, z0) → c7
ADD(s(z0), z1) → c8(S(n__add(activate(z0), z1)), ACTIVATE(z0))
ADD(z0, z1) → c9
FIRST(0, z0) → c10
FIRST(s(z0), cons(z1, z2)) → c11(ACTIVATE(z0), ACTIVATE(z2))
FIRST(z0, z1) → c12
S(z0) → c13
ACTIVATE(n__terms(z0)) → c14(TERMS(z0))
ACTIVATE(n__add(z0, z1)) → c15(ADD(z0, z1))
ACTIVATE(n__s(z0)) → c16(S(z0))
ACTIVATE(n__dbl(z0)) → c17(DBL(z0))
ACTIVATE(n__first(z0, z1)) → c18(FIRST(z0, z1))
ACTIVATE(z0) → c19
K tuples:none
Defined Rule Symbols:
terms, sqr, dbl, add, first, s, activate
Defined Pair Symbols:
TERMS, SQR, DBL, ADD, FIRST, S, ACTIVATE
Compound Symbols:
c, c1, c2, c3, c4, c5, c6, c7, c8, c9, c10, c11, c12, c13, c14, c15, c16, c17, c18, c19
(3) CdtLeafRemovalProof (BOTH BOUNDS(ID, ID) transformation)
Removed 20 trailing nodes:
DBL(0) → c4
TERMS(z0) → c(SQR(z0), S(z0))
SQR(s(z0)) → c3(S(n__add(sqr(activate(z0)), dbl(activate(z0)))), SQR(activate(z0)), ACTIVATE(z0), DBL(activate(z0)), ACTIVATE(z0))
TERMS(z0) → c1
FIRST(s(z0), cons(z1, z2)) → c11(ACTIVATE(z0), ACTIVATE(z2))
DBL(s(z0)) → c5(S(n__s(n__dbl(activate(z0)))), ACTIVATE(z0))
ADD(s(z0), z1) → c8(S(n__add(activate(z0), z1)), ACTIVATE(z0))
ACTIVATE(n__first(z0, z1)) → c18(FIRST(z0, z1))
S(z0) → c13
FIRST(0, z0) → c10
ACTIVATE(n__terms(z0)) → c14(TERMS(z0))
ACTIVATE(n__s(z0)) → c16(S(z0))
ADD(0, z0) → c7
FIRST(z0, z1) → c12
DBL(z0) → c6
SQR(0) → c2
ADD(z0, z1) → c9
ACTIVATE(n__add(z0, z1)) → c15(ADD(z0, z1))
ACTIVATE(n__dbl(z0)) → c17(DBL(z0))
ACTIVATE(z0) → c19
(4) Obligation:
Complexity Dependency Tuples Problem
Rules:
terms(z0) → cons(recip(sqr(z0)), n__terms(s(z0)))
terms(z0) → n__terms(z0)
sqr(0) → 0
sqr(s(z0)) → s(n__add(sqr(activate(z0)), dbl(activate(z0))))
dbl(0) → 0
dbl(s(z0)) → s(n__s(n__dbl(activate(z0))))
dbl(z0) → n__dbl(z0)
add(0, z0) → z0
add(s(z0), z1) → s(n__add(activate(z0), z1))
add(z0, z1) → n__add(z0, z1)
first(0, z0) → nil
first(s(z0), cons(z1, z2)) → cons(z1, n__first(activate(z0), activate(z2)))
first(z0, z1) → n__first(z0, z1)
s(z0) → n__s(z0)
activate(n__terms(z0)) → terms(z0)
activate(n__add(z0, z1)) → add(z0, z1)
activate(n__s(z0)) → s(z0)
activate(n__dbl(z0)) → dbl(z0)
activate(n__first(z0, z1)) → first(z0, z1)
activate(z0) → z0
Tuples:none
S tuples:none
K tuples:none
Defined Rule Symbols:
terms, sqr, dbl, add, first, s, activate
Defined Pair Symbols:none
Compound Symbols:none
(5) SIsEmptyProof (BOTH BOUNDS(ID, ID) transformation)
The set S is empty
(6) BOUNDS(1, 1)