(0) Obligation:

Clauses:

average(0, 0, Z) :- ','(!, eq(Z, 0)).
average(0, s(0), Z) :- ','(!, eq(Z, 0)).
average(0, s(s(0)), Z) :- ','(!, eq(Z, s(0))).
average(X, Y, Z) :- ','(p(X, P), average(P, s(Y), Z)).
average(X, Y, Z) :- ','(p(Y, P1), ','(p(P1, P2), ','(p(P2, P3), ','(average(s(X), P3, U), p(Z, U))))).
p(0, 0).
p(s(X), X).
eq(X, X).

Queries:

average(g,g,a).

(1) CutEliminatorProof (SOUND transformation)

Eliminated all cuts by simply ignoring them[PROLOG].

(2) Obligation:

Clauses:

average(0, 0, Z) :- eq(Z, 0).
average(0, s(0), Z) :- eq(Z, 0).
average(0, s(s(0)), Z) :- eq(Z, s(0)).
average(X, Y, Z) :- ','(p(X, P), average(P, s(Y), Z)).
average(X, Y, Z) :- ','(p(Y, P1), ','(p(P1, P2), ','(p(P2, P3), ','(average(s(X), P3, U), p(Z, U))))).
p(0, 0).
p(s(X), X).
eq(X, X).

Queries:

average(g,g,a).

(3) PrologToPiTRSProof (SOUND transformation)

We use the technique of [LOPSTR]. With regard to the inferred argument filtering the predicates were used in the following modes:
average_in: (b,b,f)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1, x2)
average_out_gga(x1, x2, x3)  =  average_out_gga(x1, x2, x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x1, x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x1, x2, x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x2, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x2, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x2, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x1, x2, x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x1, x2, x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1, x2)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog

(4) Obligation:

Pi-finite rewrite system:
The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1, x2)
average_out_gga(x1, x2, x3)  =  average_out_gga(x1, x2, x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x1, x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x1, x2, x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x2, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x2, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x2, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x1, x2, x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x1, x2, x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1, x2)

(5) DependencyPairsProof (EQUIVALENT transformation)

Using Dependency Pairs [AG00,LOPSTR] we result in the following initial DP problem:
Pi DP problem:
The TRS P consists of the following rules:

AVERAGE_IN_GGA(0, 0, Z) → U1_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, 0, Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(0), Z) → U2_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, s(0), Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(s(0)), Z) → U3_GGA(Z, eq_in_ag(Z, s(0)))
AVERAGE_IN_GGA(0, s(s(0)), Z) → EQ_IN_AG(Z, s(0))
AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(X, P)
U4_GGA(X, Y, Z, p_out_ga(X, P)) → U5_GGA(X, Y, Z, average_in_gga(P, s(Y), Z))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(Y, P1)
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → P_IN_GA(P1, P2)
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → P_IN_GA(P2, P3)
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_GGA(X, Y, Z, average_in_gga(s(X), P3, U))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_GGA(X, Y, Z, p_in_ag(Z, U))
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → P_IN_AG(Z, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1, x2)
average_out_gga(x1, x2, x3)  =  average_out_gga(x1, x2, x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x1, x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x1, x2, x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x2, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x2, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x2, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x1, x2, x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x1, x2, x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1, x2)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U1_GGA(x1, x2)  =  U1_GGA(x2)
EQ_IN_AG(x1, x2)  =  EQ_IN_AG(x2)
U2_GGA(x1, x2)  =  U2_GGA(x2)
U3_GGA(x1, x2)  =  U3_GGA(x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x1, x2, x4)
P_IN_GA(x1, x2)  =  P_IN_GA(x1)
U5_GGA(x1, x2, x3, x4)  =  U5_GGA(x1, x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x2, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x2, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x2, x6)
U9_GGA(x1, x2, x3, x4)  =  U9_GGA(x1, x2, x4)
U10_GGA(x1, x2, x3, x4)  =  U10_GGA(x1, x2, x4)
P_IN_AG(x1, x2)  =  P_IN_AG(x2)

We have to consider all (P,R,Pi)-chains

(6) Obligation:

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

AVERAGE_IN_GGA(0, 0, Z) → U1_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, 0, Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(0), Z) → U2_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, s(0), Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(s(0)), Z) → U3_GGA(Z, eq_in_ag(Z, s(0)))
AVERAGE_IN_GGA(0, s(s(0)), Z) → EQ_IN_AG(Z, s(0))
AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(X, P)
U4_GGA(X, Y, Z, p_out_ga(X, P)) → U5_GGA(X, Y, Z, average_in_gga(P, s(Y), Z))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(Y, P1)
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → P_IN_GA(P1, P2)
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → P_IN_GA(P2, P3)
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_GGA(X, Y, Z, average_in_gga(s(X), P3, U))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_GGA(X, Y, Z, p_in_ag(Z, U))
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → P_IN_AG(Z, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1, x2)
average_out_gga(x1, x2, x3)  =  average_out_gga(x1, x2, x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x1, x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x1, x2, x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x2, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x2, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x2, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x1, x2, x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x1, x2, x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1, x2)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U1_GGA(x1, x2)  =  U1_GGA(x2)
EQ_IN_AG(x1, x2)  =  EQ_IN_AG(x2)
U2_GGA(x1, x2)  =  U2_GGA(x2)
U3_GGA(x1, x2)  =  U3_GGA(x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x1, x2, x4)
P_IN_GA(x1, x2)  =  P_IN_GA(x1)
U5_GGA(x1, x2, x3, x4)  =  U5_GGA(x1, x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x2, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x2, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x2, x6)
U9_GGA(x1, x2, x3, x4)  =  U9_GGA(x1, x2, x4)
U10_GGA(x1, x2, x3, x4)  =  U10_GGA(x1, x2, x4)
P_IN_AG(x1, x2)  =  P_IN_AG(x2)

We have to consider all (P,R,Pi)-chains

(7) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LOPSTR] contains 1 SCC with 14 less nodes.

(8) Obligation:

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

AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1, x2)
average_out_gga(x1, x2, x3)  =  average_out_gga(x1, x2, x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x1, x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x1, x2, x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x2, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x2, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x2, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x1, x2, x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x1, x2, x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1, x2)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x1, x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x2, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x2, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x2, x6)

We have to consider all (P,R,Pi)-chains

(9) UsableRulesProof (EQUIVALENT transformation)

For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R.

(10) Obligation:

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

AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)

The TRS R consists of the following rules:

p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)

The argument filtering Pi contains the following mapping:
0  =  0
s(x1)  =  s(x1)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x1, x2)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x1, x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x2, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x2, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x2, x6)

We have to consider all (P,R,Pi)-chains

(11) PiDPToQDPProof (SOUND transformation)

Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.

(12) Obligation:

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

AVERAGE_IN_GGA(X, Y) → U4_GGA(X, Y, p_in_ga(X))
U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, Y, p_in_ga(Y))
U6_GGA(X, Y, p_out_ga(Y, P1)) → U7_GGA(X, Y, p_in_ga(P1))
U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(13) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U4_GGA(X, Y, p_in_ga(X)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(z2, s(z1)) → U4_GGA(z2, s(z1), p_in_ga(z2))
AVERAGE_IN_GGA(s(z0), z3) → U4_GGA(s(z0), z3, p_in_ga(s(z0)))

(14) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, Y, p_in_ga(Y))
U6_GGA(X, Y, p_out_ga(Y, P1)) → U7_GGA(X, Y, p_in_ga(P1))
U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(z2, s(z1)) → U4_GGA(z2, s(z1), p_in_ga(z2))
AVERAGE_IN_GGA(s(z0), z3) → U4_GGA(s(z0), z3, p_in_ga(s(z0)))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(15) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U4_GGA(X, Y, p_in_ga(X)) at position [2] we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))

(16) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, Y, p_in_ga(Y))
U6_GGA(X, Y, p_out_ga(Y, P1)) → U7_GGA(X, Y, p_in_ga(P1))
U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(17) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U6_GGA(X, Y, p_in_ga(Y)) at position [2] we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))

(18) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
U6_GGA(X, Y, p_out_ga(Y, P1)) → U7_GGA(X, Y, p_in_ga(P1))
U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(19) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule U6_GGA(X, Y, p_out_ga(Y, P1)) → U7_GGA(X, Y, p_in_ga(P1)) at position [2] we obtained the following new rules [LPAR04]:

U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))

(20) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(21) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule U7_GGA(X, Y, p_out_ga(P1, P2)) → U8_GGA(X, Y, p_in_ga(P2)) at position [2] we obtained the following new rules [LPAR04]:

U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))

(22) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0, 0)
p_in_ga(s(X)) → p_out_ga(s(X), X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(23) UsableRulesProof (EQUIVALENT transformation)

As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [LPAR04] we can delete all non-usable rules [FROCOS05] from R.

(24) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))

R is empty.
The set Q consists of the following terms:

p_in_ga(x0)

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

(25) QReductionProof (EQUIVALENT transformation)

We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN].

p_in_ga(x0)

(26) Obligation:

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

U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))

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

(27) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U4_GGA(X, Y, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y)) we obtained the following new rules [LPAR04]:

U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))

(28) Obligation:

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

U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))

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

(29) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U8_GGA(X, Y, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3) we obtained the following new rules [LPAR04]:

U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)

(30) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)

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

(31) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U6_GGA(y0, y1, p_out_ga(y1, 0)) → U7_GGA(y0, y1, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))

(32) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))

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

(33) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U6_GGA(y0, y1, p_out_ga(y1, s(x0))) → U7_GGA(y0, y1, p_out_ga(s(x0), x0)) we obtained the following new rules [LPAR04]:

U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))

(34) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))

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

(35) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U7_GGA(y0, y1, p_out_ga(y2, 0)) → U8_GGA(y0, y1, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))

(36) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))

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

(37) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U7_GGA(y0, y1, p_out_ga(y2, s(x0))) → U8_GGA(y0, y1, p_out_ga(s(x0), x0)) we obtained the following new rules [LPAR04]:

U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))

(38) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))

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

(39) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U8_GGA(z0, z1, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0) we obtained the following new rules [LPAR04]:

U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)

(40) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3)
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)

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

(41) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U8_GGA(z0, z1, p_out_ga(s(z3), z3)) → AVERAGE_IN_GGA(s(z0), z3) we obtained the following new rules [LPAR04]:

U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)

(42) Obligation:

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

AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)

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

(43) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))

(44) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))

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

(45) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(0, y1) → U4_GGA(0, y1, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))

(46) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))

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

(47) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, 0, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))

(48) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))

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

(49) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U4_GGA(0, z0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(z0)) we obtained the following new rules [LPAR04]:

U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))

(50) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))

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

(51) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U6_GGA(z0, 0, p_out_ga(0, 0)) → U7_GGA(z0, 0, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))

(52) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))

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

(53) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule U7_GGA(z0, 0, p_out_ga(0, 0)) → U8_GGA(z0, 0, p_out_ga(0, 0)) we obtained the following new rules [LPAR04]:

U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))

(54) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))

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

(55) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, s(x0), p_out_ga(s(x0), x0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))

(56) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))

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

(57) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U4_GGA(s(z0), z1, p_out_ga(s(z0), z0)) → AVERAGE_IN_GGA(z0, s(z1)) we obtained the following new rules [LPAR04]:

U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))

(58) Obligation:

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

AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0))
U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))
U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))

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

(59) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(s(x0), y1, p_out_ga(s(x0), x0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(s(s(y_0)), x1) → U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(s(0), x1, p_out_ga(s(0), 0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(s(x0), 0, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(s(x0), s(y_1)) → U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0))

(60) Obligation:

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

U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))
U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_0)), x1) → U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(s(0), x1, p_out_ga(s(0), 0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(s(x0), 0, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(s(x0), s(y_1)) → U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0))

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

(61) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U6_GGA(z0, s(s(x2)), p_out_ga(s(s(x2)), s(x2))) → U7_GGA(z0, s(s(x2)), p_out_ga(s(x2), x2)) we obtained the following new rules [LPAR04]:

U6_GGA(x0, s(s(0)), p_out_ga(s(s(0)), s(0))) → U7_GGA(x0, s(s(0)), p_out_ga(s(0), 0))
U6_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U7_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(y_1)), s(y_1)))

(62) Obligation:

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

U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))
U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_0)), x1) → U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(s(0), x1, p_out_ga(s(0), 0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(s(x0), 0, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(s(x0), s(y_1)) → U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0))
U6_GGA(x0, s(s(0)), p_out_ga(s(s(0)), s(0))) → U7_GGA(x0, s(s(0)), p_out_ga(s(0), 0))
U6_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U7_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(y_1)), s(y_1)))

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

(63) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U8_GGA(z0, s(s(s(z1))), p_out_ga(s(z1), z1)) → AVERAGE_IN_GGA(s(z0), z1) we obtained the following new rules [LPAR04]:

U8_GGA(x0, s(s(s(0))), p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(0)), s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(y_1)), s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))

(64) Obligation:

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

U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))
U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_0)), x1) → U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(s(0), x1, p_out_ga(s(0), 0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(s(x0), 0, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(s(x0), s(y_1)) → U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0))
U6_GGA(x0, s(s(0)), p_out_ga(s(s(0)), s(0))) → U7_GGA(x0, s(s(0)), p_out_ga(s(0), 0))
U6_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U7_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(y_1)), s(y_1)))
U8_GGA(x0, s(s(s(0))), p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(0)), s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(y_1)), s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))

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

(65) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U7_GGA(z0, s(s(s(x3))), p_out_ga(s(s(x3)), s(x3))) → U8_GGA(z0, s(s(s(x3))), p_out_ga(s(x3), x3)) we obtained the following new rules [LPAR04]:

U7_GGA(x0, s(s(s(0))), p_out_ga(s(s(0)), s(0))) → U8_GGA(x0, s(s(s(0))), p_out_ga(s(0), 0))
U7_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(s(0))), s(s(0)))) → U8_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(0)), s(0)))
U7_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(s(y_1)))), s(s(s(y_1))))) → U8_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(y_1))), s(s(y_1))))
U7_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(s(x1)), s(x1))) → U8_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(x1), x1))
U7_GGA(0, s(s(s(x1))), p_out_ga(s(s(x1)), s(x1))) → U8_GGA(0, s(s(s(x1))), p_out_ga(s(x1), x1))
U7_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U8_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(y_1)), s(y_1)))

(66) Obligation:

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

U6_GGA(z0, s(0), p_out_ga(s(0), 0)) → U7_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(0), p_out_ga(0, 0)) → U8_GGA(z0, s(0), p_out_ga(0, 0))
U7_GGA(z0, s(s(0)), p_out_ga(s(0), 0)) → U8_GGA(z0, s(s(0)), p_out_ga(0, 0))
U8_GGA(z0, 0, p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
U8_GGA(z0, s(s(0)), p_out_ga(0, 0)) → AVERAGE_IN_GGA(s(z0), 0)
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), 0, p_out_ga(0, 0))
U4_GGA(0, s(z0), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0)))
U6_GGA(s(z0), 0, p_out_ga(0, 0)) → U7_GGA(s(z0), 0, p_out_ga(0, 0))
U7_GGA(s(z0), 0, p_out_ga(0, 0)) → U8_GGA(s(z0), 0, p_out_ga(0, 0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, s(0), p_out_ga(s(0), 0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, s(s(y_1)), p_out_ga(s(s(y_1)), s(y_1)))
U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x1))
U4_GGA(s(0), x1, p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(0, s(x1))
U4_GGA(s(x0), 0, p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(0))
U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0)) → AVERAGE_IN_GGA(x0, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_0)), x1) → U4_GGA(s(s(y_0)), x1, p_out_ga(s(s(y_0)), s(y_0)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(s(0), x1, p_out_ga(s(0), 0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(s(x0), 0, p_out_ga(s(x0), x0))
AVERAGE_IN_GGA(s(x0), s(y_1)) → U4_GGA(s(x0), s(y_1), p_out_ga(s(x0), x0))
U6_GGA(x0, s(s(0)), p_out_ga(s(s(0)), s(0))) → U7_GGA(x0, s(s(0)), p_out_ga(s(0), 0))
U6_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U7_GGA(x0, s(s(s(y_1))), p_out_ga(s(s(y_1)), s(y_1)))
U8_GGA(x0, s(s(s(0))), p_out_ga(s(0), 0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(0)), s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, s(s(s(x1))), p_out_ga(s(x1), x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(y_1)), s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))
U7_GGA(x0, s(s(s(0))), p_out_ga(s(s(0)), s(0))) → U8_GGA(x0, s(s(s(0))), p_out_ga(s(0), 0))
U7_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(s(0))), s(s(0)))) → U8_GGA(x0, s(s(s(s(0)))), p_out_ga(s(s(0)), s(0)))
U7_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(s(y_1)))), s(s(s(y_1))))) → U8_GGA(x0, s(s(s(s(s(y_1))))), p_out_ga(s(s(s(y_1))), s(s(y_1))))
U7_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(s(x1)), s(x1))) → U8_GGA(s(y_0), s(s(s(x1))), p_out_ga(s(x1), x1))
U7_GGA(0, s(s(s(x1))), p_out_ga(s(s(x1)), s(x1))) → U8_GGA(0, s(s(s(x1))), p_out_ga(s(x1), x1))
U7_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(s(y_1))), s(s(y_1)))) → U8_GGA(x0, s(s(s(s(y_1)))), p_out_ga(s(s(y_1)), s(y_1)))

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

(67) NonTerminationProof (EQUIVALENT transformation)

We used the non-termination processor [FROCOS05] to show that the DP problem is infinite.
Found a loop by narrowing to the left:

s = U4_GGA(0, s(z0'), p_out_ga(0, 0)) evaluates to t =U4_GGA(0, s(s(z0')), p_out_ga(0, 0))

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:
  • Semiunifier: [ ]
  • Matcher: [z0' / s(z0')]




Rewriting sequence

U4_GGA(0, s(z0'), p_out_ga(0, 0))AVERAGE_IN_GGA(0, s(s(z0')))
with rule U4_GGA(0, s(z0''), p_out_ga(0, 0)) → AVERAGE_IN_GGA(0, s(s(z0''))) at position [] and matcher [z0'' / z0']

AVERAGE_IN_GGA(0, s(s(z0')))U4_GGA(0, s(s(z0')), p_out_ga(0, 0))
with rule AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(0, s(z0), p_out_ga(0, 0))

Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence


All these steps are and every following step will be a correct step w.r.t to Q.



(68) FALSE

(69) PrologToPiTRSProof (SOUND transformation)

We use the technique of [LOPSTR]. With regard to the inferred argument filtering the predicates were used in the following modes:
average_in: (b,b,f)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1)
average_out_gga(x1, x2, x3)  =  average_out_gga(x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog

(70) Obligation:

Pi-finite rewrite system:
The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1)
average_out_gga(x1, x2, x3)  =  average_out_gga(x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1)

(71) DependencyPairsProof (EQUIVALENT transformation)

Using Dependency Pairs [AG00,LOPSTR] we result in the following initial DP problem:
Pi DP problem:
The TRS P consists of the following rules:

AVERAGE_IN_GGA(0, 0, Z) → U1_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, 0, Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(0), Z) → U2_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, s(0), Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(s(0)), Z) → U3_GGA(Z, eq_in_ag(Z, s(0)))
AVERAGE_IN_GGA(0, s(s(0)), Z) → EQ_IN_AG(Z, s(0))
AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(X, P)
U4_GGA(X, Y, Z, p_out_ga(X, P)) → U5_GGA(X, Y, Z, average_in_gga(P, s(Y), Z))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(Y, P1)
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → P_IN_GA(P1, P2)
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → P_IN_GA(P2, P3)
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_GGA(X, Y, Z, average_in_gga(s(X), P3, U))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_GGA(X, Y, Z, p_in_ag(Z, U))
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → P_IN_AG(Z, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1)
average_out_gga(x1, x2, x3)  =  average_out_gga(x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U1_GGA(x1, x2)  =  U1_GGA(x2)
EQ_IN_AG(x1, x2)  =  EQ_IN_AG(x2)
U2_GGA(x1, x2)  =  U2_GGA(x2)
U3_GGA(x1, x2)  =  U3_GGA(x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x2, x4)
P_IN_GA(x1, x2)  =  P_IN_GA(x1)
U5_GGA(x1, x2, x3, x4)  =  U5_GGA(x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x6)
U9_GGA(x1, x2, x3, x4)  =  U9_GGA(x4)
U10_GGA(x1, x2, x3, x4)  =  U10_GGA(x4)
P_IN_AG(x1, x2)  =  P_IN_AG(x2)

We have to consider all (P,R,Pi)-chains

(72) Obligation:

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

AVERAGE_IN_GGA(0, 0, Z) → U1_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, 0, Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(0), Z) → U2_GGA(Z, eq_in_ag(Z, 0))
AVERAGE_IN_GGA(0, s(0), Z) → EQ_IN_AG(Z, 0)
AVERAGE_IN_GGA(0, s(s(0)), Z) → U3_GGA(Z, eq_in_ag(Z, s(0)))
AVERAGE_IN_GGA(0, s(s(0)), Z) → EQ_IN_AG(Z, s(0))
AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(X, P)
U4_GGA(X, Y, Z, p_out_ga(X, P)) → U5_GGA(X, Y, Z, average_in_gga(P, s(Y), Z))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
AVERAGE_IN_GGA(X, Y, Z) → P_IN_GA(Y, P1)
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → P_IN_GA(P1, P2)
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → P_IN_GA(P2, P3)
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_GGA(X, Y, Z, average_in_gga(s(X), P3, U))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_GGA(X, Y, Z, p_in_ag(Z, U))
U9_GGA(X, Y, Z, average_out_gga(s(X), P3, U)) → P_IN_AG(Z, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1)
average_out_gga(x1, x2, x3)  =  average_out_gga(x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U1_GGA(x1, x2)  =  U1_GGA(x2)
EQ_IN_AG(x1, x2)  =  EQ_IN_AG(x2)
U2_GGA(x1, x2)  =  U2_GGA(x2)
U3_GGA(x1, x2)  =  U3_GGA(x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x2, x4)
P_IN_GA(x1, x2)  =  P_IN_GA(x1)
U5_GGA(x1, x2, x3, x4)  =  U5_GGA(x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x6)
U9_GGA(x1, x2, x3, x4)  =  U9_GGA(x4)
U10_GGA(x1, x2, x3, x4)  =  U10_GGA(x4)
P_IN_AG(x1, x2)  =  P_IN_AG(x2)

We have to consider all (P,R,Pi)-chains

(73) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LOPSTR] contains 1 SCC with 14 less nodes.

(74) Obligation:

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

AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)

The TRS R consists of the following rules:

average_in_gga(0, 0, Z) → U1_gga(Z, eq_in_ag(Z, 0))
eq_in_ag(X, X) → eq_out_ag(X, X)
U1_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, 0, Z)
average_in_gga(0, s(0), Z) → U2_gga(Z, eq_in_ag(Z, 0))
U2_gga(Z, eq_out_ag(Z, 0)) → average_out_gga(0, s(0), Z)
average_in_gga(0, s(s(0)), Z) → U3_gga(Z, eq_in_ag(Z, s(0)))
U3_gga(Z, eq_out_ag(Z, s(0))) → average_out_gga(0, s(s(0)), Z)
average_in_gga(X, Y, Z) → U4_gga(X, Y, Z, p_in_ga(X, P))
p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)
U4_gga(X, Y, Z, p_out_ga(X, P)) → U5_gga(X, Y, Z, average_in_gga(P, s(Y), Z))
average_in_gga(X, Y, Z) → U6_gga(X, Y, Z, p_in_ga(Y, P1))
U6_gga(X, Y, Z, p_out_ga(Y, P1)) → U7_gga(X, Y, Z, P1, p_in_ga(P1, P2))
U7_gga(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_gga(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_gga(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → U9_gga(X, Y, Z, average_in_gga(s(X), P3, U))
U9_gga(X, Y, Z, average_out_gga(s(X), P3, U)) → U10_gga(X, Y, Z, p_in_ag(Z, U))
p_in_ag(0, 0) → p_out_ag(0, 0)
p_in_ag(s(X), X) → p_out_ag(s(X), X)
U10_gga(X, Y, Z, p_out_ag(Z, U)) → average_out_gga(X, Y, Z)
U5_gga(X, Y, Z, average_out_gga(P, s(Y), Z)) → average_out_gga(X, Y, Z)

The argument filtering Pi contains the following mapping:
average_in_gga(x1, x2, x3)  =  average_in_gga(x1, x2)
0  =  0
U1_gga(x1, x2)  =  U1_gga(x2)
eq_in_ag(x1, x2)  =  eq_in_ag(x2)
eq_out_ag(x1, x2)  =  eq_out_ag(x1)
average_out_gga(x1, x2, x3)  =  average_out_gga(x3)
s(x1)  =  s(x1)
U2_gga(x1, x2)  =  U2_gga(x2)
U3_gga(x1, x2)  =  U3_gga(x2)
U4_gga(x1, x2, x3, x4)  =  U4_gga(x2, x4)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
U5_gga(x1, x2, x3, x4)  =  U5_gga(x4)
U6_gga(x1, x2, x3, x4)  =  U6_gga(x1, x4)
U7_gga(x1, x2, x3, x4, x5)  =  U7_gga(x1, x5)
U8_gga(x1, x2, x3, x4, x5, x6)  =  U8_gga(x1, x6)
U9_gga(x1, x2, x3, x4)  =  U9_gga(x4)
U10_gga(x1, x2, x3, x4)  =  U10_gga(x4)
p_in_ag(x1, x2)  =  p_in_ag(x2)
p_out_ag(x1, x2)  =  p_out_ag(x1)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x6)

We have to consider all (P,R,Pi)-chains

(75) UsableRulesProof (EQUIVALENT transformation)

For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R.

(76) Obligation:

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

AVERAGE_IN_GGA(X, Y, Z) → U4_GGA(X, Y, Z, p_in_ga(X, P))
U4_GGA(X, Y, Z, p_out_ga(X, P)) → AVERAGE_IN_GGA(P, s(Y), Z)
AVERAGE_IN_GGA(X, Y, Z) → U6_GGA(X, Y, Z, p_in_ga(Y, P1))
U6_GGA(X, Y, Z, p_out_ga(Y, P1)) → U7_GGA(X, Y, Z, P1, p_in_ga(P1, P2))
U7_GGA(X, Y, Z, P1, p_out_ga(P1, P2)) → U8_GGA(X, Y, Z, P1, P2, p_in_ga(P2, P3))
U8_GGA(X, Y, Z, P1, P2, p_out_ga(P2, P3)) → AVERAGE_IN_GGA(s(X), P3, U)

The TRS R consists of the following rules:

p_in_ga(0, 0) → p_out_ga(0, 0)
p_in_ga(s(X), X) → p_out_ga(s(X), X)

The argument filtering Pi contains the following mapping:
0  =  0
s(x1)  =  s(x1)
p_in_ga(x1, x2)  =  p_in_ga(x1)
p_out_ga(x1, x2)  =  p_out_ga(x2)
AVERAGE_IN_GGA(x1, x2, x3)  =  AVERAGE_IN_GGA(x1, x2)
U4_GGA(x1, x2, x3, x4)  =  U4_GGA(x2, x4)
U6_GGA(x1, x2, x3, x4)  =  U6_GGA(x1, x4)
U7_GGA(x1, x2, x3, x4, x5)  =  U7_GGA(x1, x5)
U8_GGA(x1, x2, x3, x4, x5, x6)  =  U8_GGA(x1, x6)

We have to consider all (P,R,Pi)-chains

(77) PiDPToQDPProof (SOUND transformation)

Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.

(78) Obligation:

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

AVERAGE_IN_GGA(X, Y) → U4_GGA(Y, p_in_ga(X))
U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, p_in_ga(Y))
U6_GGA(X, p_out_ga(P1)) → U7_GGA(X, p_in_ga(P1))
U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(79) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U4_GGA(Y, p_in_ga(X)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(z1, s(z0)) → U4_GGA(s(z0), p_in_ga(z1))
AVERAGE_IN_GGA(s(z0), z1) → U4_GGA(z1, p_in_ga(s(z0)))

(80) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, p_in_ga(Y))
U6_GGA(X, p_out_ga(P1)) → U7_GGA(X, p_in_ga(P1))
U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(z1, s(z0)) → U4_GGA(s(z0), p_in_ga(z1))
AVERAGE_IN_GGA(s(z0), z1) → U4_GGA(z1, p_in_ga(s(z0)))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(81) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U4_GGA(Y, p_in_ga(X)) at position [1] we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))

(82) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
AVERAGE_IN_GGA(X, Y) → U6_GGA(X, p_in_ga(Y))
U6_GGA(X, p_out_ga(P1)) → U7_GGA(X, p_in_ga(P1))
U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(83) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule AVERAGE_IN_GGA(X, Y) → U6_GGA(X, p_in_ga(Y)) at position [1] we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))

(84) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U6_GGA(X, p_out_ga(P1)) → U7_GGA(X, p_in_ga(P1))
U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(85) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule U6_GGA(X, p_out_ga(P1)) → U7_GGA(X, p_in_ga(P1)) at position [1] we obtained the following new rules [LPAR04]:

U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))

(86) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(87) Narrowing (SOUND transformation)

By narrowing [LPAR04] the rule U7_GGA(X, p_out_ga(P2)) → U8_GGA(X, p_in_ga(P2)) at position [1] we obtained the following new rules [LPAR04]:

U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))

(88) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))

The TRS R consists of the following rules:

p_in_ga(0) → p_out_ga(0)
p_in_ga(s(X)) → p_out_ga(X)

The set Q consists of the following terms:

p_in_ga(x0)

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

(89) UsableRulesProof (EQUIVALENT transformation)

As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [LPAR04] we can delete all non-usable rules [FROCOS05] from R.

(90) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))

R is empty.
The set Q consists of the following terms:

p_in_ga(x0)

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

(91) QReductionProof (EQUIVALENT transformation)

We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN].

p_in_ga(x0)

(92) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))

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

(93) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))

(94) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))

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

(95) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(0, y1) → U4_GGA(y1, p_out_ga(0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))

(96) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))

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

(97) Instantiation (EQUIVALENT transformation)

By instantiating [LPAR04] the rule AVERAGE_IN_GGA(y0, 0) → U6_GGA(y0, p_out_ga(0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))

(98) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))

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

(99) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule AVERAGE_IN_GGA(y0, s(x0)) → U6_GGA(y0, p_out_ga(x0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))

(100) Obligation:

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

U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y))
U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))

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

(101) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U4_GGA(Y, p_out_ga(P)) → AVERAGE_IN_GGA(P, s(Y)) we obtained the following new rules [LPAR04]:

U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))

(102) Obligation:

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

U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0))
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))
U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))

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

(103) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule AVERAGE_IN_GGA(s(x0), y1) → U4_GGA(y1, p_out_ga(x0)) we obtained the following new rules [LPAR04]:

AVERAGE_IN_GGA(s(s(y_1)), x1) → U4_GGA(x1, p_out_ga(s(y_1)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(x1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(0, p_out_ga(x0))
AVERAGE_IN_GGA(s(x0), s(y_0)) → U4_GGA(s(y_0), p_out_ga(x0))

(104) Obligation:

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

U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3)
U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))
U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_1)), x1) → U4_GGA(x1, p_out_ga(s(y_1)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(x1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(0, p_out_ga(x0))
AVERAGE_IN_GGA(s(x0), s(y_0)) → U4_GGA(s(y_0), p_out_ga(x0))

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

(105) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U8_GGA(X, p_out_ga(P3)) → AVERAGE_IN_GGA(s(X), P3) we obtained the following new rules [LPAR04]:

U8_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, p_out_ga(s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, p_out_ga(s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), p_out_ga(x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, p_out_ga(s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))

(106) Obligation:

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

U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))
U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_1)), x1) → U4_GGA(x1, p_out_ga(s(y_1)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(x1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(0, p_out_ga(x0))
AVERAGE_IN_GGA(s(x0), s(y_0)) → U4_GGA(s(y_0), p_out_ga(x0))
U8_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, p_out_ga(s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, p_out_ga(s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), p_out_ga(x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, p_out_ga(s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))

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

(107) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U6_GGA(y0, p_out_ga(s(x0))) → U7_GGA(y0, p_out_ga(x0)) we obtained the following new rules [LPAR04]:

U6_GGA(x0, p_out_ga(s(0))) → U7_GGA(x0, p_out_ga(0))
U6_GGA(x0, p_out_ga(s(s(y_1)))) → U7_GGA(x0, p_out_ga(s(y_1)))

(108) Obligation:

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

U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))
U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_1)), x1) → U4_GGA(x1, p_out_ga(s(y_1)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(x1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(0, p_out_ga(x0))
AVERAGE_IN_GGA(s(x0), s(y_0)) → U4_GGA(s(y_0), p_out_ga(x0))
U8_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, p_out_ga(s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, p_out_ga(s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), p_out_ga(x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, p_out_ga(s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))
U6_GGA(x0, p_out_ga(s(0))) → U7_GGA(x0, p_out_ga(0))
U6_GGA(x0, p_out_ga(s(s(y_1)))) → U7_GGA(x0, p_out_ga(s(y_1)))

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

(109) ForwardInstantiation (EQUIVALENT transformation)

By forward instantiating [JAR06] the rule U7_GGA(y0, p_out_ga(s(x0))) → U8_GGA(y0, p_out_ga(x0)) we obtained the following new rules [LPAR04]:

U7_GGA(x0, p_out_ga(s(0))) → U8_GGA(x0, p_out_ga(0))
U7_GGA(x0, p_out_ga(s(s(0)))) → U8_GGA(x0, p_out_ga(s(0)))
U7_GGA(x0, p_out_ga(s(s(s(y_1))))) → U8_GGA(x0, p_out_ga(s(s(y_1))))
U7_GGA(s(y_0), p_out_ga(s(x1))) → U8_GGA(s(y_0), p_out_ga(x1))
U7_GGA(0, p_out_ga(s(x1))) → U8_GGA(0, p_out_ga(x1))
U7_GGA(x0, p_out_ga(s(s(y_1)))) → U8_GGA(x0, p_out_ga(s(y_1)))

(110) Obligation:

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

U6_GGA(y0, p_out_ga(0)) → U7_GGA(y0, p_out_ga(0))
U7_GGA(y0, p_out_ga(0)) → U8_GGA(y0, p_out_ga(0))
AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(s(z0), 0) → U6_GGA(s(z0), p_out_ga(0))
AVERAGE_IN_GGA(x0, s(0)) → U6_GGA(x0, p_out_ga(0))
AVERAGE_IN_GGA(x0, s(s(y_1))) → U6_GGA(x0, p_out_ga(s(y_1)))
U4_GGA(x0, p_out_ga(s(y_0))) → AVERAGE_IN_GGA(s(y_0), s(x0))
U4_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0))
U4_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(0))
U4_GGA(s(y_1), p_out_ga(x1)) → AVERAGE_IN_GGA(x1, s(s(y_1)))
AVERAGE_IN_GGA(s(s(y_1)), x1) → U4_GGA(x1, p_out_ga(s(y_1)))
AVERAGE_IN_GGA(s(0), x1) → U4_GGA(x1, p_out_ga(0))
AVERAGE_IN_GGA(s(x0), 0) → U4_GGA(0, p_out_ga(x0))
AVERAGE_IN_GGA(s(x0), s(y_0)) → U4_GGA(s(y_0), p_out_ga(x0))
U8_GGA(x0, p_out_ga(0)) → AVERAGE_IN_GGA(s(x0), 0)
U8_GGA(x0, p_out_ga(s(0))) → AVERAGE_IN_GGA(s(x0), s(0))
U8_GGA(x0, p_out_ga(s(s(y_1)))) → AVERAGE_IN_GGA(s(x0), s(s(y_1)))
U8_GGA(s(y_0), p_out_ga(x1)) → AVERAGE_IN_GGA(s(s(y_0)), x1)
U8_GGA(0, p_out_ga(x1)) → AVERAGE_IN_GGA(s(0), x1)
U8_GGA(x0, p_out_ga(s(y_1))) → AVERAGE_IN_GGA(s(x0), s(y_1))
U6_GGA(x0, p_out_ga(s(0))) → U7_GGA(x0, p_out_ga(0))
U6_GGA(x0, p_out_ga(s(s(y_1)))) → U7_GGA(x0, p_out_ga(s(y_1)))
U7_GGA(x0, p_out_ga(s(0))) → U8_GGA(x0, p_out_ga(0))
U7_GGA(x0, p_out_ga(s(s(0)))) → U8_GGA(x0, p_out_ga(s(0)))
U7_GGA(x0, p_out_ga(s(s(s(y_1))))) → U8_GGA(x0, p_out_ga(s(s(y_1))))
U7_GGA(s(y_0), p_out_ga(s(x1))) → U8_GGA(s(y_0), p_out_ga(x1))
U7_GGA(0, p_out_ga(s(x1))) → U8_GGA(0, p_out_ga(x1))
U7_GGA(x0, p_out_ga(s(s(y_1)))) → U8_GGA(x0, p_out_ga(s(y_1)))

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

(111) NonTerminationProof (EQUIVALENT transformation)

We used the non-termination processor [FROCOS05] to show that the DP problem is infinite.
Found a loop by narrowing to the left:

s = U4_GGA(x0, p_out_ga(0)) evaluates to t =U4_GGA(s(x0), p_out_ga(0))

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:
  • Matcher: [x0 / s(x0)]
  • Semiunifier: [ ]




Rewriting sequence

U4_GGA(x0, p_out_ga(0))AVERAGE_IN_GGA(0, s(x0))
with rule U4_GGA(x0', p_out_ga(0)) → AVERAGE_IN_GGA(0, s(x0')) at position [] and matcher [x0' / x0]

AVERAGE_IN_GGA(0, s(x0))U4_GGA(s(x0), p_out_ga(0))
with rule AVERAGE_IN_GGA(0, s(z0)) → U4_GGA(s(z0), p_out_ga(0))

Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence


All these steps are and every following step will be a correct step w.r.t to Q.



(112) FALSE