(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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)) → MARK(cons(recip(sqr(N)), terms(s(N))))
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(0)) → MARK(0)
ACTIVE(sqr(s(X))) → MARK(s(add(sqr(X), dbl(X))))
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(0)) → MARK(0)
ACTIVE(dbl(s(X))) → MARK(s(s(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(0, X)) → MARK(X)
ACTIVE(add(s(X), Y)) → MARK(s(add(X, Y)))
ACTIVE(add(s(X), Y)) → S(add(X, Y))
ACTIVE(add(s(X), Y)) → ADD(X, Y)
ACTIVE(first(0, X)) → MARK(nil)
ACTIVE(first(s(X), cons(Y, Z))) → MARK(cons(Y, first(X, Z)))
ACTIVE(first(s(X), cons(Y, Z))) → CONS(Y, first(X, Z))
ACTIVE(first(s(X), cons(Y, Z))) → FIRST(X, Z)
MARK(terms(X)) → ACTIVE(terms(mark(X)))
MARK(terms(X)) → TERMS(mark(X))
MARK(terms(X)) → MARK(X)
MARK(cons(X1, X2)) → ACTIVE(cons(mark(X1), X2))
MARK(cons(X1, X2)) → CONS(mark(X1), X2)
MARK(cons(X1, X2)) → MARK(X1)
MARK(recip(X)) → ACTIVE(recip(mark(X)))
MARK(recip(X)) → RECIP(mark(X))
MARK(recip(X)) → MARK(X)
MARK(sqr(X)) → ACTIVE(sqr(mark(X)))
MARK(sqr(X)) → SQR(mark(X))
MARK(sqr(X)) → MARK(X)
MARK(s(X)) → ACTIVE(s(mark(X)))
MARK(s(X)) → S(mark(X))
MARK(s(X)) → MARK(X)
MARK(0) → ACTIVE(0)
MARK(add(X1, X2)) → ACTIVE(add(mark(X1), mark(X2)))
MARK(add(X1, X2)) → ADD(mark(X1), mark(X2))
MARK(add(X1, X2)) → MARK(X1)
MARK(add(X1, X2)) → MARK(X2)
MARK(dbl(X)) → ACTIVE(dbl(mark(X)))
MARK(dbl(X)) → DBL(mark(X))
MARK(dbl(X)) → MARK(X)
MARK(first(X1, X2)) → ACTIVE(first(mark(X1), mark(X2)))
MARK(first(X1, X2)) → FIRST(mark(X1), mark(X2))
MARK(first(X1, X2)) → MARK(X1)
MARK(first(X1, X2)) → MARK(X2)
MARK(nil) → ACTIVE(nil)
TERMS(mark(X)) → TERMS(X)
TERMS(active(X)) → TERMS(X)
CONS(mark(X1), X2) → CONS(X1, X2)
CONS(X1, mark(X2)) → CONS(X1, X2)
CONS(active(X1), X2) → CONS(X1, X2)
CONS(X1, active(X2)) → CONS(X1, X2)
RECIP(mark(X)) → RECIP(X)
RECIP(active(X)) → RECIP(X)
SQR(mark(X)) → SQR(X)
SQR(active(X)) → SQR(X)
S(mark(X)) → S(X)
S(active(X)) → S(X)
ADD(mark(X1), X2) → ADD(X1, X2)
ADD(X1, mark(X2)) → ADD(X1, X2)
ADD(active(X1), X2) → ADD(X1, X2)
ADD(X1, active(X2)) → ADD(X1, X2)
DBL(mark(X)) → DBL(X)
DBL(active(X)) → DBL(X)
FIRST(mark(X1), X2) → FIRST(X1, X2)
FIRST(X1, mark(X2)) → FIRST(X1, X2)
FIRST(active(X1), X2) → FIRST(X1, X2)
FIRST(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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 9 SCCs with 29 less nodes.

(4) Complex Obligation (AND)

(5) 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(active(X1), X2) → FIRST(X1, X2)
FIRST(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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.


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
recip(x1)  =  x1
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
FIRST2 > [cons, s]
sqr > [0, nil] > [mark1, terms1, add2, dbl1, first1] > [cons, s]

Status:
FIRST2: [1,2]
add2: [2,1]
cons: []
sqr: []
dbl1: [1]
mark1: [1]
s: []
0: []
terms1: [1]
first1: [1]
nil: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(7) Obligation:

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

FIRST(active(X1), X2) → FIRST(X1, X2)
FIRST(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(8) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


FIRST(active(X1), X2) → FIRST(X1, X2)
FIRST(X1, active(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)
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
FIRST2 > [s, nil]
terms > cons > [mark1, 0, add2, first2] > active1 > [s, nil]
terms > recip > [mark1, 0, add2, first2] > active1 > [s, nil]
sqr > dbl > [mark1, 0, add2, first2] > active1 > [s, nil]

Status:
mark1: [1]
dbl: []
s: []
recip: []
first2: [2,1]
0: []
add2: [2,1]
active1: [1]
FIRST2: [2,1]
cons: []
sqr: []
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(9) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(10) PisEmptyProof (EQUIVALENT transformation)

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

(11) TRUE

(12) Obligation:

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

DBL(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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.


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)
active(x1)  =  x1
mark(x1)  =  mark(x1)
terms(x1)  =  terms
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
DBL1 > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > recip > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > 0 > nil > [cons, s]

Status:
DBL1: [1]
mark1: [1]
s: []
dbl: []
recip: []
0: []
add2: [2,1]
cons: []
sqr: []
first1: [1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(14) Obligation:

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

DBL(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(15) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


DBL(active(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
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > sqr > 0 > [mark1, add2, first2] > cons1 > [active1, s]
terms > sqr > 0 > [mark1, add2, first2] > recip1 > [active1, s]
terms > sqr > 0 > nil > [active1, s]
dbl > 0 > [mark1, add2, first2] > cons1 > [active1, s]
dbl > 0 > [mark1, add2, first2] > recip1 > [active1, s]
dbl > 0 > nil > [active1, s]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(16) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(17) PisEmptyProof (EQUIVALENT transformation)

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

(18) TRUE

(19) 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(active(X1), X2) → ADD(X1, X2)
ADD(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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.


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
cons(x1, x2)  =  x1
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
ADD2 > [s, nil]
[terms, sqr] > recip > [mark1, add1, first1] > [s, nil]
[terms, sqr] > 0 > [mark1, add1, first1] > [s, nil]
dbl > 0 > [mark1, add1, first1] > [s, nil]

Status:
add1: [1]
sqr: []
mark1: [1]
s: []
dbl: []
recip: []
ADD2: [2,1]
0: []
first1: [1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(21) Obligation:

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

ADD(active(X1), X2) → ADD(X1, X2)
ADD(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(22) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ADD(X1, active(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
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > [mark1, add2, first2] > recip > [active1, cons1, s, 0, nil]
[sqr, dbl] > [mark1, add2, first2] > recip > [active1, cons1, s, 0, nil]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
recip: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(23) Obligation:

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

ADD(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(24) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


ADD(active(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)
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
ADD1 > s
[terms, sqr, dbl] > [mark1, cons, add2] > recip1 > active1 > s
[terms, sqr, dbl] > [mark1, cons, add2] > 0 > nil > active1 > s
first > [mark1, cons, add2] > recip1 > active1 > s
first > [mark1, cons, add2] > 0 > nil > active1 > s

Status:
mark1: [1]
dbl: []
s: []
ADD1: [1]
0: []
first: []
add2: [2,1]
active1: [1]
cons: []
sqr: []
nil: []
recip1: [1]
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(25) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(26) PisEmptyProof (EQUIVALENT transformation)

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

(27) TRUE

(28) Obligation:

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

S(active(X)) → S(X)
S(mark(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(29) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


S(mark(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)
active(x1)  =  x1
mark(x1)  =  mark(x1)
terms(x1)  =  terms
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
S1 > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > recip > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > 0 > nil > [cons, s]

Status:
mark1: [1]
s: []
dbl: []
recip: []
0: []
add2: [2,1]
cons: []
sqr: []
first1: [1]
nil: []
S1: [1]
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(30) Obligation:

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

S(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(31) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


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

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > sqr > 0 > [mark1, add2, first2] > cons1 > [active1, s]
terms > sqr > 0 > [mark1, add2, first2] > recip1 > [active1, s]
terms > sqr > 0 > nil > [active1, s]
dbl > 0 > [mark1, add2, first2] > cons1 > [active1, s]
dbl > 0 > [mark1, add2, first2] > recip1 > [active1, s]
dbl > 0 > nil > [active1, s]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(32) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(33) PisEmptyProof (EQUIVALENT transformation)

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

(34) TRUE

(35) Obligation:

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

SQR(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(36) 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)
active(x1)  =  x1
mark(x1)  =  mark(x1)
terms(x1)  =  terms
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
SQR1 > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > recip > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > 0 > nil > [cons, s]

Status:
mark1: [1]
s: []
dbl: []
recip: []
0: []
add2: [2,1]
cons: []
sqr: []
SQR1: [1]
first1: [1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(37) Obligation:

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

SQR(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(38) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


SQR(active(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
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > sqr > 0 > [mark1, add2, first2] > cons1 > [active1, s]
terms > sqr > 0 > [mark1, add2, first2] > recip1 > [active1, s]
terms > sqr > 0 > nil > [active1, s]
dbl > 0 > [mark1, add2, first2] > cons1 > [active1, s]
dbl > 0 > [mark1, add2, first2] > recip1 > [active1, s]
dbl > 0 > nil > [active1, s]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(39) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(40) PisEmptyProof (EQUIVALENT transformation)

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

(41) TRUE

(42) Obligation:

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

RECIP(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(43) 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)
active(x1)  =  x1
mark(x1)  =  mark(x1)
terms(x1)  =  terms
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
RECIP1 > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > recip > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > 0 > nil > [cons, s]

Status:
RECIP1: [1]
mark1: [1]
s: []
dbl: []
recip: []
0: []
add2: [2,1]
cons: []
sqr: []
first1: [1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(44) Obligation:

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

RECIP(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(45) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


RECIP(active(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
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > sqr > 0 > [mark1, add2, first2] > cons1 > [active1, s]
terms > sqr > 0 > [mark1, add2, first2] > recip1 > [active1, s]
terms > sqr > 0 > nil > [active1, s]
dbl > 0 > [mark1, add2, first2] > cons1 > [active1, s]
dbl > 0 > [mark1, add2, first2] > recip1 > [active1, s]
dbl > 0 > nil > [active1, s]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(46) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(47) PisEmptyProof (EQUIVALENT transformation)

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

(48) TRUE

(49) Obligation:

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

CONS(X1, mark(X2)) → CONS(X1, X2)
CONS(mark(X1), X2) → CONS(X1, X2)
CONS(active(X1), X2) → CONS(X1, X2)
CONS(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(50) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


CONS(X1, mark(X2)) → CONS(X1, X2)
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)  =  CONS(x1, x2)
mark(x1)  =  mark(x1)
active(x1)  =  x1
terms(x1)  =  terms(x1)
cons(x1, x2)  =  cons
recip(x1)  =  x1
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl(x1)
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
CONS2 > [cons, s]
sqr > [0, nil] > [mark1, terms1, add2, dbl1, first1] > [cons, s]

Status:
add2: [2,1]
cons: []
sqr: []
CONS2: [1,2]
dbl1: [1]
mark1: [1]
s: []
0: []
terms1: [1]
first1: [1]
nil: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(51) Obligation:

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

CONS(active(X1), X2) → CONS(X1, X2)
CONS(X1, active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(52) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


CONS(active(X1), X2) → CONS(X1, X2)
CONS(X1, active(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(x1, x2)
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
CONS2 > [s, nil]
terms > cons > [mark1, 0, add2, first2] > active1 > [s, nil]
terms > recip > [mark1, 0, add2, first2] > active1 > [s, nil]
sqr > dbl > [mark1, 0, add2, first2] > active1 > [s, nil]

Status:
mark1: [1]
dbl: []
s: []
recip: []
first2: [2,1]
0: []
add2: [2,1]
active1: [1]
cons: []
sqr: []
CONS2: [2,1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(53) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(54) PisEmptyProof (EQUIVALENT transformation)

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

(55) TRUE

(56) Obligation:

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

TERMS(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(57) 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)
active(x1)  =  x1
mark(x1)  =  mark(x1)
terms(x1)  =  terms
cons(x1, x2)  =  cons
recip(x1)  =  recip
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
TERMS1 > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > recip > [cons, s]
[terms, sqr, dbl] > [mark1, add2, first1] > 0 > nil > [cons, s]

Status:
mark1: [1]
TERMS1: [1]
s: []
dbl: []
recip: []
0: []
add2: [2,1]
cons: []
sqr: []
first1: [1]
nil: []
terms: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(58) Obligation:

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

TERMS(active(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(59) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


TERMS(active(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
active(x1)  =  active(x1)
terms(x1)  =  terms
mark(x1)  =  mark(x1)
cons(x1, x2)  =  cons(x1)
recip(x1)  =  recip(x1)
sqr(x1)  =  sqr
s(x1)  =  s
0  =  0
add(x1, x2)  =  add(x1, x2)
dbl(x1)  =  dbl
first(x1, x2)  =  first(x1, x2)
nil  =  nil

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms > sqr > 0 > [mark1, add2, first2] > cons1 > [active1, s]
terms > sqr > 0 > [mark1, add2, first2] > recip1 > [active1, s]
terms > sqr > 0 > nil > [active1, s]
dbl > 0 > [mark1, add2, first2] > cons1 > [active1, s]
dbl > 0 > [mark1, add2, first2] > recip1 > [active1, s]
dbl > 0 > nil > [active1, s]

Status:
cons1: [1]
mark1: [1]
s: []
dbl: []
0: []
first2: [2,1]
active1: [1]
add2: [2,1]
sqr: []
nil: []
terms: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(60) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(61) PisEmptyProof (EQUIVALENT transformation)

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

(62) TRUE

(63) Obligation:

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

MARK(terms(X)) → ACTIVE(terms(mark(X)))
ACTIVE(terms(N)) → MARK(cons(recip(sqr(N)), terms(s(N))))
MARK(terms(X)) → MARK(X)
MARK(cons(X1, X2)) → ACTIVE(cons(mark(X1), X2))
ACTIVE(sqr(s(X))) → MARK(s(add(sqr(X), dbl(X))))
MARK(cons(X1, X2)) → MARK(X1)
MARK(recip(X)) → ACTIVE(recip(mark(X)))
ACTIVE(dbl(s(X))) → MARK(s(s(dbl(X))))
MARK(recip(X)) → MARK(X)
MARK(sqr(X)) → ACTIVE(sqr(mark(X)))
ACTIVE(add(0, X)) → MARK(X)
MARK(sqr(X)) → MARK(X)
MARK(s(X)) → ACTIVE(s(mark(X)))
ACTIVE(add(s(X), Y)) → MARK(s(add(X, Y)))
MARK(s(X)) → MARK(X)
MARK(add(X1, X2)) → ACTIVE(add(mark(X1), mark(X2)))
ACTIVE(first(s(X), cons(Y, Z))) → MARK(cons(Y, first(X, Z)))
MARK(add(X1, X2)) → MARK(X1)
MARK(add(X1, X2)) → MARK(X2)
MARK(dbl(X)) → ACTIVE(dbl(mark(X)))
MARK(dbl(X)) → MARK(X)
MARK(first(X1, X2)) → ACTIVE(first(mark(X1), mark(X2)))
MARK(first(X1, X2)) → MARK(X1)
MARK(first(X1, X2)) → MARK(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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(64) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


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

Lexicographic path order with status [LPO].
Quasi-Precedence:
terms1 > [sqr1, dbl1] > add2 > MARK1 > ACTIVE1 > recip1 > s1
terms1 > [sqr1, dbl1] > 0 > s1
first2 > MARK1 > ACTIVE1 > recip1 > s1
first2 > nil > s1

Status:
add2: [2,1]
MARK1: [1]
sqr1: [1]
dbl1: [1]
s1: [1]
0: []
first2: [1,2]
terms1: [1]
ACTIVE1: [1]
nil: []
recip1: [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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(65) Obligation:

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

MARK(cons(X1, X2)) → MARK(X1)

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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(66) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04].


The following pairs can be oriented strictly and are deleted.


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

Lexicographic path order with status [LPO].
Quasi-Precedence:
MARK1 > [recip, nil]
[cons1, terms1] > first2 > [recip, nil]
sqr > add1 > [recip, nil]
sqr > dbl > 0 > [recip, nil]

Status:
add1: [1]
MARK1: [1]
cons1: [1]
sqr: []
dbl: []
recip: []
0: []
first2: [1,2]
terms1: [1]
nil: []


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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

(67) 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)))
mark(terms(X)) → active(terms(mark(X)))
mark(cons(X1, X2)) → active(cons(mark(X1), X2))
mark(recip(X)) → active(recip(mark(X)))
mark(sqr(X)) → active(sqr(mark(X)))
mark(s(X)) → active(s(mark(X)))
mark(0) → active(0)
mark(add(X1, X2)) → active(add(mark(X1), mark(X2)))
mark(dbl(X)) → active(dbl(mark(X)))
mark(first(X1, X2)) → active(first(mark(X1), mark(X2)))
mark(nil) → active(nil)
terms(mark(X)) → terms(X)
terms(active(X)) → terms(X)
cons(mark(X1), X2) → cons(X1, X2)
cons(X1, mark(X2)) → cons(X1, X2)
cons(active(X1), X2) → cons(X1, X2)
cons(X1, active(X2)) → cons(X1, X2)
recip(mark(X)) → recip(X)
recip(active(X)) → recip(X)
sqr(mark(X)) → sqr(X)
sqr(active(X)) → sqr(X)
s(mark(X)) → s(X)
s(active(X)) → s(X)
add(mark(X1), X2) → add(X1, X2)
add(X1, mark(X2)) → add(X1, X2)
add(active(X1), X2) → add(X1, X2)
add(X1, active(X2)) → add(X1, X2)
dbl(mark(X)) → dbl(X)
dbl(active(X)) → dbl(X)
first(mark(X1), X2) → first(X1, X2)
first(X1, mark(X2)) → first(X1, X2)
first(active(X1), X2) → first(X1, X2)
first(X1, active(X2)) → first(X1, X2)

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

(68) PisEmptyProof (EQUIVALENT transformation)

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

(69) TRUE