/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.hs /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- YES proof of /export/starexec/sandbox/benchmark/theBenchmark.hs # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty H-Termination with start terms of the given HASKELL could be proven: (0) HASKELL (1) BR [EQUIVALENT, 0 ms] (2) HASKELL (3) COR [EQUIVALENT, 0 ms] (4) HASKELL (5) Narrow [SOUND, 0 ms] (6) AND (7) QDP (8) QDPSizeChangeProof [EQUIVALENT, 0 ms] (9) YES (10) QDP (11) QDPSizeChangeProof [EQUIVALENT, 0 ms] (12) YES (13) QDP (14) QDPSizeChangeProof [EQUIVALENT, 0 ms] (15) YES ---------------------------------------- (0) Obligation: mainModule Main module Main where { import qualified Prelude; data List a = Cons a (List a) | Nil ; gtGtEsNil :: List b -> (b -> List a) -> List a; gtGtEsNil (Cons x xs) f = psPs (f x) (gtGtEsNil xs f); gtGtEsNil Nil f = Nil; psPs :: List a -> List a -> List a; psPs Nil ys = ys; psPs (Cons x xs) ys = Cons x (psPs xs ys); returnNil :: a -> List a; returnNil x = Cons x Nil; sequence Nil = returnNil Nil; sequence (Cons c cs) = gtGtEsNil c (sequence1 cs); sequence0 x xs = returnNil (Cons x xs); sequence1 cs x = gtGtEsNil (sequence cs) (sequence0 x); } ---------------------------------------- (1) BR (EQUIVALENT) Replaced joker patterns by fresh variables and removed binding patterns. ---------------------------------------- (2) Obligation: mainModule Main module Main where { import qualified Prelude; data List a = Cons a (List a) | Nil ; gtGtEsNil :: List a -> (a -> List b) -> List b; gtGtEsNil (Cons x xs) f = psPs (f x) (gtGtEsNil xs f); gtGtEsNil Nil f = Nil; psPs :: List a -> List a -> List a; psPs Nil ys = ys; psPs (Cons x xs) ys = Cons x (psPs xs ys); returnNil :: a -> List a; returnNil x = Cons x Nil; sequence Nil = returnNil Nil; sequence (Cons c cs) = gtGtEsNil c (sequence1 cs); sequence0 x xs = returnNil (Cons x xs); sequence1 cs x = gtGtEsNil (sequence cs) (sequence0 x); } ---------------------------------------- (3) COR (EQUIVALENT) Cond Reductions: The following Function with conditions "undefined |Falseundefined; " is transformed to "undefined = undefined1; " "undefined0 True = undefined; " "undefined1 = undefined0 False; " ---------------------------------------- (4) Obligation: mainModule Main module Main where { import qualified Prelude; data List a = Cons a (List a) | Nil ; gtGtEsNil :: List a -> (a -> List b) -> List b; gtGtEsNil (Cons x xs) f = psPs (f x) (gtGtEsNil xs f); gtGtEsNil Nil f = Nil; psPs :: List a -> List a -> List a; psPs Nil ys = ys; psPs (Cons x xs) ys = Cons x (psPs xs ys); returnNil :: a -> List a; returnNil x = Cons x Nil; sequence Nil = returnNil Nil; sequence (Cons c cs) = gtGtEsNil c (sequence1 cs); sequence0 x xs = returnNil (Cons x xs); sequence1 cs x = gtGtEsNil (sequence cs) (sequence0 x); } ---------------------------------------- (5) Narrow (SOUND) Haskell To QDPs digraph dp_graph { node [outthreshold=100, inthreshold=100];1[label="sequence",fontsize=16,color="grey",shape="box"];1 -> 3[label="",style="dashed", color="grey", weight=3]; 3[label="sequence vx3",fontsize=16,color="burlywood",shape="triangle"];48[label="vx3/Cons vx30 vx31",fontsize=10,color="white",style="solid",shape="box"];3 -> 48[label="",style="solid", color="burlywood", weight=9]; 48 -> 4[label="",style="solid", color="burlywood", weight=3]; 49[label="vx3/Nil",fontsize=10,color="white",style="solid",shape="box"];3 -> 49[label="",style="solid", color="burlywood", weight=9]; 49 -> 5[label="",style="solid", color="burlywood", weight=3]; 4[label="sequence (Cons vx30 vx31)",fontsize=16,color="black",shape="box"];4 -> 6[label="",style="solid", color="black", weight=3]; 5[label="sequence Nil",fontsize=16,color="black",shape="box"];5 -> 7[label="",style="solid", color="black", weight=3]; 6[label="gtGtEsNil vx30 (sequence1 vx31)",fontsize=16,color="burlywood",shape="triangle"];50[label="vx30/Cons vx300 vx301",fontsize=10,color="white",style="solid",shape="box"];6 -> 50[label="",style="solid", color="burlywood", weight=9]; 50 -> 8[label="",style="solid", color="burlywood", weight=3]; 51[label="vx30/Nil",fontsize=10,color="white",style="solid",shape="box"];6 -> 51[label="",style="solid", color="burlywood", weight=9]; 51 -> 9[label="",style="solid", color="burlywood", weight=3]; 7[label="returnNil Nil",fontsize=16,color="black",shape="box"];7 -> 10[label="",style="solid", color="black", weight=3]; 8[label="gtGtEsNil (Cons vx300 vx301) (sequence1 vx31)",fontsize=16,color="black",shape="box"];8 -> 11[label="",style="solid", color="black", weight=3]; 9[label="gtGtEsNil Nil (sequence1 vx31)",fontsize=16,color="black",shape="box"];9 -> 12[label="",style="solid", color="black", weight=3]; 10[label="Cons Nil Nil",fontsize=16,color="green",shape="box"];11 -> 13[label="",style="dashed", color="red", weight=0]; 11[label="psPs (sequence1 vx31 vx300) (gtGtEsNil vx301 (sequence1 vx31))",fontsize=16,color="magenta"];11 -> 14[label="",style="dashed", color="magenta", weight=3]; 12[label="Nil",fontsize=16,color="green",shape="box"];14 -> 6[label="",style="dashed", color="red", weight=0]; 14[label="gtGtEsNil vx301 (sequence1 vx31)",fontsize=16,color="magenta"];14 -> 15[label="",style="dashed", color="magenta", weight=3]; 13[label="psPs (sequence1 vx31 vx300) vx4",fontsize=16,color="black",shape="triangle"];13 -> 16[label="",style="solid", color="black", weight=3]; 15[label="vx301",fontsize=16,color="green",shape="box"];16 -> 17[label="",style="dashed", color="red", weight=0]; 16[label="psPs (gtGtEsNil (sequence vx31) (sequence0 vx300)) vx4",fontsize=16,color="magenta"];16 -> 18[label="",style="dashed", color="magenta", weight=3]; 18 -> 3[label="",style="dashed", color="red", weight=0]; 18[label="sequence vx31",fontsize=16,color="magenta"];18 -> 19[label="",style="dashed", color="magenta", weight=3]; 17[label="psPs (gtGtEsNil vx5 (sequence0 vx300)) vx4",fontsize=16,color="burlywood",shape="triangle"];52[label="vx5/Cons vx50 vx51",fontsize=10,color="white",style="solid",shape="box"];17 -> 52[label="",style="solid", color="burlywood", weight=9]; 52 -> 20[label="",style="solid", color="burlywood", weight=3]; 53[label="vx5/Nil",fontsize=10,color="white",style="solid",shape="box"];17 -> 53[label="",style="solid", color="burlywood", weight=9]; 53 -> 21[label="",style="solid", color="burlywood", weight=3]; 19[label="vx31",fontsize=16,color="green",shape="box"];20[label="psPs (gtGtEsNil (Cons vx50 vx51) (sequence0 vx300)) vx4",fontsize=16,color="black",shape="box"];20 -> 22[label="",style="solid", color="black", weight=3]; 21[label="psPs (gtGtEsNil Nil (sequence0 vx300)) vx4",fontsize=16,color="black",shape="box"];21 -> 23[label="",style="solid", color="black", weight=3]; 22[label="psPs (psPs (sequence0 vx300 vx50) (gtGtEsNil vx51 (sequence0 vx300))) vx4",fontsize=16,color="black",shape="box"];22 -> 24[label="",style="solid", color="black", weight=3]; 23[label="psPs Nil vx4",fontsize=16,color="black",shape="triangle"];23 -> 25[label="",style="solid", color="black", weight=3]; 24[label="psPs (psPs (returnNil (Cons vx300 vx50)) (gtGtEsNil vx51 (sequence0 vx300))) vx4",fontsize=16,color="black",shape="box"];24 -> 26[label="",style="solid", color="black", weight=3]; 25[label="vx4",fontsize=16,color="green",shape="box"];26[label="psPs (psPs (Cons (Cons vx300 vx50) Nil) (gtGtEsNil vx51 (sequence0 vx300))) vx4",fontsize=16,color="black",shape="box"];26 -> 27[label="",style="solid", color="black", weight=3]; 27 -> 28[label="",style="dashed", color="red", weight=0]; 27[label="psPs (Cons (Cons vx300 vx50) (psPs Nil (gtGtEsNil vx51 (sequence0 vx300)))) vx4",fontsize=16,color="magenta"];27 -> 29[label="",style="dashed", color="magenta", weight=3]; 29 -> 23[label="",style="dashed", color="red", weight=0]; 29[label="psPs Nil (gtGtEsNil vx51 (sequence0 vx300))",fontsize=16,color="magenta"];29 -> 30[label="",style="dashed", color="magenta", weight=3]; 28[label="psPs (Cons (Cons vx300 vx50) vx6) vx4",fontsize=16,color="black",shape="triangle"];28 -> 31[label="",style="solid", color="black", weight=3]; 30[label="gtGtEsNil vx51 (sequence0 vx300)",fontsize=16,color="burlywood",shape="triangle"];54[label="vx51/Cons vx510 vx511",fontsize=10,color="white",style="solid",shape="box"];30 -> 54[label="",style="solid", color="burlywood", weight=9]; 54 -> 32[label="",style="solid", color="burlywood", weight=3]; 55[label="vx51/Nil",fontsize=10,color="white",style="solid",shape="box"];30 -> 55[label="",style="solid", color="burlywood", weight=9]; 55 -> 33[label="",style="solid", color="burlywood", weight=3]; 31[label="Cons (Cons vx300 vx50) (psPs vx6 vx4)",fontsize=16,color="green",shape="box"];31 -> 34[label="",style="dashed", color="green", weight=3]; 32[label="gtGtEsNil (Cons vx510 vx511) (sequence0 vx300)",fontsize=16,color="black",shape="box"];32 -> 35[label="",style="solid", color="black", weight=3]; 33[label="gtGtEsNil Nil (sequence0 vx300)",fontsize=16,color="black",shape="box"];33 -> 36[label="",style="solid", color="black", weight=3]; 34[label="psPs vx6 vx4",fontsize=16,color="burlywood",shape="triangle"];56[label="vx6/Cons vx60 vx61",fontsize=10,color="white",style="solid",shape="box"];34 -> 56[label="",style="solid", color="burlywood", weight=9]; 56 -> 37[label="",style="solid", color="burlywood", weight=3]; 57[label="vx6/Nil",fontsize=10,color="white",style="solid",shape="box"];34 -> 57[label="",style="solid", color="burlywood", weight=9]; 57 -> 38[label="",style="solid", color="burlywood", weight=3]; 35 -> 34[label="",style="dashed", color="red", weight=0]; 35[label="psPs (sequence0 vx300 vx510) (gtGtEsNil vx511 (sequence0 vx300))",fontsize=16,color="magenta"];35 -> 39[label="",style="dashed", color="magenta", weight=3]; 35 -> 40[label="",style="dashed", color="magenta", weight=3]; 36[label="Nil",fontsize=16,color="green",shape="box"];37[label="psPs (Cons vx60 vx61) vx4",fontsize=16,color="black",shape="box"];37 -> 41[label="",style="solid", color="black", weight=3]; 38[label="psPs Nil vx4",fontsize=16,color="black",shape="box"];38 -> 42[label="",style="solid", color="black", weight=3]; 39 -> 30[label="",style="dashed", color="red", weight=0]; 39[label="gtGtEsNil vx511 (sequence0 vx300)",fontsize=16,color="magenta"];39 -> 43[label="",style="dashed", color="magenta", weight=3]; 40[label="sequence0 vx300 vx510",fontsize=16,color="black",shape="box"];40 -> 44[label="",style="solid", color="black", weight=3]; 41[label="Cons vx60 (psPs vx61 vx4)",fontsize=16,color="green",shape="box"];41 -> 45[label="",style="dashed", color="green", weight=3]; 42[label="vx4",fontsize=16,color="green",shape="box"];43[label="vx511",fontsize=16,color="green",shape="box"];44[label="returnNil (Cons vx300 vx510)",fontsize=16,color="black",shape="box"];44 -> 46[label="",style="solid", color="black", weight=3]; 45 -> 34[label="",style="dashed", color="red", weight=0]; 45[label="psPs vx61 vx4",fontsize=16,color="magenta"];45 -> 47[label="",style="dashed", color="magenta", weight=3]; 46[label="Cons (Cons vx300 vx510) Nil",fontsize=16,color="green",shape="box"];47[label="vx61",fontsize=16,color="green",shape="box"];} ---------------------------------------- (6) Complex Obligation (AND) ---------------------------------------- (7) Obligation: Q DP problem: The TRS P consists of the following rules: new_psPs(Cons(vx60, vx61), vx4, h) -> new_psPs(vx61, vx4, h) R is empty. Q is empty. We have to consider all minimal (P,Q,R)-chains. ---------------------------------------- (8) QDPSizeChangeProof (EQUIVALENT) 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: *new_psPs(Cons(vx60, vx61), vx4, h) -> new_psPs(vx61, vx4, h) The graph contains the following edges 1 > 1, 2 >= 2, 3 >= 3 ---------------------------------------- (9) YES ---------------------------------------- (10) Obligation: Q DP problem: The TRS P consists of the following rules: new_sequence(Cons(Cons(vx300, vx301), vx31), h) -> new_gtGtEsNil0(vx301, vx31, h) new_gtGtEsNil0(Cons(vx300, vx301), vx31, h) -> new_psPs0(vx31, vx300, new_gtGtEsNil1(vx301, vx31, h), h) new_sequence(Cons(Cons(vx300, vx301), vx31), h) -> new_psPs0(vx31, vx300, new_gtGtEsNil1(vx301, vx31, h), h) new_gtGtEsNil0(Cons(vx300, vx301), vx31, h) -> new_gtGtEsNil0(vx301, vx31, h) new_psPs0(vx31, vx300, vx4, h) -> new_sequence(vx31, h) The TRS R consists of the following rules: new_psPs5(Nil, vx4, h) -> vx4 new_gtGtEsNil2(Nil, vx300, h) -> Nil new_sequence0(Cons(vx30, vx31), h) -> new_gtGtEsNil1(vx30, vx31, h) new_gtGtEsNil1(Cons(vx300, vx301), vx31, h) -> new_psPs2(vx31, vx300, new_gtGtEsNil1(vx301, vx31, h), h) new_sequence0(Nil, h) -> Cons(Nil, Nil) new_psPs1(vx4, h) -> vx4 new_psPs2(vx31, vx300, vx4, h) -> new_psPs3(new_sequence0(vx31, h), vx300, vx4, h) new_psPs3(Cons(vx50, vx51), vx300, vx4, h) -> new_psPs4(vx300, vx50, new_psPs1(new_gtGtEsNil2(vx51, vx300, h), h), vx4, h) new_psPs4(vx300, vx50, vx6, vx4, h) -> Cons(Cons(vx300, vx50), new_psPs5(vx6, vx4, h)) new_psPs3(Nil, vx300, vx4, h) -> new_psPs1(vx4, h) new_gtGtEsNil1(Nil, vx31, h) -> Nil new_gtGtEsNil2(Cons(vx510, vx511), vx300, h) -> new_psPs5(Cons(Cons(vx300, vx510), Nil), new_gtGtEsNil2(vx511, vx300, h), h) new_psPs5(Cons(vx60, vx61), vx4, h) -> Cons(vx60, new_psPs5(vx61, vx4, h)) The set Q consists of the following terms: new_gtGtEsNil2(Nil, x0, x1) new_psPs5(Nil, x0, x1) new_psPs1(x0, x1) new_gtGtEsNil1(Cons(x0, x1), x2, x3) new_psPs2(x0, x1, x2, x3) new_sequence0(Cons(x0, x1), x2) new_psPs3(Cons(x0, x1), x2, x3, x4) new_psPs4(x0, x1, x2, x3, x4) new_psPs5(Cons(x0, x1), x2, x3) new_sequence0(Nil, x0) new_psPs3(Nil, x0, x1, x2) new_gtGtEsNil2(Cons(x0, x1), x2, x3) new_gtGtEsNil1(Nil, x0, x1) We have to consider all minimal (P,Q,R)-chains. ---------------------------------------- (11) QDPSizeChangeProof (EQUIVALENT) 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: *new_psPs0(vx31, vx300, vx4, h) -> new_sequence(vx31, h) The graph contains the following edges 1 >= 1, 4 >= 2 *new_gtGtEsNil0(Cons(vx300, vx301), vx31, h) -> new_gtGtEsNil0(vx301, vx31, h) The graph contains the following edges 1 > 1, 2 >= 2, 3 >= 3 *new_gtGtEsNil0(Cons(vx300, vx301), vx31, h) -> new_psPs0(vx31, vx300, new_gtGtEsNil1(vx301, vx31, h), h) The graph contains the following edges 2 >= 1, 1 > 2, 3 >= 4 *new_sequence(Cons(Cons(vx300, vx301), vx31), h) -> new_gtGtEsNil0(vx301, vx31, h) The graph contains the following edges 1 > 1, 1 > 2, 2 >= 3 *new_sequence(Cons(Cons(vx300, vx301), vx31), h) -> new_psPs0(vx31, vx300, new_gtGtEsNil1(vx301, vx31, h), h) The graph contains the following edges 1 > 1, 1 > 2, 2 >= 4 ---------------------------------------- (12) YES ---------------------------------------- (13) Obligation: Q DP problem: The TRS P consists of the following rules: new_gtGtEsNil(Cons(vx510, vx511), vx300, h) -> new_gtGtEsNil(vx511, vx300, h) R is empty. Q is empty. We have to consider all minimal (P,Q,R)-chains. ---------------------------------------- (14) QDPSizeChangeProof (EQUIVALENT) 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: *new_gtGtEsNil(Cons(vx510, vx511), vx300, h) -> new_gtGtEsNil(vx511, vx300, h) The graph contains the following edges 1 > 1, 2 >= 2, 3 >= 3 ---------------------------------------- (15) YES