9.85/4.14 YES 12.72/4.85 proof of /export/starexec/sandbox/benchmark/theBenchmark.hs 12.72/4.85 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 12.72/4.85 12.72/4.85 12.72/4.85 H-Termination with start terms of the given HASKELL could be proven: 12.72/4.85 12.72/4.85 (0) HASKELL 12.72/4.85 (1) LR [EQUIVALENT, 0 ms] 12.72/4.85 (2) HASKELL 12.72/4.85 (3) BR [EQUIVALENT, 0 ms] 12.72/4.85 (4) HASKELL 12.72/4.85 (5) COR [EQUIVALENT, 0 ms] 12.72/4.85 (6) HASKELL 12.72/4.85 (7) LetRed [EQUIVALENT, 0 ms] 12.72/4.85 (8) HASKELL 12.72/4.85 (9) NumRed [SOUND, 0 ms] 12.72/4.85 (10) HASKELL 12.72/4.85 (11) Narrow [SOUND, 0 ms] 12.72/4.85 (12) AND 12.72/4.85 (13) QDP 12.72/4.85 (14) QDPSizeChangeProof [EQUIVALENT, 0 ms] 12.72/4.85 (15) YES 12.72/4.85 (16) QDP 12.72/4.85 (17) TransformationProof [EQUIVALENT, 0 ms] 12.72/4.85 (18) QDP 12.72/4.85 (19) UsableRulesProof [EQUIVALENT, 0 ms] 12.72/4.85 (20) QDP 12.72/4.85 (21) QReductionProof [EQUIVALENT, 0 ms] 12.72/4.85 (22) QDP 12.72/4.85 (23) QDPSizeChangeProof [EQUIVALENT, 0 ms] 12.72/4.85 (24) YES 12.72/4.85 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (0) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad b => Int -> b a -> b (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (1) LR (EQUIVALENT) 12.72/4.85 Lambda Reductions: 12.72/4.85 The following Lambda expression 12.72/4.85 "\_->q" 12.72/4.85 is transformed to 12.72/4.85 "gtGt0 q _ = q; 12.72/4.85 " 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (2) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad a => Int -> a b -> a (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (3) BR (EQUIVALENT) 12.72/4.85 Replaced joker patterns by fresh variables and removed binding patterns. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (4) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad a => Int -> a b -> a (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (5) COR (EQUIVALENT) 12.72/4.85 Cond Reductions: 12.72/4.85 The following Function with conditions 12.72/4.85 "undefined |Falseundefined; 12.72/4.85 " 12.72/4.85 is transformed to 12.72/4.85 "undefined = undefined1; 12.72/4.85 " 12.72/4.85 "undefined0 True = undefined; 12.72/4.85 " 12.72/4.85 "undefined1 = undefined0 False; 12.72/4.85 " 12.72/4.85 The following Function with conditions 12.72/4.85 "take n vy|n <= 0[]; 12.72/4.85 take vz [] = []; 12.72/4.85 take n (x : xs) = x : take (n - 1) xs; 12.72/4.85 " 12.72/4.85 is transformed to 12.72/4.85 "take n vy = take3 n vy; 12.72/4.85 take vz [] = take1 vz []; 12.72/4.85 take n (x : xs) = take0 n (x : xs); 12.72/4.85 " 12.72/4.85 "take0 n (x : xs) = x : take (n - 1) xs; 12.72/4.85 " 12.72/4.85 "take1 vz [] = []; 12.72/4.85 take1 wx wy = take0 wx wy; 12.72/4.85 " 12.72/4.85 "take2 n vy True = []; 12.72/4.85 take2 n vy False = take1 n vy; 12.72/4.85 " 12.72/4.85 "take3 n vy = take2 n vy (n <= 0); 12.72/4.85 take3 wz xu = take1 wz xu; 12.72/4.85 " 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (6) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad a => Int -> a b -> a (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (7) LetRed (EQUIVALENT) 12.72/4.85 Let/Where Reductions: 12.72/4.85 The bindings of the following Let/Where expression 12.72/4.85 "xs where { 12.72/4.85 xs = x : xs; 12.72/4.85 } 12.72/4.85 " 12.72/4.85 are unpacked to the following functions on top level 12.72/4.85 "repeatXs xv = xv : repeatXs xv; 12.72/4.85 " 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (8) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad b => Int -> b a -> b (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (9) NumRed (SOUND) 12.72/4.85 Num Reduction:All numbers are transformed to their corresponding representation with Succ, Pred and Zero. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (10) 12.72/4.85 Obligation: 12.72/4.85 mainModule Main 12.72/4.85 module Maybe where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Main where { 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Monad; 12.72/4.85 import qualified Prelude; 12.72/4.85 } 12.72/4.85 module Monad where { 12.72/4.85 import qualified Main; 12.72/4.85 import qualified Maybe; 12.72/4.85 import qualified Prelude; 12.72/4.85 replicateM_ :: Monad b => Int -> b a -> b (); 12.72/4.85 replicateM_ n x = sequence_ (replicate n x); 12.72/4.85 12.72/4.85 } 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (11) Narrow (SOUND) 12.72/4.85 Haskell To QDPs 12.72/4.85 12.72/4.85 digraph dp_graph { 12.72/4.85 node [outthreshold=100, inthreshold=100];1[label="Monad.replicateM_",fontsize=16,color="grey",shape="box"];1 -> 3[label="",style="dashed", color="grey", weight=3]; 12.72/4.85 3[label="Monad.replicateM_ xw3",fontsize=16,color="grey",shape="box"];3 -> 4[label="",style="dashed", color="grey", weight=3]; 12.72/4.85 4[label="Monad.replicateM_ xw3 xw4",fontsize=16,color="black",shape="triangle"];4 -> 5[label="",style="solid", color="black", weight=3]; 12.72/4.85 5[label="sequence_ (replicate xw3 xw4)",fontsize=16,color="black",shape="box"];5 -> 6[label="",style="solid", color="black", weight=3]; 12.72/4.85 6[label="foldr (>>) (return ()) (replicate xw3 xw4)",fontsize=16,color="black",shape="box"];6 -> 7[label="",style="solid", color="black", weight=3]; 12.72/4.85 7[label="foldr (>>) (return ()) (take xw3 (repeat xw4))",fontsize=16,color="black",shape="box"];7 -> 8[label="",style="solid", color="black", weight=3]; 12.72/4.85 8[label="foldr (>>) (return ()) (take3 xw3 (repeat xw4))",fontsize=16,color="black",shape="box"];8 -> 9[label="",style="solid", color="black", weight=3]; 12.72/4.85 9[label="foldr (>>) (return ()) (take2 xw3 (repeat xw4) (xw3 <= Pos Zero))",fontsize=16,color="black",shape="box"];9 -> 10[label="",style="solid", color="black", weight=3]; 12.72/4.85 10[label="foldr (>>) (return ()) (take2 xw3 (repeat xw4) (compare xw3 (Pos Zero) /= GT))",fontsize=16,color="black",shape="box"];10 -> 11[label="",style="solid", color="black", weight=3]; 12.72/4.85 11[label="foldr (>>) (return ()) (take2 xw3 (repeat xw4) (not (compare xw3 (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];11 -> 12[label="",style="solid", color="black", weight=3]; 12.72/4.85 12[label="foldr (>>) (return ()) (take2 xw3 (repeat xw4) (not (primCmpInt xw3 (Pos Zero) == GT)))",fontsize=16,color="burlywood",shape="box"];159[label="xw3/Pos xw30",fontsize=10,color="white",style="solid",shape="box"];12 -> 159[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 159 -> 13[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 160[label="xw3/Neg xw30",fontsize=10,color="white",style="solid",shape="box"];12 -> 160[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 160 -> 14[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 13[label="foldr (>>) (return ()) (take2 (Pos xw30) (repeat xw4) (not (primCmpInt (Pos xw30) (Pos Zero) == GT)))",fontsize=16,color="burlywood",shape="box"];161[label="xw30/Succ xw300",fontsize=10,color="white",style="solid",shape="box"];13 -> 161[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 161 -> 15[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 162[label="xw30/Zero",fontsize=10,color="white",style="solid",shape="box"];13 -> 162[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 162 -> 16[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 14[label="foldr (>>) (return ()) (take2 (Neg xw30) (repeat xw4) (not (primCmpInt (Neg xw30) (Pos Zero) == GT)))",fontsize=16,color="burlywood",shape="box"];163[label="xw30/Succ xw300",fontsize=10,color="white",style="solid",shape="box"];14 -> 163[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 163 -> 17[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 164[label="xw30/Zero",fontsize=10,color="white",style="solid",shape="box"];14 -> 164[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 164 -> 18[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 15[label="foldr (>>) (return ()) (take2 (Pos (Succ xw300)) (repeat xw4) (not (primCmpInt (Pos (Succ xw300)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];15 -> 19[label="",style="solid", color="black", weight=3]; 12.72/4.85 16[label="foldr (>>) (return ()) (take2 (Pos Zero) (repeat xw4) (not (primCmpInt (Pos Zero) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];16 -> 20[label="",style="solid", color="black", weight=3]; 12.72/4.85 17[label="foldr (>>) (return ()) (take2 (Neg (Succ xw300)) (repeat xw4) (not (primCmpInt (Neg (Succ xw300)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];17 -> 21[label="",style="solid", color="black", weight=3]; 12.72/4.85 18[label="foldr (>>) (return ()) (take2 (Neg Zero) (repeat xw4) (not (primCmpInt (Neg Zero) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];18 -> 22[label="",style="solid", color="black", weight=3]; 12.72/4.85 19[label="foldr (>>) (return ()) (take2 (Pos (Succ xw300)) (repeat xw4) (not (primCmpNat (Succ xw300) Zero == GT)))",fontsize=16,color="black",shape="box"];19 -> 23[label="",style="solid", color="black", weight=3]; 12.72/4.85 20[label="foldr (>>) (return ()) (take2 (Pos Zero) (repeat xw4) (not (EQ == GT)))",fontsize=16,color="black",shape="box"];20 -> 24[label="",style="solid", color="black", weight=3]; 12.72/4.85 21[label="foldr (>>) (return ()) (take2 (Neg (Succ xw300)) (repeat xw4) (not (LT == GT)))",fontsize=16,color="black",shape="box"];21 -> 25[label="",style="solid", color="black", weight=3]; 12.72/4.85 22[label="foldr (>>) (return ()) (take2 (Neg Zero) (repeat xw4) (not (EQ == GT)))",fontsize=16,color="black",shape="box"];22 -> 26[label="",style="solid", color="black", weight=3]; 12.72/4.85 23[label="foldr (>>) (return ()) (take2 (Pos (Succ xw300)) (repeat xw4) (not (GT == GT)))",fontsize=16,color="black",shape="box"];23 -> 27[label="",style="solid", color="black", weight=3]; 12.72/4.85 24[label="foldr (>>) (return ()) (take2 (Pos Zero) (repeat xw4) (not False))",fontsize=16,color="black",shape="box"];24 -> 28[label="",style="solid", color="black", weight=3]; 12.72/4.85 25[label="foldr (>>) (return ()) (take2 (Neg (Succ xw300)) (repeat xw4) (not False))",fontsize=16,color="black",shape="box"];25 -> 29[label="",style="solid", color="black", weight=3]; 12.72/4.85 26[label="foldr (>>) (return ()) (take2 (Neg Zero) (repeat xw4) (not False))",fontsize=16,color="black",shape="box"];26 -> 30[label="",style="solid", color="black", weight=3]; 12.72/4.85 27[label="foldr (>>) (return ()) (take2 (Pos (Succ xw300)) (repeat xw4) (not True))",fontsize=16,color="black",shape="box"];27 -> 31[label="",style="solid", color="black", weight=3]; 12.72/4.85 28[label="foldr (>>) (return ()) (take2 (Pos Zero) (repeat xw4) True)",fontsize=16,color="black",shape="box"];28 -> 32[label="",style="solid", color="black", weight=3]; 12.72/4.85 29[label="foldr (>>) (return ()) (take2 (Neg (Succ xw300)) (repeat xw4) True)",fontsize=16,color="black",shape="box"];29 -> 33[label="",style="solid", color="black", weight=3]; 12.72/4.85 30[label="foldr (>>) (return ()) (take2 (Neg Zero) (repeat xw4) True)",fontsize=16,color="black",shape="box"];30 -> 34[label="",style="solid", color="black", weight=3]; 12.72/4.85 31[label="foldr (>>) (return ()) (take2 (Pos (Succ xw300)) (repeat xw4) False)",fontsize=16,color="black",shape="box"];31 -> 35[label="",style="solid", color="black", weight=3]; 12.72/4.85 32[label="foldr (>>) (return ()) []",fontsize=16,color="black",shape="triangle"];32 -> 36[label="",style="solid", color="black", weight=3]; 12.72/4.85 33 -> 32[label="",style="dashed", color="red", weight=0]; 12.72/4.85 33[label="foldr (>>) (return ()) []",fontsize=16,color="magenta"];34 -> 32[label="",style="dashed", color="red", weight=0]; 12.72/4.85 34[label="foldr (>>) (return ()) []",fontsize=16,color="magenta"];35[label="foldr (>>) (return ()) (take1 (Pos (Succ xw300)) (repeat xw4))",fontsize=16,color="black",shape="box"];35 -> 37[label="",style="solid", color="black", weight=3]; 12.72/4.85 36[label="return ()",fontsize=16,color="black",shape="triangle"];36 -> 38[label="",style="solid", color="black", weight=3]; 12.72/4.85 37 -> 39[label="",style="dashed", color="red", weight=0]; 12.72/4.85 37[label="foldr (>>) (return ()) (take1 (Pos (Succ xw300)) (repeatXs xw4))",fontsize=16,color="magenta"];37 -> 40[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 38[label="() : []",fontsize=16,color="green",shape="box"];40 -> 36[label="",style="dashed", color="red", weight=0]; 12.72/4.85 40[label="return ()",fontsize=16,color="magenta"];39[label="foldr (>>) xw5 (take1 (Pos (Succ xw300)) (repeatXs xw4))",fontsize=16,color="black",shape="triangle"];39 -> 41[label="",style="solid", color="black", weight=3]; 12.72/4.85 41[label="foldr (>>) xw5 (take1 (Pos (Succ xw300)) (xw4 : repeatXs xw4))",fontsize=16,color="black",shape="box"];41 -> 42[label="",style="solid", color="black", weight=3]; 12.72/4.85 42[label="foldr (>>) xw5 (take0 (Pos (Succ xw300)) (xw4 : repeatXs xw4))",fontsize=16,color="black",shape="box"];42 -> 43[label="",style="solid", color="black", weight=3]; 12.72/4.85 43[label="foldr (>>) xw5 (xw4 : take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs xw4))",fontsize=16,color="black",shape="box"];43 -> 44[label="",style="solid", color="black", weight=3]; 12.72/4.85 44[label="(>>) xw4 foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs xw4))",fontsize=16,color="black",shape="box"];44 -> 45[label="",style="solid", color="black", weight=3]; 12.72/4.85 45[label="xw4 >>= gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs xw4)))",fontsize=16,color="burlywood",shape="box"];165[label="xw4/xw40 : xw41",fontsize=10,color="white",style="solid",shape="box"];45 -> 165[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 165 -> 46[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 166[label="xw4/[]",fontsize=10,color="white",style="solid",shape="box"];45 -> 166[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 166 -> 47[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 46[label="xw40 : xw41 >>= gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41))))",fontsize=16,color="black",shape="box"];46 -> 48[label="",style="solid", color="black", weight=3]; 12.72/4.85 47[label="[] >>= gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs [])))",fontsize=16,color="black",shape="box"];47 -> 49[label="",style="solid", color="black", weight=3]; 12.72/4.85 48 -> 73[label="",style="dashed", color="red", weight=0]; 12.72/4.85 48[label="gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))) xw40 ++ (xw41 >>= gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))))",fontsize=16,color="magenta"];48 -> 74[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 48 -> 75[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 49[label="[]",fontsize=16,color="green",shape="box"];74[label="foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))",fontsize=16,color="black",shape="triangle"];74 -> 118[label="",style="solid", color="black", weight=3]; 12.72/4.85 75 -> 119[label="",style="dashed", color="red", weight=0]; 12.72/4.85 75[label="gtGt0 (foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))) xw40",fontsize=16,color="magenta"];75 -> 120[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 73[label="xw6 ++ (xw41 >>= gtGt0 xw7)",fontsize=16,color="burlywood",shape="triangle"];167[label="xw6/xw60 : xw61",fontsize=10,color="white",style="solid",shape="box"];73 -> 167[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 167 -> 121[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 168[label="xw6/[]",fontsize=10,color="white",style="solid",shape="box"];73 -> 168[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 168 -> 122[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 118[label="foldr (>>) xw5 (take3 (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))",fontsize=16,color="black",shape="box"];118 -> 123[label="",style="solid", color="black", weight=3]; 12.72/4.85 120 -> 74[label="",style="dashed", color="red", weight=0]; 12.72/4.85 120[label="foldr (>>) xw5 (take (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)))",fontsize=16,color="magenta"];119[label="gtGt0 xw8 xw40",fontsize=16,color="black",shape="triangle"];119 -> 124[label="",style="solid", color="black", weight=3]; 12.72/4.85 121[label="(xw60 : xw61) ++ (xw41 >>= gtGt0 xw7)",fontsize=16,color="black",shape="box"];121 -> 125[label="",style="solid", color="black", weight=3]; 12.72/4.85 122[label="[] ++ (xw41 >>= gtGt0 xw7)",fontsize=16,color="black",shape="box"];122 -> 126[label="",style="solid", color="black", weight=3]; 12.72/4.85 123[label="foldr (>>) xw5 (take2 (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)) (Pos (Succ xw300) - Pos (Succ Zero) <= Pos Zero))",fontsize=16,color="black",shape="box"];123 -> 127[label="",style="solid", color="black", weight=3]; 12.72/4.85 124[label="xw8",fontsize=16,color="green",shape="box"];125[label="xw60 : xw61 ++ (xw41 >>= gtGt0 xw7)",fontsize=16,color="green",shape="box"];125 -> 128[label="",style="dashed", color="green", weight=3]; 12.72/4.85 126[label="xw41 >>= gtGt0 xw7",fontsize=16,color="burlywood",shape="box"];169[label="xw41/xw410 : xw411",fontsize=10,color="white",style="solid",shape="box"];126 -> 169[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 169 -> 129[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 170[label="xw41/[]",fontsize=10,color="white",style="solid",shape="box"];126 -> 170[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 170 -> 130[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 127[label="foldr (>>) xw5 (take2 (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)) (compare (Pos (Succ xw300) - Pos (Succ Zero)) (Pos Zero) /= GT))",fontsize=16,color="black",shape="box"];127 -> 131[label="",style="solid", color="black", weight=3]; 12.72/4.85 128 -> 73[label="",style="dashed", color="red", weight=0]; 12.72/4.85 128[label="xw61 ++ (xw41 >>= gtGt0 xw7)",fontsize=16,color="magenta"];128 -> 132[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 129[label="xw410 : xw411 >>= gtGt0 xw7",fontsize=16,color="black",shape="box"];129 -> 133[label="",style="solid", color="black", weight=3]; 12.72/4.85 130[label="[] >>= gtGt0 xw7",fontsize=16,color="black",shape="box"];130 -> 134[label="",style="solid", color="black", weight=3]; 12.72/4.85 131[label="foldr (>>) xw5 (take2 (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)) (not (compare (Pos (Succ xw300) - Pos (Succ Zero)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];131 -> 135[label="",style="solid", color="black", weight=3]; 12.72/4.85 132[label="xw61",fontsize=16,color="green",shape="box"];133 -> 73[label="",style="dashed", color="red", weight=0]; 12.72/4.85 133[label="gtGt0 xw7 xw410 ++ (xw411 >>= gtGt0 xw7)",fontsize=16,color="magenta"];133 -> 136[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 133 -> 137[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 134[label="[]",fontsize=16,color="green",shape="box"];135[label="foldr (>>) xw5 (take2 (Pos (Succ xw300) - Pos (Succ Zero)) (repeatXs (xw40 : xw41)) (not (primCmpInt (Pos (Succ xw300) - Pos (Succ Zero)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];135 -> 138[label="",style="solid", color="black", weight=3]; 12.72/4.85 136 -> 119[label="",style="dashed", color="red", weight=0]; 12.72/4.85 136[label="gtGt0 xw7 xw410",fontsize=16,color="magenta"];136 -> 139[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 136 -> 140[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 137[label="xw411",fontsize=16,color="green",shape="box"];138[label="foldr (>>) xw5 (take2 (primMinusInt (Pos (Succ xw300)) (Pos (Succ Zero))) (repeatXs (xw40 : xw41)) (not (primCmpInt (primMinusInt (Pos (Succ xw300)) (Pos (Succ Zero))) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];138 -> 141[label="",style="solid", color="black", weight=3]; 12.72/4.85 139[label="xw7",fontsize=16,color="green",shape="box"];140[label="xw410",fontsize=16,color="green",shape="box"];141[label="foldr (>>) xw5 (take2 (primMinusNat (Succ xw300) (Succ Zero)) (repeatXs (xw40 : xw41)) (not (primCmpInt (primMinusNat (Succ xw300) (Succ Zero)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];141 -> 142[label="",style="solid", color="black", weight=3]; 12.72/4.85 142[label="foldr (>>) xw5 (take2 (primMinusNat xw300 Zero) (repeatXs (xw40 : xw41)) (not (primCmpInt (primMinusNat xw300 Zero) (Pos Zero) == GT)))",fontsize=16,color="burlywood",shape="box"];171[label="xw300/Succ xw3000",fontsize=10,color="white",style="solid",shape="box"];142 -> 171[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 171 -> 143[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 172[label="xw300/Zero",fontsize=10,color="white",style="solid",shape="box"];142 -> 172[label="",style="solid", color="burlywood", weight=9]; 12.72/4.85 172 -> 144[label="",style="solid", color="burlywood", weight=3]; 12.72/4.85 143[label="foldr (>>) xw5 (take2 (primMinusNat (Succ xw3000) Zero) (repeatXs (xw40 : xw41)) (not (primCmpInt (primMinusNat (Succ xw3000) Zero) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];143 -> 145[label="",style="solid", color="black", weight=3]; 12.72/4.85 144[label="foldr (>>) xw5 (take2 (primMinusNat Zero Zero) (repeatXs (xw40 : xw41)) (not (primCmpInt (primMinusNat Zero Zero) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];144 -> 146[label="",style="solid", color="black", weight=3]; 12.72/4.85 145[label="foldr (>>) xw5 (take2 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)) (not (primCmpInt (Pos (Succ xw3000)) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];145 -> 147[label="",style="solid", color="black", weight=3]; 12.72/4.85 146[label="foldr (>>) xw5 (take2 (Pos Zero) (repeatXs (xw40 : xw41)) (not (primCmpInt (Pos Zero) (Pos Zero) == GT)))",fontsize=16,color="black",shape="box"];146 -> 148[label="",style="solid", color="black", weight=3]; 12.72/4.85 147[label="foldr (>>) xw5 (take2 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)) (not (primCmpNat (Succ xw3000) Zero == GT)))",fontsize=16,color="black",shape="box"];147 -> 149[label="",style="solid", color="black", weight=3]; 12.72/4.85 148[label="foldr (>>) xw5 (take2 (Pos Zero) (repeatXs (xw40 : xw41)) (not (EQ == GT)))",fontsize=16,color="black",shape="box"];148 -> 150[label="",style="solid", color="black", weight=3]; 12.72/4.85 149[label="foldr (>>) xw5 (take2 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)) (not (GT == GT)))",fontsize=16,color="black",shape="box"];149 -> 151[label="",style="solid", color="black", weight=3]; 12.72/4.85 150[label="foldr (>>) xw5 (take2 (Pos Zero) (repeatXs (xw40 : xw41)) (not False))",fontsize=16,color="black",shape="box"];150 -> 152[label="",style="solid", color="black", weight=3]; 12.72/4.85 151[label="foldr (>>) xw5 (take2 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)) (not True))",fontsize=16,color="black",shape="box"];151 -> 153[label="",style="solid", color="black", weight=3]; 12.72/4.85 152[label="foldr (>>) xw5 (take2 (Pos Zero) (repeatXs (xw40 : xw41)) True)",fontsize=16,color="black",shape="box"];152 -> 154[label="",style="solid", color="black", weight=3]; 12.72/4.85 153[label="foldr (>>) xw5 (take2 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)) False)",fontsize=16,color="black",shape="box"];153 -> 155[label="",style="solid", color="black", weight=3]; 12.72/4.85 154[label="foldr (>>) xw5 []",fontsize=16,color="black",shape="box"];154 -> 156[label="",style="solid", color="black", weight=3]; 12.72/4.85 155 -> 39[label="",style="dashed", color="red", weight=0]; 12.72/4.85 155[label="foldr (>>) xw5 (take1 (Pos (Succ xw3000)) (repeatXs (xw40 : xw41)))",fontsize=16,color="magenta"];155 -> 157[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 155 -> 158[label="",style="dashed", color="magenta", weight=3]; 12.72/4.85 156[label="xw5",fontsize=16,color="green",shape="box"];157[label="xw3000",fontsize=16,color="green",shape="box"];158[label="xw40 : xw41",fontsize=16,color="green",shape="box"];} 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (12) 12.72/4.85 Complex Obligation (AND) 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (13) 12.72/4.85 Obligation: 12.72/4.85 Q DP problem: 12.72/4.85 The TRS P consists of the following rules: 12.72/4.85 12.72/4.85 new_foldr0(xw5, xw300, :(xw40, xw41), h) -> new_foldr(xw5, xw300, xw40, xw41, h) 12.72/4.85 new_foldr(xw5, Succ(xw3000), xw40, xw41, h) -> new_foldr0(xw5, xw3000, :(xw40, xw41), h) 12.72/4.85 new_foldr0(xw5, Succ(xw3000), :(xw40, xw41), h) -> new_foldr0(xw5, xw3000, :(xw40, xw41), h) 12.72/4.85 12.72/4.85 R is empty. 12.72/4.85 Q is empty. 12.72/4.85 We have to consider all minimal (P,Q,R)-chains. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (14) QDPSizeChangeProof (EQUIVALENT) 12.72/4.85 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. 12.72/4.85 12.72/4.85 From the DPs we obtained the following set of size-change graphs: 12.72/4.85 *new_foldr(xw5, Succ(xw3000), xw40, xw41, h) -> new_foldr0(xw5, xw3000, :(xw40, xw41), h) 12.72/4.85 The graph contains the following edges 1 >= 1, 2 > 2, 5 >= 4 12.72/4.85 12.72/4.85 12.72/4.85 *new_foldr0(xw5, Succ(xw3000), :(xw40, xw41), h) -> new_foldr0(xw5, xw3000, :(xw40, xw41), h) 12.72/4.85 The graph contains the following edges 1 >= 1, 2 > 2, 3 >= 3, 4 >= 4 12.72/4.85 12.72/4.85 12.72/4.85 *new_foldr0(xw5, xw300, :(xw40, xw41), h) -> new_foldr(xw5, xw300, xw40, xw41, h) 12.72/4.85 The graph contains the following edges 1 >= 1, 2 >= 2, 3 > 3, 3 > 4, 4 >= 5 12.72/4.85 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (15) 12.72/4.85 YES 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (16) 12.72/4.85 Obligation: 12.72/4.85 Q DP problem: 12.72/4.85 The TRS P consists of the following rules: 12.72/4.85 12.72/4.85 new_psPs(:(xw60, xw61), xw41, xw7, h) -> new_psPs(xw61, xw41, xw7, h) 12.72/4.85 new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(new_gtGt0(xw7, xw410, h), xw411, xw7, h) 12.72/4.85 12.72/4.85 The TRS R consists of the following rules: 12.72/4.85 12.72/4.85 new_gtGt0(xw8, xw40, h) -> xw8 12.72/4.85 12.72/4.85 The set Q consists of the following terms: 12.72/4.85 12.72/4.85 new_gtGt0(x0, x1, x2) 12.72/4.85 12.72/4.85 We have to consider all minimal (P,Q,R)-chains. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (17) TransformationProof (EQUIVALENT) 12.72/4.85 By rewriting [LPAR04] the rule new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(new_gtGt0(xw7, xw410, h), xw411, xw7, h) at position [0] we obtained the following new rules [LPAR04]: 12.72/4.85 12.72/4.85 (new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h),new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h)) 12.72/4.85 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (18) 12.72/4.85 Obligation: 12.72/4.85 Q DP problem: 12.72/4.85 The TRS P consists of the following rules: 12.72/4.85 12.72/4.85 new_psPs(:(xw60, xw61), xw41, xw7, h) -> new_psPs(xw61, xw41, xw7, h) 12.72/4.85 new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h) 12.72/4.85 12.72/4.85 The TRS R consists of the following rules: 12.72/4.85 12.72/4.85 new_gtGt0(xw8, xw40, h) -> xw8 12.72/4.85 12.72/4.85 The set Q consists of the following terms: 12.72/4.85 12.72/4.85 new_gtGt0(x0, x1, x2) 12.72/4.85 12.72/4.85 We have to consider all minimal (P,Q,R)-chains. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (19) UsableRulesProof (EQUIVALENT) 12.72/4.85 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. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (20) 12.72/4.85 Obligation: 12.72/4.85 Q DP problem: 12.72/4.85 The TRS P consists of the following rules: 12.72/4.85 12.72/4.85 new_psPs(:(xw60, xw61), xw41, xw7, h) -> new_psPs(xw61, xw41, xw7, h) 12.72/4.85 new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h) 12.72/4.85 12.72/4.85 R is empty. 12.72/4.85 The set Q consists of the following terms: 12.72/4.85 12.72/4.85 new_gtGt0(x0, x1, x2) 12.72/4.85 12.72/4.85 We have to consider all minimal (P,Q,R)-chains. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (21) QReductionProof (EQUIVALENT) 12.72/4.85 We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN]. 12.72/4.85 12.72/4.85 new_gtGt0(x0, x1, x2) 12.72/4.85 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (22) 12.72/4.85 Obligation: 12.72/4.85 Q DP problem: 12.72/4.85 The TRS P consists of the following rules: 12.72/4.85 12.72/4.85 new_psPs(:(xw60, xw61), xw41, xw7, h) -> new_psPs(xw61, xw41, xw7, h) 12.72/4.85 new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h) 12.72/4.85 12.72/4.85 R is empty. 12.72/4.85 Q is empty. 12.72/4.85 We have to consider all minimal (P,Q,R)-chains. 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (23) QDPSizeChangeProof (EQUIVALENT) 12.72/4.85 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. 12.72/4.85 12.72/4.85 From the DPs we obtained the following set of size-change graphs: 12.72/4.85 *new_psPs(:(xw60, xw61), xw41, xw7, h) -> new_psPs(xw61, xw41, xw7, h) 12.72/4.85 The graph contains the following edges 1 > 1, 2 >= 2, 3 >= 3, 4 >= 4 12.72/4.85 12.72/4.85 12.72/4.85 *new_psPs([], :(xw410, xw411), xw7, h) -> new_psPs(xw7, xw411, xw7, h) 12.72/4.85 The graph contains the following edges 3 >= 1, 2 > 2, 3 >= 3, 4 >= 4 12.72/4.85 12.72/4.85 12.72/4.85 ---------------------------------------- 12.72/4.85 12.72/4.85 (24) 12.72/4.85 YES 12.83/5.04 EOF