(0) Obligation:

Clauses:

perm1([], []).
perm1(Xs, .(X, Ys)) :- ','(select(X, Xs, Zs), perm1(Zs, Ys)).
select(X, .(X, Xs), Xs).
select(X, .(Y, Xs), .(Y, Zs)) :- select(X, Xs, Zs).

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

perm1A_in_ga([], []) → perm1A_out_ga([], [])
perm1A_in_ga(.(T27, T28), .(T27, T29)) → U1_ga(T27, T28, T29, perm1A_in_ga(T28, T29))
perm1A_in_ga(.(T37, T38), .(T39, T40)) → U2_ga(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
pB_in_agaga(T39, T38, T45, T37, T46) → U4_agaga(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))
U4_agaga(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_agaga(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U5_agaga(T39, T38, T45, T37, T46, perm1A_out_ga(.(T37, T45), T46)) → pB_out_agaga(T39, T38, T45, T37, T46)
U2_ga(T37, T38, T39, T40, pB_out_agaga(T39, T38, X45, T37, T40)) → perm1A_out_ga(.(T37, T38), .(T39, T40))
U1_ga(T27, T28, T29, perm1A_out_ga(T28, T29)) → perm1A_out_ga(.(T27, T28), .(T27, T29))

The argument filtering Pi contains the following mapping:
perm1A_in_ga(x1, x2)  =  perm1A_in_ga(x1)
[]  =  []
perm1A_out_ga(x1, x2)  =  perm1A_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x1, x2, x4)
U2_ga(x1, x2, x3, x4, x5)  =  U2_ga(x1, x2, x5)
pB_in_agaga(x1, x2, x3, x4, x5)  =  pB_in_agaga(x2, x4)
U4_agaga(x1, x2, x3, x4, x5, x6)  =  U4_agaga(x2, x4, x6)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
U5_agaga(x1, x2, x3, x4, x5, x6)  =  U5_agaga(x1, x2, x3, x4, x6)
pB_out_agaga(x1, x2, x3, x4, x5)  =  pB_out_agaga(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:

PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → U1_GA(T27, T28, T29, perm1A_in_ga(T28, T29))
PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → PERM1A_IN_GA(T28, T29)
PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → U2_GA(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → PB_IN_AGAGA(T39, T38, X45, T37, T40)
PB_IN_AGAGA(T39, T38, T45, T37, T46) → U4_AGAGA(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
PB_IN_AGAGA(T39, T38, T45, T37, T46) → SELECTC_IN_AGA(T39, T38, T45)
SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → U3_AGA(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → SELECTC_IN_AGA(T70, T69, X78)
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_AGAGA(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45), T46)

The TRS R consists of the following rules:

perm1A_in_ga([], []) → perm1A_out_ga([], [])
perm1A_in_ga(.(T27, T28), .(T27, T29)) → U1_ga(T27, T28, T29, perm1A_in_ga(T28, T29))
perm1A_in_ga(.(T37, T38), .(T39, T40)) → U2_ga(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
pB_in_agaga(T39, T38, T45, T37, T46) → U4_agaga(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))
U4_agaga(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_agaga(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U5_agaga(T39, T38, T45, T37, T46, perm1A_out_ga(.(T37, T45), T46)) → pB_out_agaga(T39, T38, T45, T37, T46)
U2_ga(T37, T38, T39, T40, pB_out_agaga(T39, T38, X45, T37, T40)) → perm1A_out_ga(.(T37, T38), .(T39, T40))
U1_ga(T27, T28, T29, perm1A_out_ga(T28, T29)) → perm1A_out_ga(.(T27, T28), .(T27, T29))

The argument filtering Pi contains the following mapping:
perm1A_in_ga(x1, x2)  =  perm1A_in_ga(x1)
[]  =  []
perm1A_out_ga(x1, x2)  =  perm1A_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x1, x2, x4)
U2_ga(x1, x2, x3, x4, x5)  =  U2_ga(x1, x2, x5)
pB_in_agaga(x1, x2, x3, x4, x5)  =  pB_in_agaga(x2, x4)
U4_agaga(x1, x2, x3, x4, x5, x6)  =  U4_agaga(x2, x4, x6)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
U5_agaga(x1, x2, x3, x4, x5, x6)  =  U5_agaga(x1, x2, x3, x4, x6)
pB_out_agaga(x1, x2, x3, x4, x5)  =  pB_out_agaga(x1, x2, x3, x4, x5)
PERM1A_IN_GA(x1, x2)  =  PERM1A_IN_GA(x1)
U1_GA(x1, x2, x3, x4)  =  U1_GA(x1, x2, x4)
U2_GA(x1, x2, x3, x4, x5)  =  U2_GA(x1, x2, x5)
PB_IN_AGAGA(x1, x2, x3, x4, x5)  =  PB_IN_AGAGA(x2, x4)
U4_AGAGA(x1, x2, x3, x4, x5, x6)  =  U4_AGAGA(x2, x4, x6)
SELECTC_IN_AGA(x1, x2, x3)  =  SELECTC_IN_AGA(x2)
U3_AGA(x1, x2, x3, x4, x5)  =  U3_AGA(x2, x3, x5)
U5_AGAGA(x1, x2, x3, x4, x5, x6)  =  U5_AGAGA(x1, x2, x3, x4, x6)

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

(4) Obligation:

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

PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → U1_GA(T27, T28, T29, perm1A_in_ga(T28, T29))
PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → PERM1A_IN_GA(T28, T29)
PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → U2_GA(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → PB_IN_AGAGA(T39, T38, X45, T37, T40)
PB_IN_AGAGA(T39, T38, T45, T37, T46) → U4_AGAGA(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
PB_IN_AGAGA(T39, T38, T45, T37, T46) → SELECTC_IN_AGA(T39, T38, T45)
SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → U3_AGA(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → SELECTC_IN_AGA(T70, T69, X78)
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_AGAGA(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45), T46)

The TRS R consists of the following rules:

perm1A_in_ga([], []) → perm1A_out_ga([], [])
perm1A_in_ga(.(T27, T28), .(T27, T29)) → U1_ga(T27, T28, T29, perm1A_in_ga(T28, T29))
perm1A_in_ga(.(T37, T38), .(T39, T40)) → U2_ga(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
pB_in_agaga(T39, T38, T45, T37, T46) → U4_agaga(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))
U4_agaga(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_agaga(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U5_agaga(T39, T38, T45, T37, T46, perm1A_out_ga(.(T37, T45), T46)) → pB_out_agaga(T39, T38, T45, T37, T46)
U2_ga(T37, T38, T39, T40, pB_out_agaga(T39, T38, X45, T37, T40)) → perm1A_out_ga(.(T37, T38), .(T39, T40))
U1_ga(T27, T28, T29, perm1A_out_ga(T28, T29)) → perm1A_out_ga(.(T27, T28), .(T27, T29))

The argument filtering Pi contains the following mapping:
perm1A_in_ga(x1, x2)  =  perm1A_in_ga(x1)
[]  =  []
perm1A_out_ga(x1, x2)  =  perm1A_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x1, x2, x4)
U2_ga(x1, x2, x3, x4, x5)  =  U2_ga(x1, x2, x5)
pB_in_agaga(x1, x2, x3, x4, x5)  =  pB_in_agaga(x2, x4)
U4_agaga(x1, x2, x3, x4, x5, x6)  =  U4_agaga(x2, x4, x6)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
U5_agaga(x1, x2, x3, x4, x5, x6)  =  U5_agaga(x1, x2, x3, x4, x6)
pB_out_agaga(x1, x2, x3, x4, x5)  =  pB_out_agaga(x1, x2, x3, x4, x5)
PERM1A_IN_GA(x1, x2)  =  PERM1A_IN_GA(x1)
U1_GA(x1, x2, x3, x4)  =  U1_GA(x1, x2, x4)
U2_GA(x1, x2, x3, x4, x5)  =  U2_GA(x1, x2, x5)
PB_IN_AGAGA(x1, x2, x3, x4, x5)  =  PB_IN_AGAGA(x2, x4)
U4_AGAGA(x1, x2, x3, x4, x5, x6)  =  U4_AGAGA(x2, x4, x6)
SELECTC_IN_AGA(x1, x2, x3)  =  SELECTC_IN_AGA(x2)
U3_AGA(x1, x2, x3, x4, x5)  =  U3_AGA(x2, x3, x5)
U5_AGAGA(x1, x2, x3, x4, x5, x6)  =  U5_AGAGA(x1, x2, x3, x4, x6)

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

(5) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LOPSTR] contains 2 SCCs with 5 less nodes.

(6) Complex Obligation (AND)

(7) Obligation:

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

SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → SELECTC_IN_AGA(T70, T69, X78)

The TRS R consists of the following rules:

perm1A_in_ga([], []) → perm1A_out_ga([], [])
perm1A_in_ga(.(T27, T28), .(T27, T29)) → U1_ga(T27, T28, T29, perm1A_in_ga(T28, T29))
perm1A_in_ga(.(T37, T38), .(T39, T40)) → U2_ga(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
pB_in_agaga(T39, T38, T45, T37, T46) → U4_agaga(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))
U4_agaga(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_agaga(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U5_agaga(T39, T38, T45, T37, T46, perm1A_out_ga(.(T37, T45), T46)) → pB_out_agaga(T39, T38, T45, T37, T46)
U2_ga(T37, T38, T39, T40, pB_out_agaga(T39, T38, X45, T37, T40)) → perm1A_out_ga(.(T37, T38), .(T39, T40))
U1_ga(T27, T28, T29, perm1A_out_ga(T28, T29)) → perm1A_out_ga(.(T27, T28), .(T27, T29))

The argument filtering Pi contains the following mapping:
perm1A_in_ga(x1, x2)  =  perm1A_in_ga(x1)
[]  =  []
perm1A_out_ga(x1, x2)  =  perm1A_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x1, x2, x4)
U2_ga(x1, x2, x3, x4, x5)  =  U2_ga(x1, x2, x5)
pB_in_agaga(x1, x2, x3, x4, x5)  =  pB_in_agaga(x2, x4)
U4_agaga(x1, x2, x3, x4, x5, x6)  =  U4_agaga(x2, x4, x6)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
U5_agaga(x1, x2, x3, x4, x5, x6)  =  U5_agaga(x1, x2, x3, x4, x6)
pB_out_agaga(x1, x2, x3, x4, x5)  =  pB_out_agaga(x1, x2, x3, x4, x5)
SELECTC_IN_AGA(x1, x2, x3)  =  SELECTC_IN_AGA(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:

SELECTC_IN_AGA(T70, .(T68, T69), .(T68, X78)) → SELECTC_IN_AGA(T70, T69, X78)

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

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

(10) PiDPToQDPProof (SOUND 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:

SELECTC_IN_AGA(.(T68, T69)) → SELECTC_IN_AGA(T69)

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:

  • SELECTC_IN_AGA(.(T68, T69)) → SELECTC_IN_AGA(T69)
    The graph contains the following edges 1 > 1

(13) YES

(14) Obligation:

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

PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → PB_IN_AGAGA(T39, T38, X45, T37, T40)
PB_IN_AGAGA(T39, T38, T45, T37, T46) → U4_AGAGA(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45), T46)
PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → PERM1A_IN_GA(T28, T29)

The TRS R consists of the following rules:

perm1A_in_ga([], []) → perm1A_out_ga([], [])
perm1A_in_ga(.(T27, T28), .(T27, T29)) → U1_ga(T27, T28, T29, perm1A_in_ga(T28, T29))
perm1A_in_ga(.(T37, T38), .(T39, T40)) → U2_ga(T37, T38, T39, T40, pB_in_agaga(T39, T38, X45, T37, T40))
pB_in_agaga(T39, T38, T45, T37, T46) → U4_agaga(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))
U4_agaga(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → U5_agaga(T39, T38, T45, T37, T46, perm1A_in_ga(.(T37, T45), T46))
U5_agaga(T39, T38, T45, T37, T46, perm1A_out_ga(.(T37, T45), T46)) → pB_out_agaga(T39, T38, T45, T37, T46)
U2_ga(T37, T38, T39, T40, pB_out_agaga(T39, T38, X45, T37, T40)) → perm1A_out_ga(.(T37, T38), .(T39, T40))
U1_ga(T27, T28, T29, perm1A_out_ga(T28, T29)) → perm1A_out_ga(.(T27, T28), .(T27, T29))

The argument filtering Pi contains the following mapping:
perm1A_in_ga(x1, x2)  =  perm1A_in_ga(x1)
[]  =  []
perm1A_out_ga(x1, x2)  =  perm1A_out_ga(x1, x2)
.(x1, x2)  =  .(x1, x2)
U1_ga(x1, x2, x3, x4)  =  U1_ga(x1, x2, x4)
U2_ga(x1, x2, x3, x4, x5)  =  U2_ga(x1, x2, x5)
pB_in_agaga(x1, x2, x3, x4, x5)  =  pB_in_agaga(x2, x4)
U4_agaga(x1, x2, x3, x4, x5, x6)  =  U4_agaga(x2, x4, x6)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
U5_agaga(x1, x2, x3, x4, x5, x6)  =  U5_agaga(x1, x2, x3, x4, x6)
pB_out_agaga(x1, x2, x3, x4, x5)  =  pB_out_agaga(x1, x2, x3, x4, x5)
PERM1A_IN_GA(x1, x2)  =  PERM1A_IN_GA(x1)
PB_IN_AGAGA(x1, x2, x3, x4, x5)  =  PB_IN_AGAGA(x2, x4)
U4_AGAGA(x1, x2, x3, x4, x5, x6)  =  U4_AGAGA(x2, x4, x6)

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:

PERM1A_IN_GA(.(T37, T38), .(T39, T40)) → PB_IN_AGAGA(T39, T38, X45, T37, T40)
PB_IN_AGAGA(T39, T38, T45, T37, T46) → U4_AGAGA(T39, T38, T45, T37, T46, selectC_in_aga(T39, T38, T45))
U4_AGAGA(T39, T38, T45, T37, T46, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45), T46)
PERM1A_IN_GA(.(T27, T28), .(T27, T29)) → PERM1A_IN_GA(T28, T29)

The TRS R consists of the following rules:

selectC_in_aga(T59, .(T59, T60), T60) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(T70, .(T68, T69), .(T68, X78)) → U3_aga(T70, T68, T69, X78, selectC_in_aga(T70, T69, X78))
U3_aga(T70, T68, T69, X78, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))

The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .(x1, x2)
selectC_in_aga(x1, x2, x3)  =  selectC_in_aga(x2)
selectC_out_aga(x1, x2, x3)  =  selectC_out_aga(x1, x2, x3)
U3_aga(x1, x2, x3, x4, x5)  =  U3_aga(x2, x3, x5)
PERM1A_IN_GA(x1, x2)  =  PERM1A_IN_GA(x1)
PB_IN_AGAGA(x1, x2, x3, x4, x5)  =  PB_IN_AGAGA(x2, x4)
U4_AGAGA(x1, x2, x3, x4, x5, x6)  =  U4_AGAGA(x2, x4, x6)

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:

PERM1A_IN_GA(.(T37, T38)) → PB_IN_AGAGA(T38, T37)
PB_IN_AGAGA(T38, T37) → U4_AGAGA(T38, T37, selectC_in_aga(T38))
U4_AGAGA(T38, T37, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45))
PERM1A_IN_GA(.(T27, T28)) → PERM1A_IN_GA(T28)

The TRS R consists of the following rules:

selectC_in_aga(.(T59, T60)) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(.(T68, T69)) → U3_aga(T68, T69, selectC_in_aga(T69))
U3_aga(T68, T69, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))

The set Q consists of the following terms:

selectC_in_aga(x0)
U3_aga(x0, x1, x2)

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

(19) QDPOrderProof (EQUIVALENT transformation)

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


The following pairs can be oriented strictly and are deleted.


PB_IN_AGAGA(T38, T37) → U4_AGAGA(T38, T37, selectC_in_aga(T38))
PERM1A_IN_GA(.(T27, T28)) → PERM1A_IN_GA(T28)
The remaining pairs can at least be oriented weakly.
Used ordering: Polynomial interpretation [POLO]:

POL(.(x1, x2)) = 1 + x2   
POL(PB_IN_AGAGA(x1, x2)) = 1 + x1   
POL(PERM1A_IN_GA(x1)) = x1   
POL(U3_aga(x1, x2, x3)) = 1 + x3   
POL(U4_AGAGA(x1, x2, x3)) = x3   
POL(selectC_in_aga(x1)) = x1   
POL(selectC_out_aga(x1, x2, x3)) = 1 + x3   

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

selectC_in_aga(.(T59, T60)) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(.(T68, T69)) → U3_aga(T68, T69, selectC_in_aga(T69))
U3_aga(T68, T69, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))

(20) Obligation:

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

PERM1A_IN_GA(.(T37, T38)) → PB_IN_AGAGA(T38, T37)
U4_AGAGA(T38, T37, selectC_out_aga(T39, T38, T45)) → PERM1A_IN_GA(.(T37, T45))

The TRS R consists of the following rules:

selectC_in_aga(.(T59, T60)) → selectC_out_aga(T59, .(T59, T60), T60)
selectC_in_aga(.(T68, T69)) → U3_aga(T68, T69, selectC_in_aga(T69))
U3_aga(T68, T69, selectC_out_aga(T70, T69, X78)) → selectC_out_aga(T70, .(T68, T69), .(T68, X78))

The set Q consists of the following terms:

selectC_in_aga(x0)
U3_aga(x0, x1, x2)

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

(21) DependencyGraphProof (EQUIVALENT transformation)

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

(22) TRUE