(0) Obligation:

Clauses:

slowsort(X, Y) :- ','(perm(X, Y), sorted(Y)).
sorted([]).
sorted(.(X, [])).
sorted(.(X, .(Y, Z))) :- ','(le(X, Y), sorted(.(Y, Z))).
perm([], []).
perm(.(X, .(Y, [])), .(U, .(V, []))) :- ','(delete(U, .(X, Y), Z), perm(Z, V)).
delete(X, .(X, Y), Y).
delete(X, .(Y, Z), W) :- delete(X, Z, W).
le(s(X), s(Y)) :- le(X, Y).
le(0, s(X)).
le(0, 0).

Query: slowsort(g,a)

(1) PrologToPiTRSViaGraphTransformerProof (SOUND transformation)

Transformed Prolog program to (Pi-)TRS.

(2) Obligation:

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

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)

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

SLOWSORTA_IN_GA(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_GA(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
SLOWSORTA_IN_GA(.(T16, .(T17, [])), .(T20, .(T21, []))) → PB_IN_AGGAA(T20, T16, T17, X22, T21)
PB_IN_AGGAA(T28, T16, T17, T26, T27) → U7_AGGAA(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
PB_IN_AGGAA(T28, T16, T17, T26, T27) → DELETED_IN_AGGA(T28, T16, T17, T26)
DELETED_IN_AGGA(T57, T55, T56, X59) → U3_AGGA(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
DELETED_IN_AGGA(T57, T55, T56, X59) → DELETEC_IN_AGA(T57, T56, X59)
DELETEC_IN_AGA(T81, .(T79, T80), X88) → U2_AGA(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
DELETEC_IN_AGA(T81, .(T79, T80), X88) → DELETEC_IN_AGA(T81, T80, X88)
U7_AGGAA(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_AGGAA(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
U7_AGGAA(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → PK_IN_GAG(T26, T27, T28)
PK_IN_GAG(T26, T86, T28) → U9_GAG(T26, T86, T28, permE_in_ga(T26, T86))
PK_IN_GAG(T26, T86, T28) → PERME_IN_GA(T26, T86)
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_GA(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → PF_IN_AGGAA(T99, T95, T96, X106, T100)
PF_IN_AGGAA(T99, T95, T96, T105, T106) → U11_AGGAA(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
PF_IN_AGGAA(T99, T95, T96, T105, T106) → DELETED_IN_AGGA(T99, T95, T96, T105)
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_AGGAA(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105, T106)
U9_GAG(T26, T86, T28, permE_out_ga(T26, T86)) → U10_GAG(T26, T86, T28, sortedH_in_gg(T28, T86))
U9_GAG(T26, T86, T28, permE_out_ga(T26, T86)) → SORTEDH_IN_GG(T28, T86)
SORTEDH_IN_GG(T118, T119) → U6_GG(T118, T119, pI_in_gg(T118, T119))
SORTEDH_IN_GG(T118, T119) → PI_IN_GG(T118, T119)
PI_IN_GG(T118, T119) → U13_GG(T118, T119, leG_in_gg(T118, T119))
PI_IN_GG(T118, T119) → LEG_IN_GG(T118, T119)
LEG_IN_GG(s(T132), s(T133)) → U5_GG(T132, T133, leG_in_gg(T132, T133))
LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)
U13_GG(T118, T119, leG_out_gg(T118, T119)) → U14_GG(T118, T119, sortedJ_in_g(T119))
U13_GG(T118, T119, leG_out_gg(T118, T119)) → SORTEDJ_IN_G(T119)

The TRS R consists of the following rules:

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)
SLOWSORTA_IN_GA(x1, x2)  =  SLOWSORTA_IN_GA(x1)
U1_GA(x1, x2, x3, x4, x5)  =  U1_GA(x1, x2, x5)
PB_IN_AGGAA(x1, x2, x3, x4, x5)  =  PB_IN_AGGAA(x2, x3)
U7_AGGAA(x1, x2, x3, x4, x5, x6)  =  U7_AGGAA(x2, x3, x6)
DELETED_IN_AGGA(x1, x2, x3, x4)  =  DELETED_IN_AGGA(x2, x3)
U3_AGGA(x1, x2, x3, x4, x5)  =  U3_AGGA(x2, x3, x5)
DELETEC_IN_AGA(x1, x2, x3)  =  DELETEC_IN_AGA(x2)
U2_AGA(x1, x2, x3, x4, x5)  =  U2_AGA(x2, x3, x5)
U8_AGGAA(x1, x2, x3, x4, x5, x6)  =  U8_AGGAA(x1, x2, x3, x4, x6)
PK_IN_GAG(x1, x2, x3)  =  PK_IN_GAG(x1, x3)
U9_GAG(x1, x2, x3, x4)  =  U9_GAG(x1, x3, x4)
PERME_IN_GA(x1, x2)  =  PERME_IN_GA(x1)
U4_GA(x1, x2, x3, x4, x5)  =  U4_GA(x1, x2, x5)
PF_IN_AGGAA(x1, x2, x3, x4, x5)  =  PF_IN_AGGAA(x2, x3)
U11_AGGAA(x1, x2, x3, x4, x5, x6)  =  U11_AGGAA(x2, x3, x6)
U12_AGGAA(x1, x2, x3, x4, x5, x6)  =  U12_AGGAA(x1, x2, x3, x4, x6)
U10_GAG(x1, x2, x3, x4)  =  U10_GAG(x1, x2, x3, x4)
SORTEDH_IN_GG(x1, x2)  =  SORTEDH_IN_GG(x1, x2)
U6_GG(x1, x2, x3)  =  U6_GG(x1, x2, x3)
PI_IN_GG(x1, x2)  =  PI_IN_GG(x1, x2)
U13_GG(x1, x2, x3)  =  U13_GG(x1, x2, x3)
LEG_IN_GG(x1, x2)  =  LEG_IN_GG(x1, x2)
U5_GG(x1, x2, x3)  =  U5_GG(x1, x2, x3)
U14_GG(x1, x2, x3)  =  U14_GG(x1, x2, x3)
SORTEDJ_IN_G(x1)  =  SORTEDJ_IN_G(x1)

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

(4) Obligation:

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

SLOWSORTA_IN_GA(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_GA(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
SLOWSORTA_IN_GA(.(T16, .(T17, [])), .(T20, .(T21, []))) → PB_IN_AGGAA(T20, T16, T17, X22, T21)
PB_IN_AGGAA(T28, T16, T17, T26, T27) → U7_AGGAA(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
PB_IN_AGGAA(T28, T16, T17, T26, T27) → DELETED_IN_AGGA(T28, T16, T17, T26)
DELETED_IN_AGGA(T57, T55, T56, X59) → U3_AGGA(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
DELETED_IN_AGGA(T57, T55, T56, X59) → DELETEC_IN_AGA(T57, T56, X59)
DELETEC_IN_AGA(T81, .(T79, T80), X88) → U2_AGA(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
DELETEC_IN_AGA(T81, .(T79, T80), X88) → DELETEC_IN_AGA(T81, T80, X88)
U7_AGGAA(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_AGGAA(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
U7_AGGAA(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → PK_IN_GAG(T26, T27, T28)
PK_IN_GAG(T26, T86, T28) → U9_GAG(T26, T86, T28, permE_in_ga(T26, T86))
PK_IN_GAG(T26, T86, T28) → PERME_IN_GA(T26, T86)
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_GA(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → PF_IN_AGGAA(T99, T95, T96, X106, T100)
PF_IN_AGGAA(T99, T95, T96, T105, T106) → U11_AGGAA(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
PF_IN_AGGAA(T99, T95, T96, T105, T106) → DELETED_IN_AGGA(T99, T95, T96, T105)
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_AGGAA(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105, T106)
U9_GAG(T26, T86, T28, permE_out_ga(T26, T86)) → U10_GAG(T26, T86, T28, sortedH_in_gg(T28, T86))
U9_GAG(T26, T86, T28, permE_out_ga(T26, T86)) → SORTEDH_IN_GG(T28, T86)
SORTEDH_IN_GG(T118, T119) → U6_GG(T118, T119, pI_in_gg(T118, T119))
SORTEDH_IN_GG(T118, T119) → PI_IN_GG(T118, T119)
PI_IN_GG(T118, T119) → U13_GG(T118, T119, leG_in_gg(T118, T119))
PI_IN_GG(T118, T119) → LEG_IN_GG(T118, T119)
LEG_IN_GG(s(T132), s(T133)) → U5_GG(T132, T133, leG_in_gg(T132, T133))
LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)
U13_GG(T118, T119, leG_out_gg(T118, T119)) → U14_GG(T118, T119, sortedJ_in_g(T119))
U13_GG(T118, T119, leG_out_gg(T118, T119)) → SORTEDJ_IN_G(T119)

The TRS R consists of the following rules:

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)
SLOWSORTA_IN_GA(x1, x2)  =  SLOWSORTA_IN_GA(x1)
U1_GA(x1, x2, x3, x4, x5)  =  U1_GA(x1, x2, x5)
PB_IN_AGGAA(x1, x2, x3, x4, x5)  =  PB_IN_AGGAA(x2, x3)
U7_AGGAA(x1, x2, x3, x4, x5, x6)  =  U7_AGGAA(x2, x3, x6)
DELETED_IN_AGGA(x1, x2, x3, x4)  =  DELETED_IN_AGGA(x2, x3)
U3_AGGA(x1, x2, x3, x4, x5)  =  U3_AGGA(x2, x3, x5)
DELETEC_IN_AGA(x1, x2, x3)  =  DELETEC_IN_AGA(x2)
U2_AGA(x1, x2, x3, x4, x5)  =  U2_AGA(x2, x3, x5)
U8_AGGAA(x1, x2, x3, x4, x5, x6)  =  U8_AGGAA(x1, x2, x3, x4, x6)
PK_IN_GAG(x1, x2, x3)  =  PK_IN_GAG(x1, x3)
U9_GAG(x1, x2, x3, x4)  =  U9_GAG(x1, x3, x4)
PERME_IN_GA(x1, x2)  =  PERME_IN_GA(x1)
U4_GA(x1, x2, x3, x4, x5)  =  U4_GA(x1, x2, x5)
PF_IN_AGGAA(x1, x2, x3, x4, x5)  =  PF_IN_AGGAA(x2, x3)
U11_AGGAA(x1, x2, x3, x4, x5, x6)  =  U11_AGGAA(x2, x3, x6)
U12_AGGAA(x1, x2, x3, x4, x5, x6)  =  U12_AGGAA(x1, x2, x3, x4, x6)
U10_GAG(x1, x2, x3, x4)  =  U10_GAG(x1, x2, x3, x4)
SORTEDH_IN_GG(x1, x2)  =  SORTEDH_IN_GG(x1, x2)
U6_GG(x1, x2, x3)  =  U6_GG(x1, x2, x3)
PI_IN_GG(x1, x2)  =  PI_IN_GG(x1, x2)
U13_GG(x1, x2, x3)  =  U13_GG(x1, x2, x3)
LEG_IN_GG(x1, x2)  =  LEG_IN_GG(x1, x2)
U5_GG(x1, x2, x3)  =  U5_GG(x1, x2, x3)
U14_GG(x1, x2, x3)  =  U14_GG(x1, x2, x3)
SORTEDJ_IN_G(x1)  =  SORTEDJ_IN_G(x1)

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

(5) DependencyGraphProof (EQUIVALENT transformation)

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

(6) Complex Obligation (AND)

(7) Obligation:

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

LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)

The TRS R consists of the following rules:

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)
LEG_IN_GG(x1, x2)  =  LEG_IN_GG(x1, x2)

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

(8) UsableRulesProof (EQUIVALENT transformation)

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

(9) Obligation:

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

LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)

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

(10) PiDPToQDPProof (EQUIVALENT transformation)

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

(11) Obligation:

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

LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)

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

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

  • LEG_IN_GG(s(T132), s(T133)) → LEG_IN_GG(T132, T133)
    The graph contains the following edges 1 > 1, 2 > 2

(13) YES

(14) Obligation:

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

DELETEC_IN_AGA(T81, .(T79, T80), X88) → DELETEC_IN_AGA(T81, T80, X88)

The TRS R consists of the following rules:

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)
DELETEC_IN_AGA(x1, x2, x3)  =  DELETEC_IN_AGA(x2)

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

(15) UsableRulesProof (EQUIVALENT transformation)

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

(16) Obligation:

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

DELETEC_IN_AGA(T81, .(T79, T80), X88) → DELETEC_IN_AGA(T81, T80, X88)

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

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

(17) PiDPToQDPProof (SOUND transformation)

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

(18) Obligation:

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

DELETEC_IN_AGA(.(T79, T80)) → DELETEC_IN_AGA(T80)

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

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

  • DELETEC_IN_AGA(.(T79, T80)) → DELETEC_IN_AGA(T80)
    The graph contains the following edges 1 > 1

(20) YES

(21) Obligation:

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

PF_IN_AGGAA(T99, T95, T96, T105, T106) → U11_AGGAA(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105, T106)
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → PF_IN_AGGAA(T99, T95, T96, X106, T100)

The TRS R consists of the following rules:

slowsortA_in_ga([], []) → slowsortA_out_ga([], [])
slowsortA_in_ga(.(T16, .(T17, [])), .(T20, .(T21, []))) → U1_ga(T16, T17, T20, T21, pB_in_aggaa(T20, T16, T17, X22, T21))
pB_in_aggaa(T28, T16, T17, T26, T27) → U7_aggaa(T28, T16, T17, T26, T27, deleteD_in_agga(T28, T16, T17, T26))
deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U7_aggaa(T28, T16, T17, T26, T27, deleteD_out_agga(T28, T16, T17, T26)) → U8_aggaa(T28, T16, T17, T26, T27, pK_in_gag(T26, T27, T28))
pK_in_gag(T26, T86, T28) → U9_gag(T26, T86, T28, permE_in_ga(T26, T86))
permE_in_ga([], []) → permE_out_ga([], [])
permE_in_ga(.(T95, .(T96, [])), .(T99, .(T100, []))) → U4_ga(T95, T96, T99, T100, pF_in_aggaa(T99, T95, T96, X106, T100))
pF_in_aggaa(T99, T95, T96, T105, T106) → U11_aggaa(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_aggaa(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → U12_aggaa(T99, T95, T96, T105, T106, permE_in_ga(T105, T106))
U12_aggaa(T99, T95, T96, T105, T106, permE_out_ga(T105, T106)) → pF_out_aggaa(T99, T95, T96, T105, T106)
U4_ga(T95, T96, T99, T100, pF_out_aggaa(T99, T95, T96, X106, T100)) → permE_out_ga(.(T95, .(T96, [])), .(T99, .(T100, [])))
U9_gag(T26, T86, T28, permE_out_ga(T26, T86)) → U10_gag(T26, T86, T28, sortedH_in_gg(T28, T86))
sortedH_in_gg(T118, T119) → U6_gg(T118, T119, pI_in_gg(T118, T119))
pI_in_gg(T118, T119) → U13_gg(T118, T119, leG_in_gg(T118, T119))
leG_in_gg(s(T132), s(T133)) → U5_gg(T132, T133, leG_in_gg(T132, T133))
leG_in_gg(0, s(T140)) → leG_out_gg(0, s(T140))
leG_in_gg(0, 0) → leG_out_gg(0, 0)
U5_gg(T132, T133, leG_out_gg(T132, T133)) → leG_out_gg(s(T132), s(T133))
U13_gg(T118, T119, leG_out_gg(T118, T119)) → U14_gg(T118, T119, sortedJ_in_g(T119))
sortedJ_in_g(T145) → sortedJ_out_g(T145)
U14_gg(T118, T119, sortedJ_out_g(T119)) → pI_out_gg(T118, T119)
U6_gg(T118, T119, pI_out_gg(T118, T119)) → sortedH_out_gg(T118, T119)
U10_gag(T26, T86, T28, sortedH_out_gg(T28, T86)) → pK_out_gag(T26, T86, T28)
U8_aggaa(T28, T16, T17, T26, T27, pK_out_gag(T26, T27, T28)) → pB_out_aggaa(T28, T16, T17, T26, T27)
U1_ga(T16, T17, T20, T21, pB_out_aggaa(T20, T16, T17, X22, T21)) → slowsortA_out_ga(.(T16, .(T17, [])), .(T20, .(T21, [])))

The argument filtering Pi contains the following mapping:
slowsortA_in_ga(x1, x2)  =  slowsortA_in_ga(x1)
[]  =  []
slowsortA_out_ga(x1, x2)  =  slowsortA_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4, x5)  =  U1_ga(x1, x2, x5)
pB_in_aggaa(x1, x2, x3, x4, x5)  =  pB_in_aggaa(x2, x3)
U7_aggaa(x1, x2, x3, x4, x5, x6)  =  U7_aggaa(x2, x3, x6)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
U8_aggaa(x1, x2, x3, x4, x5, x6)  =  U8_aggaa(x1, x2, x3, x4, x6)
pK_in_gag(x1, x2, x3)  =  pK_in_gag(x1, x3)
U9_gag(x1, x2, x3, x4)  =  U9_gag(x1, x3, x4)
permE_in_ga(x1, x2)  =  permE_in_ga(x1)
permE_out_ga(x1, x2)  =  permE_out_ga(x1, x2)
U4_ga(x1, x2, x3, x4, x5)  =  U4_ga(x1, x2, x5)
pF_in_aggaa(x1, x2, x3, x4, x5)  =  pF_in_aggaa(x2, x3)
U11_aggaa(x1, x2, x3, x4, x5, x6)  =  U11_aggaa(x2, x3, x6)
U12_aggaa(x1, x2, x3, x4, x5, x6)  =  U12_aggaa(x1, x2, x3, x4, x6)
pF_out_aggaa(x1, x2, x3, x4, x5)  =  pF_out_aggaa(x1, x2, x3, x4, x5)
U10_gag(x1, x2, x3, x4)  =  U10_gag(x1, x2, x3, x4)
sortedH_in_gg(x1, x2)  =  sortedH_in_gg(x1, x2)
U6_gg(x1, x2, x3)  =  U6_gg(x1, x2, x3)
pI_in_gg(x1, x2)  =  pI_in_gg(x1, x2)
U13_gg(x1, x2, x3)  =  U13_gg(x1, x2, x3)
leG_in_gg(x1, x2)  =  leG_in_gg(x1, x2)
s(x1)  =  s(x1)
U5_gg(x1, x2, x3)  =  U5_gg(x1, x2, x3)
0  =  0
leG_out_gg(x1, x2)  =  leG_out_gg(x1, x2)
U14_gg(x1, x2, x3)  =  U14_gg(x1, x2, x3)
sortedJ_in_g(x1)  =  sortedJ_in_g(x1)
sortedJ_out_g(x1)  =  sortedJ_out_g(x1)
pI_out_gg(x1, x2)  =  pI_out_gg(x1, x2)
sortedH_out_gg(x1, x2)  =  sortedH_out_gg(x1, x2)
pK_out_gag(x1, x2, x3)  =  pK_out_gag(x1, x2, x3)
pB_out_aggaa(x1, x2, x3, x4, x5)  =  pB_out_aggaa(x1, x2, x3, x4, x5)
PERME_IN_GA(x1, x2)  =  PERME_IN_GA(x1)
PF_IN_AGGAA(x1, x2, x3, x4, x5)  =  PF_IN_AGGAA(x2, x3)
U11_AGGAA(x1, x2, x3, x4, x5, x6)  =  U11_AGGAA(x2, x3, x6)

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

(22) UsableRulesProof (EQUIVALENT transformation)

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

(23) Obligation:

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

PF_IN_AGGAA(T99, T95, T96, T105, T106) → U11_AGGAA(T99, T95, T96, T105, T106, deleteD_in_agga(T99, T95, T96, T105))
U11_AGGAA(T99, T95, T96, T105, T106, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105, T106)
PERME_IN_GA(.(T95, .(T96, [])), .(T99, .(T100, []))) → PF_IN_AGGAA(T99, T95, T96, X106, T100)

The TRS R consists of the following rules:

deleteD_in_agga(T41, T41, T42, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T57, T55, T56, X59) → U3_agga(T57, T55, T56, X59, deleteC_in_aga(T57, T56, X59))
U3_agga(T57, T55, T56, X59, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
deleteC_in_aga(T70, .(T70, T71), T71) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(T81, .(T79, T80), X88) → U2_aga(T81, T79, T80, X88, deleteC_in_aga(T81, T80, X88))
U2_aga(T81, T79, T80, X88, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)

The argument filtering Pi contains the following mapping:
[]  =  []
.(x1, x2)  =  .(x1, x2)
deleteD_in_agga(x1, x2, x3, x4)  =  deleteD_in_agga(x2, x3)
deleteD_out_agga(x1, x2, x3, x4)  =  deleteD_out_agga(x1, x2, x3, x4)
U3_agga(x1, x2, x3, x4, x5)  =  U3_agga(x2, x3, x5)
deleteC_in_aga(x1, x2, x3)  =  deleteC_in_aga(x2)
deleteC_out_aga(x1, x2, x3)  =  deleteC_out_aga(x1, x2, x3)
U2_aga(x1, x2, x3, x4, x5)  =  U2_aga(x2, x3, x5)
PERME_IN_GA(x1, x2)  =  PERME_IN_GA(x1)
PF_IN_AGGAA(x1, x2, x3, x4, x5)  =  PF_IN_AGGAA(x2, x3)
U11_AGGAA(x1, x2, x3, x4, x5, x6)  =  U11_AGGAA(x2, x3, x6)

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

(24) PiDPToQDPProof (SOUND transformation)

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

(25) Obligation:

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

PF_IN_AGGAA(T95, T96) → U11_AGGAA(T95, T96, deleteD_in_agga(T95, T96))
U11_AGGAA(T95, T96, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105)
PERME_IN_GA(.(T95, .(T96, []))) → PF_IN_AGGAA(T95, T96)

The TRS R consists of the following rules:

deleteD_in_agga(T41, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T55, T56) → U3_agga(T55, T56, deleteC_in_aga(T56))
U3_agga(T55, T56, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
deleteC_in_aga(.(T70, T71)) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(.(T79, T80)) → U2_aga(T79, T80, deleteC_in_aga(T80))
U2_aga(T79, T80, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)

The set Q consists of the following terms:

deleteD_in_agga(x0, x1)
U3_agga(x0, x1, x2)
deleteC_in_aga(x0)
U2_aga(x0, x1, x2)

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

(26) QDPOrderProof (EQUIVALENT transformation)

We use the reduction pair processor [LPAR04,JAR06].


The following pairs can be oriented strictly and are deleted.


PERME_IN_GA(.(T95, .(T96, []))) → PF_IN_AGGAA(T95, T96)
The remaining pairs can at least be oriented weakly.
Used ordering: Polynomial interpretation [POLO]:

POL(.(x1, x2)) = 1 + x1 + x2   
POL(PERME_IN_GA(x1)) = x1   
POL(PF_IN_AGGAA(x1, x2)) = x2   
POL(U11_AGGAA(x1, x2, x3)) = x3   
POL(U2_aga(x1, x2, x3)) = x3   
POL(U3_agga(x1, x2, x3)) = x3   
POL([]) = 1   
POL(deleteC_in_aga(x1)) = x1   
POL(deleteC_out_aga(x1, x2, x3)) = x3   
POL(deleteD_in_agga(x1, x2)) = x2   
POL(deleteD_out_agga(x1, x2, x3, x4)) = x4   

The following usable rules [FROCOS05] with respect to the argument filtering of the ordering [JAR06] were oriented:

deleteD_in_agga(T41, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T55, T56) → U3_agga(T55, T56, deleteC_in_aga(T56))
deleteC_in_aga(.(T70, T71)) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(.(T79, T80)) → U2_aga(T79, T80, deleteC_in_aga(T80))
U3_agga(T55, T56, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
U2_aga(T79, T80, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)

(27) Obligation:

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

PF_IN_AGGAA(T95, T96) → U11_AGGAA(T95, T96, deleteD_in_agga(T95, T96))
U11_AGGAA(T95, T96, deleteD_out_agga(T99, T95, T96, T105)) → PERME_IN_GA(T105)

The TRS R consists of the following rules:

deleteD_in_agga(T41, T42) → deleteD_out_agga(T41, T41, T42, T42)
deleteD_in_agga(T55, T56) → U3_agga(T55, T56, deleteC_in_aga(T56))
U3_agga(T55, T56, deleteC_out_aga(T57, T56, X59)) → deleteD_out_agga(T57, T55, T56, X59)
deleteC_in_aga(.(T70, T71)) → deleteC_out_aga(T70, .(T70, T71), T71)
deleteC_in_aga(.(T79, T80)) → U2_aga(T79, T80, deleteC_in_aga(T80))
U2_aga(T79, T80, deleteC_out_aga(T81, T80, X88)) → deleteC_out_aga(T81, .(T79, T80), X88)

The set Q consists of the following terms:

deleteD_in_agga(x0, x1)
U3_agga(x0, x1, x2)
deleteC_in_aga(x0)
U2_aga(x0, x1, x2)

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

(28) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 0 SCCs with 2 less nodes.

(29) TRUE