(0) Obligation:

Clauses:

goal(A, B, C) :- ','(s2l(A, D), applast(D, B, C)).
applast(L, X, Last) :- ','(append(L, .(X, []), LX), last(Last, LX)).
last(X, .(X, [])).
last(X, .(H, T)) :- last(X, T).
append([], L, L).
append(.(H, L1), L2, .(H, L3)) :- append(L1, L2, L3).
s2l(s(X), .(Y, Xs)) :- s2l(X, Xs).
s2l(0, []).

Queries:

goal(g,a,a).

(1) PrologToPrologProblemTransformerProof (SOUND transformation)

Built Prolog problem from termination graph.

(2) Obligation:

Clauses:

s2l9(s(T24), .(X69, X70)) :- s2l9(T24, X70).
s2l9(0, []).
append25([], T71, .(T71, [])).
append25(.(T78, T81), T82, .(T78, X165)) :- append25(T81, T82, X165).
last22(T91, .(T91, [])).
last22(T101, .(T99, T102)) :- last22(T101, T102).
append21(X141, T63, T64, .(X141, X142)) :- append25(T63, T64, X142).
append46(T128, .(T128, [])).
goal1(s(T16), T10, T11) :- s2l9(T16, X32).
goal1(s(T16), T44, T45) :- ','(s2l9(T16, T43), append21(X105, T43, T44, X104)).
goal1(s(T16), T44, T50) :- ','(s2l9(T16, T43), ','(append21(T48, T43, T44, T49), last22(T50, T49))).
goal1(0, T117, T118) :- append46(T117, X210).
goal1(0, T117, T122) :- ','(append46(T117, T121), last22(T122, T121)).

Queries:

goal1(g,a,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:
goal1_in: (b,f,f)
s2l9_in: (b,f)
append21_in: (f,b,f,f)
append25_in: (b,f,f)
last22_in: (f,b)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog

(4) Obligation:

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

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)

(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:

GOAL1_IN_GAA(s(T16), T10, T11) → U5_GAA(T16, T10, T11, s2l9_in_ga(T16, X32))
GOAL1_IN_GAA(s(T16), T10, T11) → S2L9_IN_GA(T16, X32)
S2L9_IN_GA(s(T24), .(X69, X70)) → U1_GA(T24, X69, X70, s2l9_in_ga(T24, X70))
S2L9_IN_GA(s(T24), .(X69, X70)) → S2L9_IN_GA(T24, X70)
GOAL1_IN_GAA(s(T16), T44, T45) → U6_GAA(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_GAA(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_GAA(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
U6_GAA(T16, T44, T45, s2l9_out_ga(T16, T43)) → APPEND21_IN_AGAA(X105, T43, T44, X104)
APPEND21_IN_AGAA(X141, T63, T64, .(X141, X142)) → U4_AGAA(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
APPEND21_IN_AGAA(X141, T63, T64, .(X141, X142)) → APPEND25_IN_GAA(T63, T64, X142)
APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → U2_GAA(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → APPEND25_IN_GAA(T81, T82, X165)
GOAL1_IN_GAA(s(T16), T44, T50) → U8_GAA(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_GAA(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_GAA(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U8_GAA(T16, T44, T50, s2l9_out_ga(T16, T43)) → APPEND21_IN_AGAA(T48, T43, T44, T49)
U9_GAA(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_GAA(T16, T44, T50, last22_in_ag(T50, T49))
U9_GAA(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → LAST22_IN_AG(T50, T49)
LAST22_IN_AG(T101, .(T99, T102)) → U3_AG(T101, T99, T102, last22_in_ag(T101, T102))
LAST22_IN_AG(T101, .(T99, T102)) → LAST22_IN_AG(T101, T102)
GOAL1_IN_GAA(0, T117, T118) → U11_GAA(T117, T118, append46_in_aa(T117, X210))
GOAL1_IN_GAA(0, T117, T118) → APPEND46_IN_AA(T117, X210)
GOAL1_IN_GAA(0, T117, T122) → U12_GAA(T117, T122, append46_in_aa(T117, T121))
U12_GAA(T117, T122, append46_out_aa(T117, T121)) → U13_GAA(T117, T122, last22_in_ag(T122, T121))
U12_GAA(T117, T122, append46_out_aa(T117, T121)) → LAST22_IN_AG(T122, T121)

The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)
GOAL1_IN_GAA(x1, x2, x3)  =  GOAL1_IN_GAA(x1)
U5_GAA(x1, x2, x3, x4)  =  U5_GAA(x4)
S2L9_IN_GA(x1, x2)  =  S2L9_IN_GA(x1)
U1_GA(x1, x2, x3, x4)  =  U1_GA(x4)
U6_GAA(x1, x2, x3, x4)  =  U6_GAA(x4)
U7_GAA(x1, x2, x3, x4)  =  U7_GAA(x4)
APPEND21_IN_AGAA(x1, x2, x3, x4)  =  APPEND21_IN_AGAA(x2)
U4_AGAA(x1, x2, x3, x4, x5)  =  U4_AGAA(x5)
APPEND25_IN_GAA(x1, x2, x3)  =  APPEND25_IN_GAA(x1)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U8_GAA(x1, x2, x3, x4)  =  U8_GAA(x4)
U9_GAA(x1, x2, x3, x4)  =  U9_GAA(x4)
U10_GAA(x1, x2, x3, x4)  =  U10_GAA(x4)
LAST22_IN_AG(x1, x2)  =  LAST22_IN_AG(x2)
U3_AG(x1, x2, x3, x4)  =  U3_AG(x4)
U11_GAA(x1, x2, x3)  =  U11_GAA(x3)
APPEND46_IN_AA(x1, x2)  =  APPEND46_IN_AA
U12_GAA(x1, x2, x3)  =  U12_GAA(x3)
U13_GAA(x1, x2, x3)  =  U13_GAA(x3)

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

(6) Obligation:

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

GOAL1_IN_GAA(s(T16), T10, T11) → U5_GAA(T16, T10, T11, s2l9_in_ga(T16, X32))
GOAL1_IN_GAA(s(T16), T10, T11) → S2L9_IN_GA(T16, X32)
S2L9_IN_GA(s(T24), .(X69, X70)) → U1_GA(T24, X69, X70, s2l9_in_ga(T24, X70))
S2L9_IN_GA(s(T24), .(X69, X70)) → S2L9_IN_GA(T24, X70)
GOAL1_IN_GAA(s(T16), T44, T45) → U6_GAA(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_GAA(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_GAA(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
U6_GAA(T16, T44, T45, s2l9_out_ga(T16, T43)) → APPEND21_IN_AGAA(X105, T43, T44, X104)
APPEND21_IN_AGAA(X141, T63, T64, .(X141, X142)) → U4_AGAA(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
APPEND21_IN_AGAA(X141, T63, T64, .(X141, X142)) → APPEND25_IN_GAA(T63, T64, X142)
APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → U2_GAA(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → APPEND25_IN_GAA(T81, T82, X165)
GOAL1_IN_GAA(s(T16), T44, T50) → U8_GAA(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_GAA(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_GAA(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U8_GAA(T16, T44, T50, s2l9_out_ga(T16, T43)) → APPEND21_IN_AGAA(T48, T43, T44, T49)
U9_GAA(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_GAA(T16, T44, T50, last22_in_ag(T50, T49))
U9_GAA(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → LAST22_IN_AG(T50, T49)
LAST22_IN_AG(T101, .(T99, T102)) → U3_AG(T101, T99, T102, last22_in_ag(T101, T102))
LAST22_IN_AG(T101, .(T99, T102)) → LAST22_IN_AG(T101, T102)
GOAL1_IN_GAA(0, T117, T118) → U11_GAA(T117, T118, append46_in_aa(T117, X210))
GOAL1_IN_GAA(0, T117, T118) → APPEND46_IN_AA(T117, X210)
GOAL1_IN_GAA(0, T117, T122) → U12_GAA(T117, T122, append46_in_aa(T117, T121))
U12_GAA(T117, T122, append46_out_aa(T117, T121)) → U13_GAA(T117, T122, last22_in_ag(T122, T121))
U12_GAA(T117, T122, append46_out_aa(T117, T121)) → LAST22_IN_AG(T122, T121)

The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)
GOAL1_IN_GAA(x1, x2, x3)  =  GOAL1_IN_GAA(x1)
U5_GAA(x1, x2, x3, x4)  =  U5_GAA(x4)
S2L9_IN_GA(x1, x2)  =  S2L9_IN_GA(x1)
U1_GA(x1, x2, x3, x4)  =  U1_GA(x4)
U6_GAA(x1, x2, x3, x4)  =  U6_GAA(x4)
U7_GAA(x1, x2, x3, x4)  =  U7_GAA(x4)
APPEND21_IN_AGAA(x1, x2, x3, x4)  =  APPEND21_IN_AGAA(x2)
U4_AGAA(x1, x2, x3, x4, x5)  =  U4_AGAA(x5)
APPEND25_IN_GAA(x1, x2, x3)  =  APPEND25_IN_GAA(x1)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U8_GAA(x1, x2, x3, x4)  =  U8_GAA(x4)
U9_GAA(x1, x2, x3, x4)  =  U9_GAA(x4)
U10_GAA(x1, x2, x3, x4)  =  U10_GAA(x4)
LAST22_IN_AG(x1, x2)  =  LAST22_IN_AG(x2)
U3_AG(x1, x2, x3, x4)  =  U3_AG(x4)
U11_GAA(x1, x2, x3)  =  U11_GAA(x3)
APPEND46_IN_AA(x1, x2)  =  APPEND46_IN_AA
U12_GAA(x1, x2, x3)  =  U12_GAA(x3)
U13_GAA(x1, x2, x3)  =  U13_GAA(x3)

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

(7) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LOPSTR] contains 3 SCCs with 20 less nodes.

(8) Complex Obligation (AND)

(9) Obligation:

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

LAST22_IN_AG(T101, .(T99, T102)) → LAST22_IN_AG(T101, T102)

The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)
LAST22_IN_AG(x1, x2)  =  LAST22_IN_AG(x2)

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

(10) UsableRulesProof (EQUIVALENT transformation)

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

(11) Obligation:

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

LAST22_IN_AG(T101, .(T99, T102)) → LAST22_IN_AG(T101, T102)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .(x2)
LAST22_IN_AG(x1, x2)  =  LAST22_IN_AG(x2)

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

(12) PiDPToQDPProof (SOUND transformation)

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

(13) Obligation:

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

LAST22_IN_AG(.(T102)) → LAST22_IN_AG(T102)

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

(14) QDPSizeChangeProof (EQUIVALENT transformation)

By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:

  • LAST22_IN_AG(.(T102)) → LAST22_IN_AG(T102)
    The graph contains the following edges 1 > 1

(15) YES

(16) Obligation:

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

APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → APPEND25_IN_GAA(T81, T82, X165)

The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)
APPEND25_IN_GAA(x1, x2, x3)  =  APPEND25_IN_GAA(x1)

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

(17) UsableRulesProof (EQUIVALENT transformation)

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

(18) Obligation:

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

APPEND25_IN_GAA(.(T78, T81), T82, .(T78, X165)) → APPEND25_IN_GAA(T81, T82, X165)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .(x2)
APPEND25_IN_GAA(x1, x2, x3)  =  APPEND25_IN_GAA(x1)

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

(19) PiDPToQDPProof (SOUND transformation)

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

(20) Obligation:

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

APPEND25_IN_GAA(.(T81)) → APPEND25_IN_GAA(T81)

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

(21) QDPSizeChangeProof (EQUIVALENT transformation)

By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:

  • APPEND25_IN_GAA(.(T81)) → APPEND25_IN_GAA(T81)
    The graph contains the following edges 1 > 1

(22) YES

(23) Obligation:

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

S2L9_IN_GA(s(T24), .(X69, X70)) → S2L9_IN_GA(T24, X70)

The TRS R consists of the following rules:

goal1_in_gaa(s(T16), T10, T11) → U5_gaa(T16, T10, T11, s2l9_in_ga(T16, X32))
s2l9_in_ga(s(T24), .(X69, X70)) → U1_ga(T24, X69, X70, s2l9_in_ga(T24, X70))
s2l9_in_ga(0, []) → s2l9_out_ga(0, [])
U1_ga(T24, X69, X70, s2l9_out_ga(T24, X70)) → s2l9_out_ga(s(T24), .(X69, X70))
U5_gaa(T16, T10, T11, s2l9_out_ga(T16, X32)) → goal1_out_gaa(s(T16), T10, T11)
goal1_in_gaa(s(T16), T44, T45) → U6_gaa(T16, T44, T45, s2l9_in_ga(T16, T43))
U6_gaa(T16, T44, T45, s2l9_out_ga(T16, T43)) → U7_gaa(T16, T44, T45, append21_in_agaa(X105, T43, T44, X104))
append21_in_agaa(X141, T63, T64, .(X141, X142)) → U4_agaa(X141, T63, T64, X142, append25_in_gaa(T63, T64, X142))
append25_in_gaa([], T71, .(T71, [])) → append25_out_gaa([], T71, .(T71, []))
append25_in_gaa(.(T78, T81), T82, .(T78, X165)) → U2_gaa(T78, T81, T82, X165, append25_in_gaa(T81, T82, X165))
U2_gaa(T78, T81, T82, X165, append25_out_gaa(T81, T82, X165)) → append25_out_gaa(.(T78, T81), T82, .(T78, X165))
U4_agaa(X141, T63, T64, X142, append25_out_gaa(T63, T64, X142)) → append21_out_agaa(X141, T63, T64, .(X141, X142))
U7_gaa(T16, T44, T45, append21_out_agaa(X105, T43, T44, X104)) → goal1_out_gaa(s(T16), T44, T45)
goal1_in_gaa(s(T16), T44, T50) → U8_gaa(T16, T44, T50, s2l9_in_ga(T16, T43))
U8_gaa(T16, T44, T50, s2l9_out_ga(T16, T43)) → U9_gaa(T16, T44, T50, append21_in_agaa(T48, T43, T44, T49))
U9_gaa(T16, T44, T50, append21_out_agaa(T48, T43, T44, T49)) → U10_gaa(T16, T44, T50, last22_in_ag(T50, T49))
last22_in_ag(T91, .(T91, [])) → last22_out_ag(T91, .(T91, []))
last22_in_ag(T101, .(T99, T102)) → U3_ag(T101, T99, T102, last22_in_ag(T101, T102))
U3_ag(T101, T99, T102, last22_out_ag(T101, T102)) → last22_out_ag(T101, .(T99, T102))
U10_gaa(T16, T44, T50, last22_out_ag(T50, T49)) → goal1_out_gaa(s(T16), T44, T50)
goal1_in_gaa(0, T117, T118) → U11_gaa(T117, T118, append46_in_aa(T117, X210))
append46_in_aa(T128, .(T128, [])) → append46_out_aa(T128, .(T128, []))
U11_gaa(T117, T118, append46_out_aa(T117, X210)) → goal1_out_gaa(0, T117, T118)
goal1_in_gaa(0, T117, T122) → U12_gaa(T117, T122, append46_in_aa(T117, T121))
U12_gaa(T117, T122, append46_out_aa(T117, T121)) → U13_gaa(T117, T122, last22_in_ag(T122, T121))
U13_gaa(T117, T122, last22_out_ag(T122, T121)) → goal1_out_gaa(0, T117, T122)

The argument filtering Pi contains the following mapping:
goal1_in_gaa(x1, x2, x3)  =  goal1_in_gaa(x1)
s(x1)  =  s(x1)
U5_gaa(x1, x2, x3, x4)  =  U5_gaa(x4)
s2l9_in_ga(x1, x2)  =  s2l9_in_ga(x1)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x4)
0  =  0
s2l9_out_ga(x1, x2)  =  s2l9_out_ga(x2)
.(x1, x2)  =  .(x2)
goal1_out_gaa(x1, x2, x3)  =  goal1_out_gaa
U6_gaa(x1, x2, x3, x4)  =  U6_gaa(x4)
U7_gaa(x1, x2, x3, x4)  =  U7_gaa(x4)
append21_in_agaa(x1, x2, x3, x4)  =  append21_in_agaa(x2)
U4_agaa(x1, x2, x3, x4, x5)  =  U4_agaa(x5)
append25_in_gaa(x1, x2, x3)  =  append25_in_gaa(x1)
[]  =  []
append25_out_gaa(x1, x2, x3)  =  append25_out_gaa(x3)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
append21_out_agaa(x1, x2, x3, x4)  =  append21_out_agaa(x4)
U8_gaa(x1, x2, x3, x4)  =  U8_gaa(x4)
U9_gaa(x1, x2, x3, x4)  =  U9_gaa(x4)
U10_gaa(x1, x2, x3, x4)  =  U10_gaa(x4)
last22_in_ag(x1, x2)  =  last22_in_ag(x2)
last22_out_ag(x1, x2)  =  last22_out_ag
U3_ag(x1, x2, x3, x4)  =  U3_ag(x4)
U11_gaa(x1, x2, x3)  =  U11_gaa(x3)
append46_in_aa(x1, x2)  =  append46_in_aa
append46_out_aa(x1, x2)  =  append46_out_aa(x2)
U12_gaa(x1, x2, x3)  =  U12_gaa(x3)
U13_gaa(x1, x2, x3)  =  U13_gaa(x3)
S2L9_IN_GA(x1, x2)  =  S2L9_IN_GA(x1)

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

(24) UsableRulesProof (EQUIVALENT transformation)

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

(25) Obligation:

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

S2L9_IN_GA(s(T24), .(X69, X70)) → S2L9_IN_GA(T24, X70)

R is empty.
The argument filtering Pi contains the following mapping:
s(x1)  =  s(x1)
.(x1, x2)  =  .(x2)
S2L9_IN_GA(x1, x2)  =  S2L9_IN_GA(x1)

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

(26) PiDPToQDPProof (SOUND transformation)

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

(27) Obligation:

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

S2L9_IN_GA(s(T24)) → S2L9_IN_GA(T24)

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

(28) QDPSizeChangeProof (EQUIVALENT transformation)

By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:

  • S2L9_IN_GA(s(T24)) → S2L9_IN_GA(T24)
    The graph contains the following edges 1 > 1

(29) YES