(0) Obligation:
Q restricted rewrite system:
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
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:
+1(s(N), s(M)) → +1(N, M)
*1(s(N), s(M)) → +1(N, +(M, *(N, M)))
*1(s(N), s(M)) → +1(M, *(N, M))
*1(s(N), s(M)) → *1(N, M)
GT(NzN, 0) → U_4(is_NzNat(NzN))
GT(NzN, 0) → IS_NZNAT(NzN)
GT(s(N), s(M)) → GT(N, M)
LT(N, M) → GT(M, N)
D(s(N), s(M)) → D(N, M)
QUOT(N, NzM) → U_11(is_NzNat(NzM), N, NzM)
QUOT(N, NzM) → IS_NZNAT(NzM)
U_11(True, N, NzM) → U_1(gt(N, NzM), N, NzM)
U_11(True, N, NzM) → GT(N, NzM)
U_1(True, N, NzM) → QUOT(d(N, NzM), NzM)
U_1(True, N, NzM) → D(N, NzM)
QUOT(NzM, NzM) → U_01(is_NzNat(NzM))
QUOT(NzM, NzM) → IS_NZNAT(NzM)
QUOT(N, NzM) → U_21(is_NzNat(NzM), NzM, N)
U_21(True, NzM, N) → U_2(gt(NzM, N))
U_21(True, NzM, N) → GT(NzM, N)
GCD(NzM, NzM) → U_02(is_NzNat(NzM), NzM)
GCD(NzM, NzM) → IS_NZNAT(NzM)
GCD(NzN, NzM) → U_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
GCD(NzN, NzM) → IS_NZNAT(NzN)
GCD(NzN, NzM) → IS_NZNAT(NzM)
U_31(True, True, NzN, NzM) → U_3(gt(NzN, NzM), NzN, NzM)
U_31(True, True, NzN, NzM) → GT(NzN, NzM)
U_3(True, NzN, NzM) → GCD(d(NzN, NzM), NzM)
U_3(True, NzN, NzM) → D(NzN, NzM)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
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 6 SCCs with 19 less nodes.
(4) Complex Obligation (AND)
(5) Obligation:
Q DP problem:
The TRS P consists of the following rules:
D(s(N), s(M)) → D(N, M)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(6) Obligation:
Q DP problem:
The TRS P consists of the following rules:
GT(s(N), s(M)) → GT(N, M)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(7) Obligation:
Q DP problem:
The TRS P consists of the following rules:
U_31(True, True, NzN, NzM) → U_3(gt(NzN, NzM), NzN, NzM)
U_3(True, NzN, NzM) → GCD(d(NzN, NzM), NzM)
GCD(NzN, NzM) → U_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(8) Obligation:
Q DP problem:
The TRS P consists of the following rules:
U_11(True, N, NzM) → U_1(gt(N, NzM), N, NzM)
U_1(True, N, NzM) → QUOT(d(N, NzM), NzM)
QUOT(N, NzM) → U_11(is_NzNat(NzM), N, NzM)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(9) Obligation:
Q DP problem:
The TRS P consists of the following rules:
+1(s(N), s(M)) → +1(N, M)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.
(10) Obligation:
Q DP problem:
The TRS P consists of the following rules:
*1(s(N), s(M)) → *1(N, M)
The TRS R consists of the following rules:
p(s(N)) → N
+(N, 0) → N
+(s(N), s(M)) → s(s(+(N, M)))
*(N, 0) → 0
*(s(N), s(M)) → s(+(N, +(M, *(N, M))))
gt(0, M) → False
gt(NzN, 0) → u_4(is_NzNat(NzN))
u_4(True) → True
is_NzNat(0) → False
is_NzNat(s(N)) → True
gt(s(N), s(M)) → gt(N, M)
lt(N, M) → gt(M, N)
d(0, N) → N
d(s(N), s(M)) → d(N, M)
quot(N, NzM) → u_11(is_NzNat(NzM), N, NzM)
u_11(True, N, NzM) → u_1(gt(N, NzM), N, NzM)
u_1(True, N, NzM) → s(quot(d(N, NzM), NzM))
quot(NzM, NzM) → u_01(is_NzNat(NzM))
u_01(True) → s(0)
quot(N, NzM) → u_21(is_NzNat(NzM), NzM, N)
u_21(True, NzM, N) → u_2(gt(NzM, N))
u_2(True) → 0
gcd(0, N) → 0
gcd(NzM, NzM) → u_02(is_NzNat(NzM), NzM)
u_02(True, NzM) → NzM
gcd(NzN, NzM) → u_31(is_NzNat(NzN), is_NzNat(NzM), NzN, NzM)
u_31(True, True, NzN, NzM) → u_3(gt(NzN, NzM), NzN, NzM)
u_3(True, NzN, NzM) → gcd(d(NzN, NzM), NzM)
Q is empty.
We have to consider all minimal (P,Q,R)-chains.