(0) Obligation:
Q restricted rewrite system:
The TRS R consists of the following rules:
a__and(tt, T) → mark(T)
a__isNatIList(IL) → a__isNatList(IL)
a__isNat(0) → tt
a__isNat(s(N)) → a__isNat(N)
a__isNat(length(L)) → a__isNatList(L)
a__isNatIList(zeros) → tt
a__isNatIList(cons(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__isNatList(nil) → tt
a__isNatList(cons(N, L)) → a__and(a__isNat(N), a__isNatList(L))
a__isNatList(take(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__zeros → cons(0, zeros)
a__take(0, IL) → a__uTake1(a__isNatIList(IL))
a__uTake1(tt) → nil
a__take(s(M), cons(N, IL)) → a__uTake2(a__and(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL))), M, N, IL)
a__uTake2(tt, M, N, IL) → cons(mark(N), take(M, IL))
a__length(cons(N, L)) → a__uLength(a__and(a__isNat(N), a__isNatList(L)), L)
a__uLength(tt, L) → s(a__length(mark(L)))
mark(and(X1, X2)) → a__and(mark(X1), mark(X2))
mark(isNatIList(X)) → a__isNatIList(X)
mark(isNatList(X)) → a__isNatList(X)
mark(isNat(X)) → a__isNat(X)
mark(length(X)) → a__length(mark(X))
mark(zeros) → a__zeros
mark(take(X1, X2)) → a__take(mark(X1), mark(X2))
mark(uTake1(X)) → a__uTake1(mark(X))
mark(uTake2(X1, X2, X3, X4)) → a__uTake2(mark(X1), X2, X3, X4)
mark(uLength(X1, X2)) → a__uLength(mark(X1), X2)
mark(tt) → tt
mark(0) → 0
mark(s(X)) → s(mark(X))
mark(cons(X1, X2)) → cons(mark(X1), X2)
mark(nil) → nil
a__and(X1, X2) → and(X1, X2)
a__isNatIList(X) → isNatIList(X)
a__isNatList(X) → isNatList(X)
a__isNat(X) → isNat(X)
a__length(X) → length(X)
a__zeros → zeros
a__take(X1, X2) → take(X1, X2)
a__uTake1(X) → uTake1(X)
a__uTake2(X1, X2, X3, X4) → uTake2(X1, X2, X3, X4)
a__uLength(X1, X2) → uLength(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:
A__AND(tt, T) → MARK(T)
A__ISNATILIST(IL) → A__ISNATLIST(IL)
A__ISNAT(s(N)) → A__ISNAT(N)
A__ISNAT(length(L)) → A__ISNATLIST(L)
A__ISNATILIST(cons(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__ISNATILIST(cons(N, IL)) → A__ISNAT(N)
A__ISNATILIST(cons(N, IL)) → A__ISNATILIST(IL)
A__ISNATLIST(cons(N, L)) → A__AND(a__isNat(N), a__isNatList(L))
A__ISNATLIST(cons(N, L)) → A__ISNAT(N)
A__ISNATLIST(cons(N, L)) → A__ISNATLIST(L)
A__ISNATLIST(take(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__ISNATLIST(take(N, IL)) → A__ISNAT(N)
A__ISNATLIST(take(N, IL)) → A__ISNATILIST(IL)
A__TAKE(0, IL) → A__UTAKE1(a__isNatIList(IL))
A__TAKE(0, IL) → A__ISNATILIST(IL)
A__TAKE(s(M), cons(N, IL)) → A__UTAKE2(a__and(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL))), M, N, IL)
A__TAKE(s(M), cons(N, IL)) → A__AND(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL)))
A__TAKE(s(M), cons(N, IL)) → A__ISNAT(M)
A__TAKE(s(M), cons(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__TAKE(s(M), cons(N, IL)) → A__ISNAT(N)
A__TAKE(s(M), cons(N, IL)) → A__ISNATILIST(IL)
A__UTAKE2(tt, M, N, IL) → MARK(N)
A__LENGTH(cons(N, L)) → A__ULENGTH(a__and(a__isNat(N), a__isNatList(L)), L)
A__LENGTH(cons(N, L)) → A__AND(a__isNat(N), a__isNatList(L))
A__LENGTH(cons(N, L)) → A__ISNAT(N)
A__LENGTH(cons(N, L)) → A__ISNATLIST(L)
A__ULENGTH(tt, L) → A__LENGTH(mark(L))
A__ULENGTH(tt, L) → MARK(L)
MARK(and(X1, X2)) → A__AND(mark(X1), mark(X2))
MARK(and(X1, X2)) → MARK(X1)
MARK(and(X1, X2)) → MARK(X2)
MARK(isNatIList(X)) → A__ISNATILIST(X)
MARK(isNatList(X)) → A__ISNATLIST(X)
MARK(isNat(X)) → A__ISNAT(X)
MARK(length(X)) → A__LENGTH(mark(X))
MARK(length(X)) → MARK(X)
MARK(zeros) → A__ZEROS
MARK(take(X1, X2)) → A__TAKE(mark(X1), mark(X2))
MARK(take(X1, X2)) → MARK(X1)
MARK(take(X1, X2)) → MARK(X2)
MARK(uTake1(X)) → A__UTAKE1(mark(X))
MARK(uTake1(X)) → MARK(X)
MARK(uTake2(X1, X2, X3, X4)) → A__UTAKE2(mark(X1), X2, X3, X4)
MARK(uTake2(X1, X2, X3, X4)) → MARK(X1)
MARK(uLength(X1, X2)) → A__ULENGTH(mark(X1), X2)
MARK(uLength(X1, X2)) → MARK(X1)
MARK(s(X)) → MARK(X)
MARK(cons(X1, X2)) → MARK(X1)
The TRS R consists of the following rules:
a__and(tt, T) → mark(T)
a__isNatIList(IL) → a__isNatList(IL)
a__isNat(0) → tt
a__isNat(s(N)) → a__isNat(N)
a__isNat(length(L)) → a__isNatList(L)
a__isNatIList(zeros) → tt
a__isNatIList(cons(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__isNatList(nil) → tt
a__isNatList(cons(N, L)) → a__and(a__isNat(N), a__isNatList(L))
a__isNatList(take(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__zeros → cons(0, zeros)
a__take(0, IL) → a__uTake1(a__isNatIList(IL))
a__uTake1(tt) → nil
a__take(s(M), cons(N, IL)) → a__uTake2(a__and(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL))), M, N, IL)
a__uTake2(tt, M, N, IL) → cons(mark(N), take(M, IL))
a__length(cons(N, L)) → a__uLength(a__and(a__isNat(N), a__isNatList(L)), L)
a__uLength(tt, L) → s(a__length(mark(L)))
mark(and(X1, X2)) → a__and(mark(X1), mark(X2))
mark(isNatIList(X)) → a__isNatIList(X)
mark(isNatList(X)) → a__isNatList(X)
mark(isNat(X)) → a__isNat(X)
mark(length(X)) → a__length(mark(X))
mark(zeros) → a__zeros
mark(take(X1, X2)) → a__take(mark(X1), mark(X2))
mark(uTake1(X)) → a__uTake1(mark(X))
mark(uTake2(X1, X2, X3, X4)) → a__uTake2(mark(X1), X2, X3, X4)
mark(uLength(X1, X2)) → a__uLength(mark(X1), X2)
mark(tt) → tt
mark(0) → 0
mark(s(X)) → s(mark(X))
mark(cons(X1, X2)) → cons(mark(X1), X2)
mark(nil) → nil
a__and(X1, X2) → and(X1, X2)
a__isNatIList(X) → isNatIList(X)
a__isNatList(X) → isNatList(X)
a__isNat(X) → isNat(X)
a__length(X) → length(X)
a__zeros → zeros
a__take(X1, X2) → take(X1, X2)
a__uTake1(X) → uTake1(X)
a__uTake2(X1, X2, X3, X4) → uTake2(X1, X2, X3, X4)
a__uLength(X1, X2) → uLength(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 1 SCC with 3 less nodes.
(4) Obligation:
Q DP problem:
The TRS P consists of the following rules:
MARK(and(X1, X2)) → A__AND(mark(X1), mark(X2))
A__AND(tt, T) → MARK(T)
MARK(and(X1, X2)) → MARK(X1)
MARK(and(X1, X2)) → MARK(X2)
MARK(isNatIList(X)) → A__ISNATILIST(X)
A__ISNATILIST(IL) → A__ISNATLIST(IL)
A__ISNATLIST(cons(N, L)) → A__AND(a__isNat(N), a__isNatList(L))
A__ISNATLIST(cons(N, L)) → A__ISNAT(N)
A__ISNAT(s(N)) → A__ISNAT(N)
A__ISNAT(length(L)) → A__ISNATLIST(L)
A__ISNATLIST(cons(N, L)) → A__ISNATLIST(L)
A__ISNATLIST(take(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__ISNATLIST(take(N, IL)) → A__ISNAT(N)
A__ISNATLIST(take(N, IL)) → A__ISNATILIST(IL)
A__ISNATILIST(cons(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__ISNATILIST(cons(N, IL)) → A__ISNAT(N)
A__ISNATILIST(cons(N, IL)) → A__ISNATILIST(IL)
MARK(isNatList(X)) → A__ISNATLIST(X)
MARK(isNat(X)) → A__ISNAT(X)
MARK(length(X)) → A__LENGTH(mark(X))
A__LENGTH(cons(N, L)) → A__ULENGTH(a__and(a__isNat(N), a__isNatList(L)), L)
A__ULENGTH(tt, L) → A__LENGTH(mark(L))
A__LENGTH(cons(N, L)) → A__AND(a__isNat(N), a__isNatList(L))
A__LENGTH(cons(N, L)) → A__ISNAT(N)
A__LENGTH(cons(N, L)) → A__ISNATLIST(L)
A__ULENGTH(tt, L) → MARK(L)
MARK(length(X)) → MARK(X)
MARK(take(X1, X2)) → A__TAKE(mark(X1), mark(X2))
A__TAKE(0, IL) → A__ISNATILIST(IL)
A__TAKE(s(M), cons(N, IL)) → A__UTAKE2(a__and(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL))), M, N, IL)
A__UTAKE2(tt, M, N, IL) → MARK(N)
MARK(take(X1, X2)) → MARK(X1)
MARK(take(X1, X2)) → MARK(X2)
MARK(uTake1(X)) → MARK(X)
MARK(uTake2(X1, X2, X3, X4)) → A__UTAKE2(mark(X1), X2, X3, X4)
MARK(uTake2(X1, X2, X3, X4)) → MARK(X1)
MARK(uLength(X1, X2)) → A__ULENGTH(mark(X1), X2)
MARK(uLength(X1, X2)) → MARK(X1)
MARK(s(X)) → MARK(X)
MARK(cons(X1, X2)) → MARK(X1)
A__TAKE(s(M), cons(N, IL)) → A__AND(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL)))
A__TAKE(s(M), cons(N, IL)) → A__ISNAT(M)
A__TAKE(s(M), cons(N, IL)) → A__AND(a__isNat(N), a__isNatIList(IL))
A__TAKE(s(M), cons(N, IL)) → A__ISNAT(N)
A__TAKE(s(M), cons(N, IL)) → A__ISNATILIST(IL)
The TRS R consists of the following rules:
a__and(tt, T) → mark(T)
a__isNatIList(IL) → a__isNatList(IL)
a__isNat(0) → tt
a__isNat(s(N)) → a__isNat(N)
a__isNat(length(L)) → a__isNatList(L)
a__isNatIList(zeros) → tt
a__isNatIList(cons(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__isNatList(nil) → tt
a__isNatList(cons(N, L)) → a__and(a__isNat(N), a__isNatList(L))
a__isNatList(take(N, IL)) → a__and(a__isNat(N), a__isNatIList(IL))
a__zeros → cons(0, zeros)
a__take(0, IL) → a__uTake1(a__isNatIList(IL))
a__uTake1(tt) → nil
a__take(s(M), cons(N, IL)) → a__uTake2(a__and(a__isNat(M), a__and(a__isNat(N), a__isNatIList(IL))), M, N, IL)
a__uTake2(tt, M, N, IL) → cons(mark(N), take(M, IL))
a__length(cons(N, L)) → a__uLength(a__and(a__isNat(N), a__isNatList(L)), L)
a__uLength(tt, L) → s(a__length(mark(L)))
mark(and(X1, X2)) → a__and(mark(X1), mark(X2))
mark(isNatIList(X)) → a__isNatIList(X)
mark(isNatList(X)) → a__isNatList(X)
mark(isNat(X)) → a__isNat(X)
mark(length(X)) → a__length(mark(X))
mark(zeros) → a__zeros
mark(take(X1, X2)) → a__take(mark(X1), mark(X2))
mark(uTake1(X)) → a__uTake1(mark(X))
mark(uTake2(X1, X2, X3, X4)) → a__uTake2(mark(X1), X2, X3, X4)
mark(uLength(X1, X2)) → a__uLength(mark(X1), X2)
mark(tt) → tt
mark(0) → 0
mark(s(X)) → s(mark(X))
mark(cons(X1, X2)) → cons(mark(X1), X2)
mark(nil) → nil
a__and(X1, X2) → and(X1, X2)
a__isNatIList(X) → isNatIList(X)
a__isNatList(X) → isNatList(X)
a__isNat(X) → isNat(X)
a__length(X) → length(X)
a__zeros → zeros
a__take(X1, X2) → take(X1, X2)
a__uTake1(X) → uTake1(X)
a__uTake2(X1, X2, X3, X4) → uTake2(X1, X2, X3, X4)
a__uLength(X1, X2) → uLength(X1, X2)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.