(0) Obligation:

Q restricted rewrite system:
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.

(1) DependencyPairsProof (EQUIVALENT transformation)

Using Dependency Pairs [AG00,LPAR04] we result in the following initial DP problem.

(2) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ACTIVE(terms(N)) → CONS(recip(sqr(N)), terms(s(N)))
ACTIVE(terms(N)) → RECIP(sqr(N))
ACTIVE(terms(N)) → SQR(N)
ACTIVE(terms(N)) → TERMS(s(N))
ACTIVE(terms(N)) → S(N)
ACTIVE(sqr(s(X))) → S(add(sqr(X), dbl(X)))
ACTIVE(sqr(s(X))) → ADD(sqr(X), dbl(X))
ACTIVE(sqr(s(X))) → SQR(X)
ACTIVE(sqr(s(X))) → DBL(X)
ACTIVE(dbl(s(X))) → S(s(dbl(X)))
ACTIVE(dbl(s(X))) → S(dbl(X))
ACTIVE(dbl(s(X))) → DBL(X)
ACTIVE(add(s(X), Y)) → S(add(X, Y))
ACTIVE(add(s(X), Y)) → ADD(X, Y)
ACTIVE(first(s(X), cons(Y, Z))) → CONS(Y, first(X, Z))
ACTIVE(first(s(X), cons(Y, Z))) → FIRST(X, Z)
ACTIVE(terms(X)) → TERMS(active(X))
ACTIVE(terms(X)) → ACTIVE(X)
ACTIVE(cons(X1, X2)) → CONS(active(X1), X2)
ACTIVE(cons(X1, X2)) → ACTIVE(X1)
ACTIVE(recip(X)) → RECIP(active(X))
ACTIVE(recip(X)) → ACTIVE(X)
ACTIVE(sqr(X)) → SQR(active(X))
ACTIVE(sqr(X)) → ACTIVE(X)
ACTIVE(add(X1, X2)) → ADD(active(X1), X2)
ACTIVE(add(X1, X2)) → ACTIVE(X1)
ACTIVE(add(X1, X2)) → ADD(X1, active(X2))
ACTIVE(add(X1, X2)) → ACTIVE(X2)
ACTIVE(dbl(X)) → DBL(active(X))
ACTIVE(dbl(X)) → ACTIVE(X)
ACTIVE(first(X1, X2)) → FIRST(active(X1), X2)
ACTIVE(first(X1, X2)) → ACTIVE(X1)
ACTIVE(first(X1, X2)) → FIRST(X1, active(X2))
ACTIVE(first(X1, X2)) → ACTIVE(X2)
TERMS(mark(X)) → TERMS(X)
CONS(mark(X1), X2) → CONS(X1, X2)
RECIP(mark(X)) → RECIP(X)
SQR(mark(X)) → SQR(X)
ADD(mark(X1), X2) → ADD(X1, X2)
ADD(X1, mark(X2)) → ADD(X1, X2)
DBL(mark(X)) → DBL(X)
FIRST(mark(X1), X2) → FIRST(X1, X2)
FIRST(X1, mark(X2)) → FIRST(X1, X2)
PROPER(terms(X)) → TERMS(proper(X))
PROPER(terms(X)) → PROPER(X)
PROPER(cons(X1, X2)) → CONS(proper(X1), proper(X2))
PROPER(cons(X1, X2)) → PROPER(X1)
PROPER(cons(X1, X2)) → PROPER(X2)
PROPER(recip(X)) → RECIP(proper(X))
PROPER(recip(X)) → PROPER(X)
PROPER(sqr(X)) → SQR(proper(X))
PROPER(sqr(X)) → PROPER(X)
PROPER(s(X)) → S(proper(X))
PROPER(s(X)) → PROPER(X)
PROPER(add(X1, X2)) → ADD(proper(X1), proper(X2))
PROPER(add(X1, X2)) → PROPER(X1)
PROPER(add(X1, X2)) → PROPER(X2)
PROPER(dbl(X)) → DBL(proper(X))
PROPER(dbl(X)) → PROPER(X)
PROPER(first(X1, X2)) → FIRST(proper(X1), proper(X2))
PROPER(first(X1, X2)) → PROPER(X1)
PROPER(first(X1, X2)) → PROPER(X2)
TERMS(ok(X)) → TERMS(X)
CONS(ok(X1), ok(X2)) → CONS(X1, X2)
RECIP(ok(X)) → RECIP(X)
SQR(ok(X)) → SQR(X)
S(ok(X)) → S(X)
ADD(ok(X1), ok(X2)) → ADD(X1, X2)
DBL(ok(X)) → DBL(X)
FIRST(ok(X1), ok(X2)) → FIRST(X1, X2)
TOP(mark(X)) → TOP(proper(X))
TOP(mark(X)) → PROPER(X)
TOP(ok(X)) → TOP(active(X))
TOP(ok(X)) → ACTIVE(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(3) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 11 SCCs with 35 less nodes.

(4) Complex Obligation (AND)

(5) Obligation:

Q DP problem:
The TRS P consists of the following rules:

S(ok(X)) → S(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(6) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


S(ok(X)) → S(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
S(x1)  =  S(x1)
ok(x1)  =  ok(x1)
active(x1)  =  x1
terms(x1)  =  x1
mark(x1)  =  mark
cons(x1, x2)  =  cons(x1, x2)
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x1
dbl(x1)  =  x1
first(x1, x2)  =  x1
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
S1 > [ok1, mark, nil, top]
proper1 > cons2 > [ok1, mark, nil, top]
proper1 > 0 > [ok1, mark, nil, top]

Status:
S1: [1]
ok1: [1]
mark: []
cons2: [2,1]
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(7) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(8) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(9) TRUE

(10) Obligation:

Q DP problem:
The TRS P consists of the following rules:

FIRST(X1, mark(X2)) → FIRST(X1, X2)
FIRST(mark(X1), X2) → FIRST(X1, X2)
FIRST(ok(X1), ok(X2)) → FIRST(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(11) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


FIRST(ok(X1), ok(X2)) → FIRST(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
FIRST(x1, x2)  =  x2
mark(x1)  =  x1
ok(x1)  =  ok(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  x2
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr(x1)
s(x1)  =  x1
0  =  0
add(x1, x2)  =  add(x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1)
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
[terms1, sqr1, proper1] > [ok1, recip1, 0, add1, dbl1, first1, nil, top]

Status:
ok1: [1]
terms1: [1]
recip1: [1]
sqr1: [1]
0: []
add1: [1]
dbl1: [1]
first1: [1]
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(12) Obligation:

Q DP problem:
The TRS P consists of the following rules:

FIRST(X1, mark(X2)) → FIRST(X1, X2)
FIRST(mark(X1), X2) → FIRST(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(13) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


FIRST(X1, mark(X2)) → FIRST(X1, X2)
FIRST(mark(X1), X2) → FIRST(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
FIRST(x1, x2)  =  FIRST(x1, x2)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
FIRST2 > [mark1, cons1, sqr1, s, dbl1, nil, top]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil, top]
0 > [mark1, cons1, sqr1, s, dbl1, nil, top]
add2 > [mark1, cons1, sqr1, s, dbl1, nil, top]
first2 > [mark1, cons1, sqr1, s, dbl1, nil, top]

Status:
FIRST2: [1,2]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [2,1]
nil: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(14) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(15) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(16) TRUE

(17) Obligation:

Q DP problem:
The TRS P consists of the following rules:

DBL(ok(X)) → DBL(X)
DBL(mark(X)) → DBL(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(18) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


DBL(ok(X)) → DBL(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
DBL(x1)  =  x1
ok(x1)  =  ok(x1)
mark(x1)  =  x1
active(x1)  =  x1
terms(x1)  =  x1
cons(x1, x2)  =  x1
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x2
dbl(x1)  =  x1
first(x1, x2)  =  x2
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
proper1 > [ok1, 0] > [nil, top]

Status:
ok1: [1]
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(19) Obligation:

Q DP problem:
The TRS P consists of the following rules:

DBL(mark(X)) → DBL(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(20) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


DBL(mark(X)) → DBL(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
DBL(x1)  =  DBL(x1)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top(x1)

Lexicographic path order with status [LPO].
Quasi-Precedence:
DBL1 > [mark1, cons1, sqr1, s, dbl1, nil]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil]
0 > [mark1, cons1, sqr1, s, dbl1, nil]
add2 > [mark1, cons1, sqr1, s, dbl1, nil]
first2 > [mark1, cons1, sqr1, s, dbl1, nil]
top1 > [mark1, cons1, sqr1, s, dbl1, nil]

Status:
DBL1: [1]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top1: [1]


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(21) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(22) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(23) TRUE

(24) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ADD(X1, mark(X2)) → ADD(X1, X2)
ADD(mark(X1), X2) → ADD(X1, X2)
ADD(ok(X1), ok(X2)) → ADD(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(25) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ADD(ok(X1), ok(X2)) → ADD(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
ADD(x1, x2)  =  x2
mark(x1)  =  x1
ok(x1)  =  ok(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  x2
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr(x1)
s(x1)  =  x1
0  =  0
add(x1, x2)  =  add(x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1)
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
[terms1, sqr1, proper1] > [ok1, recip1, 0, add1, dbl1, first1, nil, top]

Status:
ok1: [1]
terms1: [1]
recip1: [1]
sqr1: [1]
0: []
add1: [1]
dbl1: [1]
first1: [1]
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(26) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ADD(X1, mark(X2)) → ADD(X1, X2)
ADD(mark(X1), X2) → ADD(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(27) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ADD(X1, mark(X2)) → ADD(X1, X2)
ADD(mark(X1), X2) → ADD(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
ADD(x1, x2)  =  ADD(x1, x2)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
ADD2 > [mark1, cons1, sqr1, s, dbl1, nil, top]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil, top]
0 > [mark1, cons1, sqr1, s, dbl1, nil, top]
add2 > [mark1, cons1, sqr1, s, dbl1, nil, top]
first2 > [mark1, cons1, sqr1, s, dbl1, nil, top]

Status:
ADD2: [1,2]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [2,1]
nil: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(28) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(29) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(30) TRUE

(31) Obligation:

Q DP problem:
The TRS P consists of the following rules:

SQR(ok(X)) → SQR(X)
SQR(mark(X)) → SQR(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(32) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


SQR(ok(X)) → SQR(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
SQR(x1)  =  x1
ok(x1)  =  ok(x1)
mark(x1)  =  x1
active(x1)  =  x1
terms(x1)  =  x1
cons(x1, x2)  =  x1
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x2
dbl(x1)  =  x1
first(x1, x2)  =  x2
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
proper1 > [ok1, 0] > [nil, top]

Status:
ok1: [1]
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(33) Obligation:

Q DP problem:
The TRS P consists of the following rules:

SQR(mark(X)) → SQR(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(34) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


SQR(mark(X)) → SQR(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
SQR(x1)  =  SQR(x1)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top(x1)

Lexicographic path order with status [LPO].
Quasi-Precedence:
SQR1 > [mark1, cons1, sqr1, s, dbl1, nil]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil]
0 > [mark1, cons1, sqr1, s, dbl1, nil]
add2 > [mark1, cons1, sqr1, s, dbl1, nil]
first2 > [mark1, cons1, sqr1, s, dbl1, nil]
top1 > [mark1, cons1, sqr1, s, dbl1, nil]

Status:
SQR1: [1]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top1: [1]


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(35) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(36) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(37) TRUE

(38) Obligation:

Q DP problem:
The TRS P consists of the following rules:

RECIP(ok(X)) → RECIP(X)
RECIP(mark(X)) → RECIP(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(39) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


RECIP(ok(X)) → RECIP(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
RECIP(x1)  =  x1
ok(x1)  =  ok(x1)
mark(x1)  =  x1
active(x1)  =  x1
terms(x1)  =  x1
cons(x1, x2)  =  x1
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x2
dbl(x1)  =  x1
first(x1, x2)  =  x2
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
proper1 > [ok1, 0] > [nil, top]

Status:
ok1: [1]
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(40) Obligation:

Q DP problem:
The TRS P consists of the following rules:

RECIP(mark(X)) → RECIP(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(41) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


RECIP(mark(X)) → RECIP(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
RECIP(x1)  =  RECIP(x1)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top(x1)

Lexicographic path order with status [LPO].
Quasi-Precedence:
RECIP1 > [mark1, cons1, sqr1, s, dbl1, nil]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil]
0 > [mark1, cons1, sqr1, s, dbl1, nil]
add2 > [mark1, cons1, sqr1, s, dbl1, nil]
first2 > [mark1, cons1, sqr1, s, dbl1, nil]
top1 > [mark1, cons1, sqr1, s, dbl1, nil]

Status:
RECIP1: [1]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top1: [1]


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(42) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(43) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(44) TRUE

(45) Obligation:

Q DP problem:
The TRS P consists of the following rules:

CONS(ok(X1), ok(X2)) → CONS(X1, X2)
CONS(mark(X1), X2) → CONS(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(46) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


CONS(ok(X1), ok(X2)) → CONS(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
CONS(x1, x2)  =  CONS(x2)
ok(x1)  =  ok(x1)
mark(x1)  =  mark
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  s(x1)
0  =  0
add(x1, x2)  =  add(x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1)
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
CONS1 > [ok1, mark, cons1, s1, add1, dbl1, first1, nil, top]
[terms1, 0, proper1] > [ok1, mark, cons1, s1, add1, dbl1, first1, nil, top]

Status:
CONS1: [1]
ok1: [1]
mark: []
terms1: [1]
cons1: [1]
s1: [1]
0: []
add1: [1]
dbl1: [1]
first1: [1]
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(47) Obligation:

Q DP problem:
The TRS P consists of the following rules:

CONS(mark(X1), X2) → CONS(X1, X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(48) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


CONS(mark(X1), X2) → CONS(X1, X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
CONS(x1, x2)  =  x1
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top(x1)

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms1 > [mark1, cons1, sqr1, s, dbl1, nil, top1]
0 > [mark1, cons1, sqr1, s, dbl1, nil, top1]
add2 > [mark1, cons1, sqr1, s, dbl1, nil, top1]
first2 > [mark1, cons1, sqr1, s, dbl1, nil, top1]

Status:
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top1: [1]


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(49) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(50) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(51) TRUE

(52) Obligation:

Q DP problem:
The TRS P consists of the following rules:

TERMS(ok(X)) → TERMS(X)
TERMS(mark(X)) → TERMS(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(53) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


TERMS(ok(X)) → TERMS(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
TERMS(x1)  =  x1
ok(x1)  =  ok(x1)
mark(x1)  =  x1
active(x1)  =  x1
terms(x1)  =  x1
cons(x1, x2)  =  x1
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x2
dbl(x1)  =  x1
first(x1, x2)  =  x2
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
proper1 > [ok1, 0] > [nil, top]

Status:
ok1: [1]
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(54) Obligation:

Q DP problem:
The TRS P consists of the following rules:

TERMS(mark(X)) → TERMS(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(55) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


TERMS(mark(X)) → TERMS(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
TERMS(x1)  =  TERMS(x1)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  x1
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top(x1)

Lexicographic path order with status [LPO].
Quasi-Precedence:
TERMS1 > [mark1, cons1, sqr1, s, dbl1, nil]
terms1 > [mark1, cons1, sqr1, s, dbl1, nil]
0 > [mark1, cons1, sqr1, s, dbl1, nil]
add2 > [mark1, cons1, sqr1, s, dbl1, nil]
first2 > [mark1, cons1, sqr1, s, dbl1, nil]
top1 > [mark1, cons1, sqr1, s, dbl1, nil]

Status:
TERMS1: [1]
mark1: [1]
terms1: [1]
cons1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top1: [1]


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(56) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(57) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(58) TRUE

(59) Obligation:

Q DP problem:
The TRS P consists of the following rules:

PROPER(cons(X1, X2)) → PROPER(X1)
PROPER(terms(X)) → PROPER(X)
PROPER(cons(X1, X2)) → PROPER(X2)
PROPER(recip(X)) → PROPER(X)
PROPER(sqr(X)) → PROPER(X)
PROPER(s(X)) → PROPER(X)
PROPER(add(X1, X2)) → PROPER(X1)
PROPER(add(X1, X2)) → PROPER(X2)
PROPER(dbl(X)) → PROPER(X)
PROPER(first(X1, X2)) → PROPER(X1)
PROPER(first(X1, X2)) → PROPER(X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(60) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


PROPER(cons(X1, X2)) → PROPER(X1)
PROPER(terms(X)) → PROPER(X)
PROPER(cons(X1, X2)) → PROPER(X2)
PROPER(recip(X)) → PROPER(X)
PROPER(s(X)) → PROPER(X)
PROPER(add(X1, X2)) → PROPER(X1)
PROPER(add(X1, X2)) → PROPER(X2)
PROPER(dbl(X)) → PROPER(X)
PROPER(first(X1, X2)) → PROPER(X1)
PROPER(first(X1, X2)) → PROPER(X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
PROPER(x1)  =  PROPER(x1)
cons(x1, x2)  =  cons(x1, x2)
terms(x1)  =  terms(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  x1
s(x1)  =  s(x1)
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
active(x1)  =  x1
mark(x1)  =  mark
0  =  0
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
PROPER1 > [cons2, s1, add2, dbl1, mark, nil, top]
terms1 > [cons2, s1, add2, dbl1, mark, nil, top]
recip1 > [cons2, s1, add2, dbl1, mark, nil, top]
first2 > [cons2, s1, add2, dbl1, mark, nil, top]
0 > [cons2, s1, add2, dbl1, mark, nil, top]

Status:
PROPER1: [1]
cons2: [1,2]
terms1: [1]
recip1: [1]
s1: [1]
add2: [2,1]
dbl1: [1]
first2: [2,1]
mark: []
0: []
nil: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(61) Obligation:

Q DP problem:
The TRS P consists of the following rules:

PROPER(sqr(X)) → PROPER(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(62) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


PROPER(sqr(X)) → PROPER(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
PROPER(x1)  =  PROPER(x1)
sqr(x1)  =  sqr(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
mark(x1)  =  mark
cons(x1, x2)  =  cons(x1, x2)
recip(x1)  =  recip(x1)
s(x1)  =  s(x1)
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  ok
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
PROPER1 > [mark, cons2, recip1, s1, add2, dbl1, first2, nil, ok, top]
sqr1 > 0 > [mark, cons2, recip1, s1, add2, dbl1, first2, nil, ok, top]
terms1 > [mark, cons2, recip1, s1, add2, dbl1, first2, nil, ok, top]

Status:
PROPER1: [1]
sqr1: [1]
terms1: [1]
mark: []
cons2: [2,1]
recip1: [1]
s1: [1]
0: []
add2: [1,2]
dbl1: [1]
first2: [2,1]
nil: []
ok: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(63) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(64) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(65) TRUE

(66) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ACTIVE(cons(X1, X2)) → ACTIVE(X1)
ACTIVE(terms(X)) → ACTIVE(X)
ACTIVE(recip(X)) → ACTIVE(X)
ACTIVE(sqr(X)) → ACTIVE(X)
ACTIVE(add(X1, X2)) → ACTIVE(X1)
ACTIVE(add(X1, X2)) → ACTIVE(X2)
ACTIVE(dbl(X)) → ACTIVE(X)
ACTIVE(first(X1, X2)) → ACTIVE(X1)
ACTIVE(first(X1, X2)) → ACTIVE(X2)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(67) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ACTIVE(cons(X1, X2)) → ACTIVE(X1)
ACTIVE(terms(X)) → ACTIVE(X)
ACTIVE(add(X1, X2)) → ACTIVE(X1)
ACTIVE(add(X1, X2)) → ACTIVE(X2)
ACTIVE(first(X1, X2)) → ACTIVE(X1)
ACTIVE(first(X1, X2)) → ACTIVE(X2)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
ACTIVE(x1)  =  x1
cons(x1, x2)  =  cons(x1)
terms(x1)  =  terms(x1)
recip(x1)  =  x1
sqr(x1)  =  x1
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  x1
first(x1, x2)  =  first(x1, x2)
active(x1)  =  x1
mark(x1)  =  mark
s(x1)  =  s(x1)
0  =  0
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  x1
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms1 > [cons1, mark, s1, nil, top]
add2 > [cons1, mark, s1, nil, top]
first2 > [cons1, mark, s1, nil, top]
0 > [cons1, mark, s1, nil, top]

Status:
cons1: [1]
terms1: [1]
add2: [2,1]
first2: [1,2]
mark: []
s1: [1]
0: []
nil: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(68) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ACTIVE(recip(X)) → ACTIVE(X)
ACTIVE(sqr(X)) → ACTIVE(X)
ACTIVE(dbl(X)) → ACTIVE(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(69) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ACTIVE(dbl(X)) → ACTIVE(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
ACTIVE(x1)  =  x1
recip(x1)  =  x1
sqr(x1)  =  x1
dbl(x1)  =  dbl(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
mark(x1)  =  mark
cons(x1, x2)  =  cons(x1, x2)
s(x1)  =  s(x1)
0  =  0
add(x1, x2)  =  add(x1, x2)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  ok
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms1 > [dbl1, mark, cons2, s1, add2, first2, nil, ok, top]
0 > [dbl1, mark, cons2, s1, add2, first2, nil, ok, top]

Status:
dbl1: [1]
terms1: [1]
mark: []
cons2: [2,1]
s1: [1]
0: []
add2: [2,1]
first2: [2,1]
nil: []
ok: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(70) Obligation:

Q DP problem:
The TRS P consists of the following rules:

ACTIVE(recip(X)) → ACTIVE(X)
ACTIVE(sqr(X)) → ACTIVE(X)

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(71) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ACTIVE(recip(X)) → ACTIVE(X)
ACTIVE(sqr(X)) → ACTIVE(X)
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
ACTIVE(x1)  =  x1
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
mark(x1)  =  mark
cons(x1, x2)  =  cons(x1)
s(x1)  =  s(x1)
0  =  0
add(x1, x2)  =  add(x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
proper(x1)  =  x1
ok(x1)  =  ok
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
recip1 > [mark, cons1, s1, add1, dbl1, first2, nil, ok, top]
[sqr1, terms1, 0] > [mark, cons1, s1, add1, dbl1, first2, nil, ok, top]

Status:
recip1: [1]
sqr1: [1]
terms1: [1]
mark: []
cons1: [1]
s1: [1]
0: []
add1: [1]
dbl1: [1]
first2: [2,1]
nil: []
ok: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(72) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(73) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(74) TRUE

(75) Obligation:

Q DP problem:
The TRS P consists of the following rules:

TOP(ok(X)) → TOP(active(X))
TOP(mark(X)) → TOP(proper(X))

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(76) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


TOP(mark(X)) → TOP(proper(X))
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
TOP(x1)  =  TOP(x1)
ok(x1)  =  x1
active(x1)  =  x1
mark(x1)  =  mark(x1)
proper(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr(x1)
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1, x2)
nil  =  nil
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
TOP1 > [s, 0, nil, top]
terms1 > [mark1, cons1, recip1, sqr1] > [s, 0, nil, top]
add2 > [mark1, cons1, recip1, sqr1] > [s, 0, nil, top]
dbl1 > [mark1, cons1, recip1, sqr1] > [s, 0, nil, top]
first2 > [mark1, cons1, recip1, sqr1] > [s, 0, nil, top]

Status:
TOP1: [1]
mark1: [1]
terms1: [1]
cons1: [1]
recip1: [1]
sqr1: [1]
s: []
0: []
add2: [2,1]
dbl1: [1]
first2: [1,2]
nil: []
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(77) Obligation:

Q DP problem:
The TRS P consists of the following rules:

TOP(ok(X)) → TOP(active(X))

The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(78) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


TOP(ok(X)) → TOP(active(X))
The remaining pairs can at least be oriented weakly.
Used ordering: Combined order from the following AFS and order.
TOP(x1)  =  x1
ok(x1)  =  ok(x1)
active(x1)  =  x1
terms(x1)  =  x1
mark(x1)  =  mark
cons(x1, x2)  =  x2
recip(x1)  =  x1
sqr(x1)  =  x1
s(x1)  =  x1
0  =  0
add(x1, x2)  =  x1
dbl(x1)  =  x1
first(x1, x2)  =  x1
nil  =  nil
proper(x1)  =  proper(x1)
top(x1)  =  top

Lexicographic path order with status [LPO].
Quasi-Precedence:
[ok1, proper1] > [mark, 0, nil, top]

Status:
ok1: [1]
mark: []
0: []
nil: []
proper1: [1]
top: []


The following usable rules [FROCOS05] were oriented:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

(79) Obligation:

Q DP problem:
P is empty.
The TRS R consists of the following rules:

active(terms(N)) → mark(cons(recip(sqr(N)), terms(s(N))))
active(sqr(0)) → mark(0)
active(sqr(s(X))) → mark(s(add(sqr(X), dbl(X))))
active(dbl(0)) → mark(0)
active(dbl(s(X))) → mark(s(s(dbl(X))))
active(add(0, X)) → mark(X)
active(add(s(X), Y)) → mark(s(add(X, Y)))
active(first(0, X)) → mark(nil)
active(first(s(X), cons(Y, Z))) → mark(cons(Y, first(X, Z)))
active(terms(X)) → terms(active(X))
active(cons(X1, X2)) → cons(active(X1), X2)
active(recip(X)) → recip(active(X))
active(sqr(X)) → sqr(active(X))
active(add(X1, X2)) → add(active(X1), X2)
active(add(X1, X2)) → add(X1, active(X2))
active(dbl(X)) → dbl(active(X))
active(first(X1, X2)) → first(active(X1), X2)
active(first(X1, X2)) → first(X1, active(X2))
terms(mark(X)) → mark(terms(X))
cons(mark(X1), X2) → mark(cons(X1, X2))
recip(mark(X)) → mark(recip(X))
sqr(mark(X)) → mark(sqr(X))
add(mark(X1), X2) → mark(add(X1, X2))
add(X1, mark(X2)) → mark(add(X1, X2))
dbl(mark(X)) → mark(dbl(X))
first(mark(X1), X2) → mark(first(X1, X2))
first(X1, mark(X2)) → mark(first(X1, X2))
proper(terms(X)) → terms(proper(X))
proper(cons(X1, X2)) → cons(proper(X1), proper(X2))
proper(recip(X)) → recip(proper(X))
proper(sqr(X)) → sqr(proper(X))
proper(s(X)) → s(proper(X))
proper(0) → ok(0)
proper(add(X1, X2)) → add(proper(X1), proper(X2))
proper(dbl(X)) → dbl(proper(X))
proper(first(X1, X2)) → first(proper(X1), proper(X2))
proper(nil) → ok(nil)
terms(ok(X)) → ok(terms(X))
cons(ok(X1), ok(X2)) → ok(cons(X1, X2))
recip(ok(X)) → ok(recip(X))
sqr(ok(X)) → ok(sqr(X))
s(ok(X)) → ok(s(X))
add(ok(X1), ok(X2)) → ok(add(X1, X2))
dbl(ok(X)) → ok(dbl(X))
first(ok(X1), ok(X2)) → ok(first(X1, X2))
top(mark(X)) → top(proper(X))
top(ok(X)) → top(active(X))

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

(80) PisEmptyProof (EQUIVALENT transformation)

The TRS P is empty. Hence, there is no (P,Q,R) chain.

(81) TRUE