(0) Obligation:
Clauses:
fl([], [], 0).
fl(.(E, X), R, s(Z)) :- ','(append(E, Y, R), fl(X, Y, Z)).
append([], X, X).
append(.(X, Xs), Ys, .(X, Zs)) :- append(Xs, Ys, Zs).
Queries:
fl(a,g,a).
(1) PrologToDTProblemTransformerProof (SOUND transformation)
Built DT problem from termination graph.
(2) Obligation:
Triples:
p6([], [], .(T24, T25), s(T26)) :- p6(T24, X38, T25, T26).
append31(.(T77, T80), X128, .(T77, T79)) :- append31(T80, X128, T79).
fl1(.(T10, T11), [], s(T12)) :- p6(T10, X9, T11, T12).
fl1(.([], T45), T44, s(T46)) :- fl1(T45, T44, T46).
fl1(.(.(T53, T56), T57), .(T53, T55), s(T58)) :- append31(T56, X90, T55).
fl1(.(.(T53, T56), T62), .(T53, T55), s(T63)) :- ','(appendc31(T56, T61, T55), fl1(T62, T61, T63)).
Clauses:
qc6([], [], [], 0).
qc6([], [], .(T24, T25), s(T26)) :- qc6(T24, X38, T25, T26).
flc1([], [], 0).
flc1(.(T10, T11), [], s(T12)) :- qc6(T10, X9, T11, T12).
flc1(.([], T45), T44, s(T46)) :- flc1(T45, T44, T46).
flc1(.(.(T53, T56), T62), .(T53, T55), s(T63)) :- ','(appendc31(T56, T61, T55), flc1(T62, T61, T63)).
appendc31([], T70, T70).
appendc31(.(T77, T80), X128, .(T77, T79)) :- appendc31(T80, X128, T79).
Afs:
fl1(x1, x2, x3) = fl1(x2)
(3) TriplesToPiDPProof (SOUND transformation)
We use the technique of [LOPSTR]. With regard to the inferred argument filtering the predicates were used in the following modes:
fl1_in: (f,b,f)
p6_in: (f,f,f,f)
append31_in: (f,f,b)
appendc31_in: (f,f,b)
Transforming
TRIPLES into the following
Term Rewriting System:
Pi DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(.(T10, T11), [], s(T12)) → U3_AGA(T10, T11, T12, p6_in_aaaa(T10, X9, T11, T12))
FL1_IN_AGA(.(T10, T11), [], s(T12)) → P6_IN_AAAA(T10, X9, T11, T12)
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → U1_AAAA(T24, T25, T26, p6_in_aaaa(T24, X38, T25, T26))
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → P6_IN_AAAA(T24, X38, T25, T26)
FL1_IN_AGA(.([], T45), T44, s(T46)) → U4_AGA(T45, T44, T46, fl1_in_aga(T45, T44, T46))
FL1_IN_AGA(.([], T45), T44, s(T46)) → FL1_IN_AGA(T45, T44, T46)
FL1_IN_AGA(.(.(T53, T56), T57), .(T53, T55), s(T58)) → U5_AGA(T53, T56, T57, T55, T58, append31_in_aag(T56, X90, T55))
FL1_IN_AGA(.(.(T53, T56), T57), .(T53, T55), s(T58)) → APPEND31_IN_AAG(T56, X90, T55)
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → U2_AAG(T77, T80, X128, T79, append31_in_aag(T80, X128, T79))
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → APPEND31_IN_AAG(T80, X128, T79)
FL1_IN_AGA(.(.(T53, T56), T62), .(T53, T55), s(T63)) → U6_AGA(T53, T56, T62, T55, T63, appendc31_in_aag(T56, T61, T55))
U6_AGA(T53, T56, T62, T55, T63, appendc31_out_aag(T56, T61, T55)) → U7_AGA(T53, T56, T62, T55, T63, fl1_in_aga(T62, T61, T63))
U6_AGA(T53, T56, T62, T55, T63, appendc31_out_aag(T56, T61, T55)) → FL1_IN_AGA(T62, T61, T63)
The TRS R consists of the following rules:
appendc31_in_aag([], T70, T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T80), X128, .(T77, T79)) → U14_aag(T77, T80, X128, T79, appendc31_in_aag(T80, X128, T79))
U14_aag(T77, T80, X128, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The argument filtering Pi contains the following mapping:
fl1_in_aga(
x1,
x2,
x3) =
fl1_in_aga(
x2)
[] =
[]
p6_in_aaaa(
x1,
x2,
x3,
x4) =
p6_in_aaaa
.(
x1,
x2) =
.(
x1,
x2)
append31_in_aag(
x1,
x2,
x3) =
append31_in_aag(
x3)
appendc31_in_aag(
x1,
x2,
x3) =
appendc31_in_aag(
x3)
appendc31_out_aag(
x1,
x2,
x3) =
appendc31_out_aag(
x1,
x2,
x3)
U14_aag(
x1,
x2,
x3,
x4,
x5) =
U14_aag(
x1,
x4,
x5)
s(
x1) =
s(
x1)
FL1_IN_AGA(
x1,
x2,
x3) =
FL1_IN_AGA(
x2)
U3_AGA(
x1,
x2,
x3,
x4) =
U3_AGA(
x4)
P6_IN_AAAA(
x1,
x2,
x3,
x4) =
P6_IN_AAAA
U1_AAAA(
x1,
x2,
x3,
x4) =
U1_AAAA(
x4)
U4_AGA(
x1,
x2,
x3,
x4) =
U4_AGA(
x2,
x4)
U5_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U5_AGA(
x1,
x4,
x6)
APPEND31_IN_AAG(
x1,
x2,
x3) =
APPEND31_IN_AAG(
x3)
U2_AAG(
x1,
x2,
x3,
x4,
x5) =
U2_AAG(
x1,
x4,
x5)
U6_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U6_AGA(
x1,
x4,
x6)
U7_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U7_AGA(
x1,
x4,
x6)
We have to consider all (P,R,Pi)-chains
Infinitary Constructor Rewriting Termination of PiDP implies Termination of TRIPLES
(4) Obligation:
Pi DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(.(T10, T11), [], s(T12)) → U3_AGA(T10, T11, T12, p6_in_aaaa(T10, X9, T11, T12))
FL1_IN_AGA(.(T10, T11), [], s(T12)) → P6_IN_AAAA(T10, X9, T11, T12)
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → U1_AAAA(T24, T25, T26, p6_in_aaaa(T24, X38, T25, T26))
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → P6_IN_AAAA(T24, X38, T25, T26)
FL1_IN_AGA(.([], T45), T44, s(T46)) → U4_AGA(T45, T44, T46, fl1_in_aga(T45, T44, T46))
FL1_IN_AGA(.([], T45), T44, s(T46)) → FL1_IN_AGA(T45, T44, T46)
FL1_IN_AGA(.(.(T53, T56), T57), .(T53, T55), s(T58)) → U5_AGA(T53, T56, T57, T55, T58, append31_in_aag(T56, X90, T55))
FL1_IN_AGA(.(.(T53, T56), T57), .(T53, T55), s(T58)) → APPEND31_IN_AAG(T56, X90, T55)
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → U2_AAG(T77, T80, X128, T79, append31_in_aag(T80, X128, T79))
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → APPEND31_IN_AAG(T80, X128, T79)
FL1_IN_AGA(.(.(T53, T56), T62), .(T53, T55), s(T63)) → U6_AGA(T53, T56, T62, T55, T63, appendc31_in_aag(T56, T61, T55))
U6_AGA(T53, T56, T62, T55, T63, appendc31_out_aag(T56, T61, T55)) → U7_AGA(T53, T56, T62, T55, T63, fl1_in_aga(T62, T61, T63))
U6_AGA(T53, T56, T62, T55, T63, appendc31_out_aag(T56, T61, T55)) → FL1_IN_AGA(T62, T61, T63)
The TRS R consists of the following rules:
appendc31_in_aag([], T70, T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T80), X128, .(T77, T79)) → U14_aag(T77, T80, X128, T79, appendc31_in_aag(T80, X128, T79))
U14_aag(T77, T80, X128, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The argument filtering Pi contains the following mapping:
fl1_in_aga(
x1,
x2,
x3) =
fl1_in_aga(
x2)
[] =
[]
p6_in_aaaa(
x1,
x2,
x3,
x4) =
p6_in_aaaa
.(
x1,
x2) =
.(
x1,
x2)
append31_in_aag(
x1,
x2,
x3) =
append31_in_aag(
x3)
appendc31_in_aag(
x1,
x2,
x3) =
appendc31_in_aag(
x3)
appendc31_out_aag(
x1,
x2,
x3) =
appendc31_out_aag(
x1,
x2,
x3)
U14_aag(
x1,
x2,
x3,
x4,
x5) =
U14_aag(
x1,
x4,
x5)
s(
x1) =
s(
x1)
FL1_IN_AGA(
x1,
x2,
x3) =
FL1_IN_AGA(
x2)
U3_AGA(
x1,
x2,
x3,
x4) =
U3_AGA(
x4)
P6_IN_AAAA(
x1,
x2,
x3,
x4) =
P6_IN_AAAA
U1_AAAA(
x1,
x2,
x3,
x4) =
U1_AAAA(
x4)
U4_AGA(
x1,
x2,
x3,
x4) =
U4_AGA(
x2,
x4)
U5_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U5_AGA(
x1,
x4,
x6)
APPEND31_IN_AAG(
x1,
x2,
x3) =
APPEND31_IN_AAG(
x3)
U2_AAG(
x1,
x2,
x3,
x4,
x5) =
U2_AAG(
x1,
x4,
x5)
U6_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U6_AGA(
x1,
x4,
x6)
U7_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U7_AGA(
x1,
x4,
x6)
We have to consider all (P,R,Pi)-chains
(5) DependencyGraphProof (EQUIVALENT transformation)
The approximation of the Dependency Graph [LOPSTR] contains 3 SCCs with 8 less nodes.
(6) Complex Obligation (AND)
(7) Obligation:
Pi DP problem:
The TRS P consists of the following rules:
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → APPEND31_IN_AAG(T80, X128, T79)
The TRS R consists of the following rules:
appendc31_in_aag([], T70, T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T80), X128, .(T77, T79)) → U14_aag(T77, T80, X128, T79, appendc31_in_aag(T80, X128, T79))
U14_aag(T77, T80, X128, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The argument filtering Pi contains the following mapping:
[] =
[]
.(
x1,
x2) =
.(
x1,
x2)
appendc31_in_aag(
x1,
x2,
x3) =
appendc31_in_aag(
x3)
appendc31_out_aag(
x1,
x2,
x3) =
appendc31_out_aag(
x1,
x2,
x3)
U14_aag(
x1,
x2,
x3,
x4,
x5) =
U14_aag(
x1,
x4,
x5)
APPEND31_IN_AAG(
x1,
x2,
x3) =
APPEND31_IN_AAG(
x3)
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:
APPEND31_IN_AAG(.(T77, T80), X128, .(T77, T79)) → APPEND31_IN_AAG(T80, X128, T79)
R is empty.
The argument filtering Pi contains the following mapping:
.(
x1,
x2) =
.(
x1,
x2)
APPEND31_IN_AAG(
x1,
x2,
x3) =
APPEND31_IN_AAG(
x3)
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:
APPEND31_IN_AAG(.(T77, T79)) → APPEND31_IN_AAG(T79)
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:
- APPEND31_IN_AAG(.(T77, T79)) → APPEND31_IN_AAG(T79)
The graph contains the following edges 1 > 1
(13) YES
(14) Obligation:
Pi DP problem:
The TRS P consists of the following rules:
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → P6_IN_AAAA(T24, X38, T25, T26)
The TRS R consists of the following rules:
appendc31_in_aag([], T70, T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T80), X128, .(T77, T79)) → U14_aag(T77, T80, X128, T79, appendc31_in_aag(T80, X128, T79))
U14_aag(T77, T80, X128, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The argument filtering Pi contains the following mapping:
[] =
[]
.(
x1,
x2) =
.(
x1,
x2)
appendc31_in_aag(
x1,
x2,
x3) =
appendc31_in_aag(
x3)
appendc31_out_aag(
x1,
x2,
x3) =
appendc31_out_aag(
x1,
x2,
x3)
U14_aag(
x1,
x2,
x3,
x4,
x5) =
U14_aag(
x1,
x4,
x5)
s(
x1) =
s(
x1)
P6_IN_AAAA(
x1,
x2,
x3,
x4) =
P6_IN_AAAA
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:
P6_IN_AAAA([], [], .(T24, T25), s(T26)) → P6_IN_AAAA(T24, X38, T25, T26)
R is empty.
The argument filtering Pi contains the following mapping:
[] =
[]
.(
x1,
x2) =
.(
x1,
x2)
s(
x1) =
s(
x1)
P6_IN_AAAA(
x1,
x2,
x3,
x4) =
P6_IN_AAAA
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:
P6_IN_AAAA → P6_IN_AAAA
R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
(19) NonTerminationProof (EQUIVALENT transformation)
We used the non-termination processor [FROCOS05] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.
s =
P6_IN_AAAA evaluates to t =
P6_IN_AAAAThus s starts an infinite chain as s semiunifies with t with the following substitutions:
- Matcher: [ ]
- Semiunifier: [ ]
Rewriting sequenceThe DP semiunifies directly so there is only one rewrite step from P6_IN_AAAA to P6_IN_AAAA.
(20) NO
(21) Obligation:
Pi DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(.(.(T53, T56), T62), .(T53, T55), s(T63)) → U6_AGA(T53, T56, T62, T55, T63, appendc31_in_aag(T56, T61, T55))
U6_AGA(T53, T56, T62, T55, T63, appendc31_out_aag(T56, T61, T55)) → FL1_IN_AGA(T62, T61, T63)
FL1_IN_AGA(.([], T45), T44, s(T46)) → FL1_IN_AGA(T45, T44, T46)
The TRS R consists of the following rules:
appendc31_in_aag([], T70, T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T80), X128, .(T77, T79)) → U14_aag(T77, T80, X128, T79, appendc31_in_aag(T80, X128, T79))
U14_aag(T77, T80, X128, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The argument filtering Pi contains the following mapping:
[] =
[]
.(
x1,
x2) =
.(
x1,
x2)
appendc31_in_aag(
x1,
x2,
x3) =
appendc31_in_aag(
x3)
appendc31_out_aag(
x1,
x2,
x3) =
appendc31_out_aag(
x1,
x2,
x3)
U14_aag(
x1,
x2,
x3,
x4,
x5) =
U14_aag(
x1,
x4,
x5)
s(
x1) =
s(
x1)
FL1_IN_AGA(
x1,
x2,
x3) =
FL1_IN_AGA(
x2)
U6_AGA(
x1,
x2,
x3,
x4,
x5,
x6) =
U6_AGA(
x1,
x4,
x6)
We have to consider all (P,R,Pi)-chains
(22) PiDPToQDPProof (SOUND transformation)
Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.
(23) Obligation:
Q DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(.(T53, T55)) → U6_AGA(T53, T55, appendc31_in_aag(T55))
U6_AGA(T53, T55, appendc31_out_aag(T56, T61, T55)) → FL1_IN_AGA(T61)
FL1_IN_AGA(T44) → FL1_IN_AGA(T44)
The TRS R consists of the following rules:
appendc31_in_aag(T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T79)) → U14_aag(T77, T79, appendc31_in_aag(T79))
U14_aag(T77, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The set Q consists of the following terms:
appendc31_in_aag(x0)
U14_aag(x0, x1, x2)
We have to consider all (P,Q,R)-chains.
(24) QDPOrderProof (EQUIVALENT transformation)
We use the reduction pair processor [LPAR04].
The following pairs can be oriented strictly and are deleted.
FL1_IN_AGA(.(T53, T55)) → U6_AGA(T53, T55, appendc31_in_aag(T55))
The remaining pairs can at least be oriented weakly.
Used ordering: Polynomial interpretation [POLO]:
POL(.(x1, x2)) = 1 + x1 + x2
POL(FL1_IN_AGA(x1)) = x1
POL(U14_aag(x1, x2, x3)) = x1 + x3
POL(U6_AGA(x1, x2, x3)) = x1 + x3
POL([]) = 0
POL(appendc31_in_aag(x1)) = x1
POL(appendc31_out_aag(x1, x2, x3)) = x2
The following usable rules [FROCOS05] were oriented:
appendc31_in_aag(T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T79)) → U14_aag(T77, T79, appendc31_in_aag(T79))
U14_aag(T77, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
(25) Obligation:
Q DP problem:
The TRS P consists of the following rules:
U6_AGA(T53, T55, appendc31_out_aag(T56, T61, T55)) → FL1_IN_AGA(T61)
FL1_IN_AGA(T44) → FL1_IN_AGA(T44)
The TRS R consists of the following rules:
appendc31_in_aag(T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T79)) → U14_aag(T77, T79, appendc31_in_aag(T79))
U14_aag(T77, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The set Q consists of the following terms:
appendc31_in_aag(x0)
U14_aag(x0, x1, x2)
We have to consider all (P,Q,R)-chains.
(26) DependencyGraphProof (EQUIVALENT transformation)
The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 1 SCC with 1 less node.
(27) Obligation:
Q DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(T44) → FL1_IN_AGA(T44)
The TRS R consists of the following rules:
appendc31_in_aag(T70) → appendc31_out_aag([], T70, T70)
appendc31_in_aag(.(T77, T79)) → U14_aag(T77, T79, appendc31_in_aag(T79))
U14_aag(T77, T79, appendc31_out_aag(T80, X128, T79)) → appendc31_out_aag(.(T77, T80), X128, .(T77, T79))
The set Q consists of the following terms:
appendc31_in_aag(x0)
U14_aag(x0, x1, x2)
We have to consider all (P,Q,R)-chains.
(28) UsableRulesProof (EQUIVALENT transformation)
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [LPAR04] we can delete all non-usable rules [FROCOS05] from R.
(29) Obligation:
Q DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(T44) → FL1_IN_AGA(T44)
R is empty.
The set Q consists of the following terms:
appendc31_in_aag(x0)
U14_aag(x0, x1, x2)
We have to consider all (P,Q,R)-chains.
(30) QReductionProof (EQUIVALENT transformation)
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN].
appendc31_in_aag(x0)
U14_aag(x0, x1, x2)
(31) Obligation:
Q DP problem:
The TRS P consists of the following rules:
FL1_IN_AGA(T44) → FL1_IN_AGA(T44)
R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
(32) NonTerminationProof (EQUIVALENT transformation)
We used the non-termination processor [FROCOS05] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.
s =
FL1_IN_AGA(
T44) evaluates to t =
FL1_IN_AGA(
T44)
Thus s starts an infinite chain as s semiunifies with t with the following substitutions:
- Semiunifier: [ ]
- Matcher: [ ]
Rewriting sequenceThe DP semiunifies directly so there is only one rewrite step from FL1_IN_AGA(T44) to FL1_IN_AGA(T44).
(33) NO