7.56/3.53 YES 9.35/4.05 proof of /export/starexec/sandbox/benchmark/theBenchmark.hs 9.35/4.05 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 9.35/4.05 9.35/4.05 9.35/4.05 H-Termination with start terms of the given HASKELL could be proven: 9.35/4.05 9.35/4.05 (0) HASKELL 9.35/4.05 (1) BR [EQUIVALENT, 0 ms] 9.35/4.05 (2) HASKELL 9.35/4.05 (3) COR [EQUIVALENT, 0 ms] 9.35/4.05 (4) HASKELL 9.35/4.05 (5) Narrow [SOUND, 0 ms] 9.35/4.05 (6) AND 9.35/4.05 (7) QDP 9.35/4.05 (8) QDPSizeChangeProof [EQUIVALENT, 0 ms] 9.35/4.05 (9) YES 9.35/4.05 (10) QDP 9.35/4.05 (11) QDPSizeChangeProof [EQUIVALENT, 0 ms] 9.35/4.05 (12) YES 9.35/4.05 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (0) 9.35/4.05 Obligation: 9.35/4.05 mainModule Main 9.35/4.05 module Main where { 9.35/4.05 import qualified Prelude; 9.35/4.05 data Main.Char = Char MyInt ; 9.35/4.05 9.35/4.05 data List a = Cons a (List a) | Nil ; 9.35/4.05 9.35/4.05 data MyInt = Pos Main.Nat | Neg Main.Nat ; 9.35/4.05 9.35/4.05 data Main.Nat = Succ Main.Nat | Zero ; 9.35/4.05 9.35/4.05 psPs :: List a -> List a -> List a; 9.35/4.05 psPs Nil ys = ys; 9.35/4.05 psPs (Cons x xs) ys = Cons x (psPs xs ys); 9.35/4.05 9.35/4.05 unwords :: List (List Main.Char) -> List Main.Char; 9.35/4.05 unwords Nil = Nil; 9.35/4.05 unwords (Cons w Nil) = w; 9.35/4.05 unwords (Cons w ws) = psPs w (Cons (Main.Char (Main.Pos (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ Main.Zero)))))))))))))))))))))))))))))))))) (unwords ws)); 9.35/4.05 9.35/4.05 } 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (1) BR (EQUIVALENT) 9.35/4.05 Replaced joker patterns by fresh variables and removed binding patterns. 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (2) 9.35/4.05 Obligation: 9.35/4.05 mainModule Main 9.35/4.05 module Main where { 9.35/4.05 import qualified Prelude; 9.35/4.05 data Main.Char = Char MyInt ; 9.35/4.05 9.35/4.05 data List a = Cons a (List a) | Nil ; 9.35/4.05 9.35/4.05 data MyInt = Pos Main.Nat | Neg Main.Nat ; 9.35/4.05 9.35/4.05 data Main.Nat = Succ Main.Nat | Zero ; 9.35/4.05 9.35/4.05 psPs :: List a -> List a -> List a; 9.35/4.05 psPs Nil ys = ys; 9.35/4.05 psPs (Cons x xs) ys = Cons x (psPs xs ys); 9.35/4.05 9.35/4.05 unwords :: List (List Main.Char) -> List Main.Char; 9.35/4.05 unwords Nil = Nil; 9.35/4.05 unwords (Cons w Nil) = w; 9.35/4.05 unwords (Cons w ws) = psPs w (Cons (Main.Char (Main.Pos (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ Main.Zero)))))))))))))))))))))))))))))))))) (unwords ws)); 9.35/4.05 9.35/4.05 } 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (3) COR (EQUIVALENT) 9.35/4.05 Cond Reductions: 9.35/4.05 The following Function with conditions 9.35/4.05 "undefined |Falseundefined; 9.35/4.05 " 9.35/4.05 is transformed to 9.35/4.05 "undefined = undefined1; 9.35/4.05 " 9.35/4.05 "undefined0 True = undefined; 9.35/4.05 " 9.35/4.05 "undefined1 = undefined0 False; 9.35/4.05 " 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (4) 9.35/4.05 Obligation: 9.35/4.05 mainModule Main 9.35/4.05 module Main where { 9.35/4.05 import qualified Prelude; 9.35/4.05 data Main.Char = Char MyInt ; 9.35/4.05 9.35/4.05 data List a = Cons a (List a) | Nil ; 9.35/4.05 9.35/4.05 data MyInt = Pos Main.Nat | Neg Main.Nat ; 9.35/4.05 9.35/4.05 data Main.Nat = Succ Main.Nat | Zero ; 9.35/4.05 9.35/4.05 psPs :: List a -> List a -> List a; 9.35/4.05 psPs Nil ys = ys; 9.35/4.05 psPs (Cons x xs) ys = Cons x (psPs xs ys); 9.35/4.05 9.35/4.05 unwords :: List (List Main.Char) -> List Main.Char; 9.35/4.05 unwords Nil = Nil; 9.35/4.05 unwords (Cons w Nil) = w; 9.35/4.05 unwords (Cons w ws) = psPs w (Cons (Main.Char (Main.Pos (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ (Main.Succ Main.Zero)))))))))))))))))))))))))))))))))) (unwords ws)); 9.35/4.05 9.35/4.05 } 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (5) Narrow (SOUND) 9.35/4.05 Haskell To QDPs 9.35/4.05 9.35/4.05 digraph dp_graph { 9.35/4.05 node [outthreshold=100, inthreshold=100];1[label="unwords",fontsize=16,color="grey",shape="box"];1 -> 3[label="",style="dashed", color="grey", weight=3]; 9.35/4.05 3[label="unwords vx3",fontsize=16,color="burlywood",shape="triangle"];28[label="vx3/Cons vx30 vx31",fontsize=10,color="white",style="solid",shape="box"];3 -> 28[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 28 -> 4[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 29[label="vx3/Nil",fontsize=10,color="white",style="solid",shape="box"];3 -> 29[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 29 -> 5[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 4[label="unwords (Cons vx30 vx31)",fontsize=16,color="burlywood",shape="box"];30[label="vx31/Cons vx310 vx311",fontsize=10,color="white",style="solid",shape="box"];4 -> 30[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 30 -> 6[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 31[label="vx31/Nil",fontsize=10,color="white",style="solid",shape="box"];4 -> 31[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 31 -> 7[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 5[label="unwords Nil",fontsize=16,color="black",shape="box"];5 -> 8[label="",style="solid", color="black", weight=3]; 9.35/4.05 6[label="unwords (Cons vx30 (Cons vx310 vx311))",fontsize=16,color="black",shape="box"];6 -> 9[label="",style="solid", color="black", weight=3]; 9.35/4.05 7[label="unwords (Cons vx30 Nil)",fontsize=16,color="black",shape="box"];7 -> 10[label="",style="solid", color="black", weight=3]; 9.35/4.05 8[label="Nil",fontsize=16,color="green",shape="box"];9 -> 16[label="",style="dashed", color="red", weight=0]; 9.35/4.05 9[label="psPs vx30 (Cons (Char (Pos (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ Zero)))))))))))))))))))))))))))))))))) (unwords (Cons vx310 vx311)))",fontsize=16,color="magenta"];9 -> 17[label="",style="dashed", color="magenta", weight=3]; 9.35/4.05 9 -> 18[label="",style="dashed", color="magenta", weight=3]; 9.35/4.05 9 -> 19[label="",style="dashed", color="magenta", weight=3]; 9.35/4.05 10[label="vx30",fontsize=16,color="green",shape="box"];17[label="Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ (Succ Zero))))))))))))))))))))))))))))))",fontsize=16,color="green",shape="box"];18[label="vx30",fontsize=16,color="green",shape="box"];19 -> 3[label="",style="dashed", color="red", weight=0]; 9.35/4.05 19[label="unwords (Cons vx310 vx311)",fontsize=16,color="magenta"];19 -> 21[label="",style="dashed", color="magenta", weight=3]; 9.35/4.05 16[label="psPs vx5 (Cons (Char (Pos (Succ vx6))) vx9)",fontsize=16,color="burlywood",shape="triangle"];32[label="vx5/Cons vx50 vx51",fontsize=10,color="white",style="solid",shape="box"];16 -> 32[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 32 -> 22[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 33[label="vx5/Nil",fontsize=10,color="white",style="solid",shape="box"];16 -> 33[label="",style="solid", color="burlywood", weight=9]; 9.35/4.05 33 -> 23[label="",style="solid", color="burlywood", weight=3]; 9.35/4.05 21[label="Cons vx310 vx311",fontsize=16,color="green",shape="box"];22[label="psPs (Cons vx50 vx51) (Cons (Char (Pos (Succ vx6))) vx9)",fontsize=16,color="black",shape="box"];22 -> 24[label="",style="solid", color="black", weight=3]; 9.35/4.05 23[label="psPs Nil (Cons (Char (Pos (Succ vx6))) vx9)",fontsize=16,color="black",shape="box"];23 -> 25[label="",style="solid", color="black", weight=3]; 9.35/4.05 24[label="Cons vx50 (psPs vx51 (Cons (Char (Pos (Succ vx6))) vx9))",fontsize=16,color="green",shape="box"];24 -> 26[label="",style="dashed", color="green", weight=3]; 9.35/4.05 25[label="Cons (Char (Pos (Succ vx6))) vx9",fontsize=16,color="green",shape="box"];26 -> 16[label="",style="dashed", color="red", weight=0]; 9.35/4.05 26[label="psPs vx51 (Cons (Char (Pos (Succ vx6))) vx9)",fontsize=16,color="magenta"];26 -> 27[label="",style="dashed", color="magenta", weight=3]; 9.35/4.05 27[label="vx51",fontsize=16,color="green",shape="box"];} 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (6) 9.35/4.05 Complex Obligation (AND) 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (7) 9.35/4.05 Obligation: 9.35/4.05 Q DP problem: 9.35/4.05 The TRS P consists of the following rules: 9.35/4.05 9.35/4.05 new_psPs(Cons(vx50, vx51), vx6, vx9) -> new_psPs(vx51, vx6, vx9) 9.35/4.05 9.35/4.05 R is empty. 9.35/4.05 Q is empty. 9.35/4.05 We have to consider all minimal (P,Q,R)-chains. 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (8) QDPSizeChangeProof (EQUIVALENT) 9.35/4.05 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. 9.35/4.05 9.35/4.05 From the DPs we obtained the following set of size-change graphs: 9.35/4.05 *new_psPs(Cons(vx50, vx51), vx6, vx9) -> new_psPs(vx51, vx6, vx9) 9.35/4.05 The graph contains the following edges 1 > 1, 2 >= 2, 3 >= 3 9.35/4.05 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (9) 9.35/4.05 YES 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (10) 9.35/4.05 Obligation: 9.35/4.05 Q DP problem: 9.35/4.05 The TRS P consists of the following rules: 9.35/4.05 9.35/4.05 new_unwords(Cons(vx30, Cons(vx310, vx311))) -> new_unwords(Cons(vx310, vx311)) 9.35/4.05 9.35/4.05 R is empty. 9.35/4.05 Q is empty. 9.35/4.05 We have to consider all minimal (P,Q,R)-chains. 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (11) QDPSizeChangeProof (EQUIVALENT) 9.35/4.05 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. 9.35/4.05 9.35/4.05 From the DPs we obtained the following set of size-change graphs: 9.35/4.05 *new_unwords(Cons(vx30, Cons(vx310, vx311))) -> new_unwords(Cons(vx310, vx311)) 9.35/4.05 The graph contains the following edges 1 > 1 9.35/4.05 9.35/4.05 9.35/4.05 ---------------------------------------- 9.35/4.05 9.35/4.05 (12) 9.35/4.05 YES 9.76/4.14 EOF