0 Prolog
↳1 CutEliminatorProof (⇐)
↳2 Prolog
↳3 PrologToPiTRSProof (⇐)
↳4 PiTRS
↳5 DependencyPairsProof (⇔)
↳6 PiDP
↳7 DependencyGraphProof (⇔)
↳8 AND
↳9 PiDP
↳10 UsableRulesProof (⇔)
↳11 PiDP
↳12 PiDPToQDPProof (⇐)
↳13 QDP
↳14 QDPSizeChangeProof (⇔)
↳15 TRUE
↳16 PiDP
↳17 PiDPToQDPProof (⇐)
↳18 QDP
↳19 PrologToPiTRSProof (⇐)
↳20 PiTRS
↳21 DependencyPairsProof (⇔)
↳22 PiDP
↳23 DependencyGraphProof (⇔)
↳24 AND
↳25 PiDP
↳26 UsableRulesProof (⇔)
↳27 PiDP
↳28 PiDPToQDPProof (⇐)
↳29 QDP
↳30 QDPSizeChangeProof (⇔)
↳31 TRUE
↳32 PiDP
↳33 PiDPToQDPProof (⇐)
↳34 QDP
↳35 MRRProof (⇔)
↳36 QDP
↳37 PisEmptyProof (⇔)
↳38 TRUE
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(void, L) → U1_AG(L, eq_in_gg(L, []))
IN_ORDER_IN_AG(void, L) → EQ_IN_GG(L, [])
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
IN_ORDER_IN_AG(T, Xs) → VALUE_IN_AA(T, X)
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U2_AG(T, Xs, value_out_aa(T, X)) → APP_IN_AAG(Ls, .(X, Rs), Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → U8_AAG(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → LEFT_IN_AA(T, L)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → RIGHT_IN_AA(T, R)
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_AG(T, Xs, in_order_in_ag(R, Rs))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(void, L) → U1_AG(L, eq_in_gg(L, []))
IN_ORDER_IN_AG(void, L) → EQ_IN_GG(L, [])
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
IN_ORDER_IN_AG(T, Xs) → VALUE_IN_AA(T, X)
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U2_AG(T, Xs, value_out_aa(T, X)) → APP_IN_AAG(Ls, .(X, Rs), Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → U8_AAG(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → LEFT_IN_AA(T, L)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → RIGHT_IN_AA(T, R)
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_AG(T, Xs, in_order_in_ag(R, Rs))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
APP_IN_AAG(.(Zs)) → APP_IN_AAG(Zs)
From the DPs we obtained the following set of size-change graphs:
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(Xs) → U2_AG(Xs, value_in_aa)
U2_AG(Xs, value_out_aa) → U3_AG(Xs, app_in_aag(Xs))
U3_AG(Xs, app_out_aag(Ls, .(Rs), Xs)) → U4_AG(Xs, Ls, Rs, left_in_aa)
U4_AG(Xs, Ls, Rs, left_out_aa) → U5_AG(Xs, Rs, in_order_in_ag(Ls))
U5_AG(Xs, Rs, in_order_out_ag(Ls)) → U6_AG(Xs, Rs, right_in_aa)
U6_AG(Xs, Rs, right_out_aa) → IN_ORDER_IN_AG(Rs)
U4_AG(Xs, Ls, Rs, left_out_aa) → IN_ORDER_IN_AG(Ls)
in_order_in_ag(L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(L)
in_order_in_ag(Xs) → U2_ag(Xs, value_in_aa)
value_in_aa → value_out_aa
U2_ag(Xs, value_out_aa) → U3_ag(Xs, app_in_aag(Xs))
app_in_aag(X) → app_out_aag([], X, X)
app_in_aag(.(Zs)) → U8_aag(Zs, app_in_aag(Zs))
U8_aag(Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(Xs), Ys, .(Zs))
U3_ag(Xs, app_out_aag(Ls, .(Rs), Xs)) → U4_ag(Xs, Ls, Rs, left_in_aa)
left_in_aa → left_out_aa
U4_ag(Xs, Ls, Rs, left_out_aa) → U5_ag(Xs, Rs, in_order_in_ag(Ls))
U5_ag(Xs, Rs, in_order_out_ag(Ls)) → U6_ag(Xs, Rs, right_in_aa)
right_in_aa → right_out_aa
U6_ag(Xs, Rs, right_out_aa) → U7_ag(Xs, in_order_in_ag(Rs))
U7_ag(Xs, in_order_out_ag(Rs)) → in_order_out_ag(Xs)
in_order_in_ag(x0)
eq_in_gg(x0, x1)
U1_ag(x0, x1)
value_in_aa
U2_ag(x0, x1)
app_in_aag(x0)
U8_aag(x0, x1)
U3_ag(x0, x1)
left_in_aa
U4_ag(x0, x1, x2, x3)
U5_ag(x0, x1, x2)
right_in_aa
U6_ag(x0, x1, x2)
U7_ag(x0, x1)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(void, L) → U1_AG(L, eq_in_gg(L, []))
IN_ORDER_IN_AG(void, L) → EQ_IN_GG(L, [])
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
IN_ORDER_IN_AG(T, Xs) → VALUE_IN_AA(T, X)
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U2_AG(T, Xs, value_out_aa(T, X)) → APP_IN_AAG(Ls, .(X, Rs), Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → U8_AAG(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → LEFT_IN_AA(T, L)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → RIGHT_IN_AA(T, R)
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_AG(T, Xs, in_order_in_ag(R, Rs))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(void, L) → U1_AG(L, eq_in_gg(L, []))
IN_ORDER_IN_AG(void, L) → EQ_IN_GG(L, [])
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
IN_ORDER_IN_AG(T, Xs) → VALUE_IN_AA(T, X)
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U2_AG(T, Xs, value_out_aa(T, X)) → APP_IN_AAG(Ls, .(X, Rs), Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → U8_AAG(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → LEFT_IN_AA(T, L)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → RIGHT_IN_AA(T, R)
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_AG(T, Xs, in_order_in_ag(R, Rs))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
APP_IN_AAG(.(X, Xs), Ys, .(X, Zs)) → APP_IN_AAG(Xs, Ys, Zs)
APP_IN_AAG(.(Zs)) → APP_IN_AAG(Zs)
From the DPs we obtained the following set of size-change graphs:
IN_ORDER_IN_AG(T, Xs) → U2_AG(T, Xs, value_in_aa(T, X))
U2_AG(T, Xs, value_out_aa(T, X)) → U3_AG(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
U3_AG(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_AG(T, Xs, X, Ls, Rs, left_in_aa(T, L))
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_AG(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_AG(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_AG(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
U6_AG(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → IN_ORDER_IN_AG(R, Rs)
U4_AG(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → IN_ORDER_IN_AG(L, Ls)
in_order_in_ag(void, L) → U1_ag(L, eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg(X, X)
U1_ag(L, eq_out_gg(L, [])) → in_order_out_ag(void, L)
in_order_in_ag(T, Xs) → U2_ag(T, Xs, value_in_aa(T, X))
value_in_aa(void, X5) → value_out_aa(void, X5)
value_in_aa(node(X6, X, X7), X) → value_out_aa(node(X6, X, X7), X)
U2_ag(T, Xs, value_out_aa(T, X)) → U3_ag(T, Xs, X, app_in_aag(Ls, .(X, Rs), Xs))
app_in_aag([], X, X) → app_out_aag([], X, X)
app_in_aag(.(X, Xs), Ys, .(X, Zs)) → U8_aag(X, Xs, Ys, Zs, app_in_aag(Xs, Ys, Zs))
U8_aag(X, Xs, Ys, Zs, app_out_aag(Xs, Ys, Zs)) → app_out_aag(.(X, Xs), Ys, .(X, Zs))
U3_ag(T, Xs, X, app_out_aag(Ls, .(X, Rs), Xs)) → U4_ag(T, Xs, X, Ls, Rs, left_in_aa(T, L))
left_in_aa(void, void) → left_out_aa(void, void)
left_in_aa(node(L, X1, X2), L) → left_out_aa(node(L, X1, X2), L)
U4_ag(T, Xs, X, Ls, Rs, left_out_aa(T, L)) → U5_ag(T, Xs, X, Ls, Rs, L, in_order_in_ag(L, Ls))
U5_ag(T, Xs, X, Ls, Rs, L, in_order_out_ag(L, Ls)) → U6_ag(T, Xs, X, Ls, Rs, L, right_in_aa(T, R))
right_in_aa(void, void) → right_out_aa(void, void)
right_in_aa(node(X3, X4, R), R) → right_out_aa(node(X3, X4, R), R)
U6_ag(T, Xs, X, Ls, Rs, L, right_out_aa(T, R)) → U7_ag(T, Xs, in_order_in_ag(R, Rs))
U7_ag(T, Xs, in_order_out_ag(R, Rs)) → in_order_out_ag(T, Xs)
IN_ORDER_IN_AG(Xs) → U2_AG(Xs, value_in_aa)
U2_AG(Xs, value_out_aa) → U3_AG(app_in_aag(Xs))
U3_AG(app_out_aag(Ls, .(Rs))) → U4_AG(Ls, Rs, left_in_aa)
U4_AG(Ls, Rs, left_out_aa) → U5_AG(Rs, in_order_in_ag(Ls))
U5_AG(Rs, in_order_out_ag) → U6_AG(Rs, right_in_aa)
U6_AG(Rs, right_out_aa) → IN_ORDER_IN_AG(Rs)
U4_AG(Ls, Rs, left_out_aa) → IN_ORDER_IN_AG(Ls)
in_order_in_ag(L) → U1_ag(eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg
U1_ag(eq_out_gg) → in_order_out_ag
in_order_in_ag(Xs) → U2_ag(Xs, value_in_aa)
value_in_aa → value_out_aa
U2_ag(Xs, value_out_aa) → U3_ag(app_in_aag(Xs))
app_in_aag(X) → app_out_aag([], X)
app_in_aag(.(Zs)) → U8_aag(app_in_aag(Zs))
U8_aag(app_out_aag(Xs, Ys)) → app_out_aag(.(Xs), Ys)
U3_ag(app_out_aag(Ls, .(Rs))) → U4_ag(Ls, Rs, left_in_aa)
left_in_aa → left_out_aa
U4_ag(Ls, Rs, left_out_aa) → U5_ag(Rs, in_order_in_ag(Ls))
U5_ag(Rs, in_order_out_ag) → U6_ag(Rs, right_in_aa)
right_in_aa → right_out_aa
U6_ag(Rs, right_out_aa) → U7_ag(in_order_in_ag(Rs))
U7_ag(in_order_out_ag) → in_order_out_ag
in_order_in_ag(x0)
eq_in_gg(x0, x1)
U1_ag(x0)
value_in_aa
U2_ag(x0, x1)
app_in_aag(x0)
U8_aag(x0)
U3_ag(x0)
left_in_aa
U4_ag(x0, x1, x2)
U5_ag(x0, x1)
right_in_aa
U6_ag(x0, x1)
U7_ag(x0)
IN_ORDER_IN_AG(Xs) → U2_AG(Xs, value_in_aa)
U2_AG(Xs, value_out_aa) → U3_AG(app_in_aag(Xs))
U3_AG(app_out_aag(Ls, .(Rs))) → U4_AG(Ls, Rs, left_in_aa)
U4_AG(Ls, Rs, left_out_aa) → U5_AG(Rs, in_order_in_ag(Ls))
U5_AG(Rs, in_order_out_ag) → U6_AG(Rs, right_in_aa)
U6_AG(Rs, right_out_aa) → IN_ORDER_IN_AG(Rs)
U4_AG(Ls, Rs, left_out_aa) → IN_ORDER_IN_AG(Ls)
in_order_in_ag(L) → U1_ag(eq_in_gg(L, []))
eq_in_gg(X, X) → eq_out_gg
U1_ag(eq_out_gg) → in_order_out_ag
in_order_in_ag(Xs) → U2_ag(Xs, value_in_aa)
value_in_aa → value_out_aa
U2_ag(Xs, value_out_aa) → U3_ag(app_in_aag(Xs))
app_in_aag(X) → app_out_aag([], X)
U3_ag(app_out_aag(Ls, .(Rs))) → U4_ag(Ls, Rs, left_in_aa)
left_in_aa → left_out_aa
U4_ag(Ls, Rs, left_out_aa) → U5_ag(Rs, in_order_in_ag(Ls))
U5_ag(Rs, in_order_out_ag) → U6_ag(Rs, right_in_aa)
right_in_aa → right_out_aa
U6_ag(Rs, right_out_aa) → U7_ag(in_order_in_ag(Rs))
U7_ag(in_order_out_ag) → in_order_out_ag
POL(.(x1)) = 14 + x1
POL(IN_ORDER_IN_AG(x1)) = 4 + x1
POL(U1_ag(x1)) = 2 + x1
POL(U2_AG(x1, x2)) = 2 + x1 + x2
POL(U2_ag(x1, x2)) = 2 + x1 + x2
POL(U3_AG(x1)) = x1
POL(U3_ag(x1)) = x1
POL(U4_AG(x1, x2, x3)) = 11 + x1 + x2 + x3
POL(U4_ag(x1, x2, x3)) = 12 + x1 + x2 + x3
POL(U5_AG(x1, x2)) = 6 + x1 + x2
POL(U5_ag(x1, x2)) = 7 + x1 + x2
POL(U6_AG(x1, x2)) = 5 + x1 + x2
POL(U6_ag(x1, x2)) = 6 + x1 + x2
POL(U7_ag(x1)) = 1 + x1
POL(U8_aag(x1)) = 14 + x1
POL([]) = 0
POL(app_in_aag(x1)) = 1 + x1
POL(app_out_aag(x1, x2)) = x1 + x2
POL(eq_in_gg(x1, x2)) = 1 + x1 + x2
POL(eq_out_gg) = 0
POL(in_order_in_ag(x1)) = 4 + x1
POL(in_order_out_ag) = 1
POL(left_in_aa) = 1
POL(left_out_aa) = 0
POL(right_in_aa) = 1
POL(right_out_aa) = 0
POL(value_in_aa) = 1
POL(value_out_aa) = 0
app_in_aag(.(Zs)) → U8_aag(app_in_aag(Zs))
U8_aag(app_out_aag(Xs, Ys)) → app_out_aag(.(Xs), Ys)
in_order_in_ag(x0)
eq_in_gg(x0, x1)
U1_ag(x0)
value_in_aa
U2_ag(x0, x1)
app_in_aag(x0)
U8_aag(x0)
U3_ag(x0)
left_in_aa
U4_ag(x0, x1, x2)
U5_ag(x0, x1)
right_in_aa
U6_ag(x0, x1)
U7_ag(x0)