/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.pl /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- YES proof of /export/starexec/sandbox/benchmark/theBenchmark.pl # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty Left Termination of the query pattern fold(g,g,a) w.r.t. the given Prolog program could successfully be proven: (0) Prolog (1) PrologToDTProblemTransformerProof [SOUND, 0 ms] (2) TRIPLES (3) TriplesToPiDPProof [SOUND, 2 ms] (4) PiDP (5) DependencyGraphProof [EQUIVALENT, 0 ms] (6) TRUE ---------------------------------------- (0) Obligation: Clauses: fold(X, .(Y, Ys), Z) :- ','(myop(X, Y, V), fold(V, Ys, Z)). fold(X, [], X). myop(a, b, c). Query: fold(g,g,a) ---------------------------------------- (1) PrologToDTProblemTransformerProof (SOUND) Built DT problem from termination graph DT10. { "root": 1, "program": { "directives": [], "clauses": [ [ "(fold X (. Y Ys) Z)", "(',' (myop X Y V) (fold V Ys Z))" ], [ "(fold X ([]) X)", null ], [ "(myop (a) (b) (c))", null ] ] }, "graph": { "nodes": { "23": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (myop T8 T9 X9) (fold X9 T10 T12))" }, { "clause": 1, "scope": 1, "term": "(fold T8 (. T9 T10) T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T8", "T9", "T10" ], "free": ["X9"], "exprvars": [] } }, "24": { "goal": [{ "clause": 1, "scope": 1, "term": "(fold T1 T2 T3)" }], "kb": { "nonunifying": [[ "(fold T1 T2 T3)", "(fold X5 (. X6 X7) X8)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [ "X5", "X6", "X7", "X8" ], "exprvars": [] } }, "26": { "goal": [ { "clause": 2, "scope": 2, "term": "(',' (myop T8 T9 X9) (fold X9 T10 T12))" }, { "clause": -1, "scope": 2, "term": null }, { "clause": 1, "scope": 1, "term": "(fold T8 (. T9 T10) T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T8", "T9", "T10" ], "free": ["X9"], "exprvars": [] } }, "27": { "goal": [{ "clause": 2, "scope": 2, "term": "(',' (myop T8 T9 X9) (fold X9 T10 T12))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T8", "T9", "T10" ], "free": ["X9"], "exprvars": [] } }, "28": { "goal": [ { "clause": -1, "scope": 2, "term": null }, { "clause": 1, "scope": 1, "term": "(fold T8 (. T9 T10) T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T8", "T9", "T10" ], "free": [], "exprvars": [] } }, "160": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "type": "Nodes", "161": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "162": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "163": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "1": { "goal": [{ "clause": -1, "scope": -1, "term": "(fold T1 T2 T3)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "3": { "goal": [ { "clause": 0, "scope": 1, "term": "(fold T1 T2 T3)" }, { "clause": 1, "scope": 1, "term": "(fold T1 T2 T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "103": { "goal": [{ "clause": 1, "scope": 1, "term": "(fold T8 (. T9 T10) T3)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T8", "T9", "T10" ], "free": [], "exprvars": [] } }, "31": { "goal": [{ "clause": -1, "scope": -1, "term": "(fold (c) T10 T12)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T10"], "free": [], "exprvars": [] } }, "32": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } } }, "edges": [ { "from": 1, "to": 3, "label": "CASE" }, { "from": 3, "to": 23, "label": "EVAL with clause\nfold(X5, .(X6, X7), X8) :- ','(myop(X5, X6, X9), fold(X9, X7, X8)).\nand substitutionT1 -> T8,\nX5 -> T8,\nX6 -> T9,\nX7 -> T10,\nT2 -> .(T9, T10),\nT3 -> T12,\nX8 -> T12,\nT11 -> T12" }, { "from": 3, "to": 24, "label": "EVAL-BACKTRACK" }, { "from": 23, "to": 26, "label": "CASE" }, { "from": 24, "to": 161, "label": "EVAL with clause\nfold(X17, [], X17).\nand substitutionT1 -> T18,\nX17 -> T18,\nT2 -> [],\nT3 -> T18" }, { "from": 24, "to": 162, "label": "EVAL-BACKTRACK" }, { "from": 26, "to": 27, "label": "PARALLEL" }, { "from": 26, "to": 28, "label": "PARALLEL" }, { "from": 27, "to": 31, "label": "EVAL with clause\nmyop(a, b, c).\nand substitutionT8 -> a,\nT9 -> b,\nX9 -> c" }, { "from": 27, "to": 32, "label": "EVAL-BACKTRACK" }, { "from": 28, "to": 103, "label": "FAILURE" }, { "from": 31, "to": 1, "label": "INSTANCE with matching:\nT1 -> c\nT2 -> T10\nT3 -> T12" }, { "from": 103, "to": 160, "label": "BACKTRACK\nfor clause: fold(X, [], X)because of non-unification" }, { "from": 161, "to": 163, "label": "SUCCESS" } ], "type": "Graph" } } ---------------------------------------- (2) Obligation: Triples: foldA(a, .(b, X1), X2) :- foldA(c, X1, X2). Clauses: foldcA(a, .(b, X1), X2) :- foldcA(c, X1, X2). foldcA(X1, [], X1). Afs: foldA(x1, x2, x3) = foldA(x1, x2) ---------------------------------------- (3) TriplesToPiDPProof (SOUND) We use the technique of [DT09]. With regard to the inferred argument filtering the predicates were used in the following modes: foldA_in_3: (b,b,f) Transforming TRIPLES into the following Term Rewriting System: Pi DP problem: The TRS P consists of the following rules: FOLDA_IN_GGA(a, .(b, X1), X2) -> U1_GGA(X1, X2, foldA_in_gga(c, X1, X2)) FOLDA_IN_GGA(a, .(b, X1), X2) -> FOLDA_IN_GGA(c, X1, X2) R is empty. The argument filtering Pi contains the following mapping: foldA_in_gga(x1, x2, x3) = foldA_in_gga(x1, x2) a = a .(x1, x2) = .(x1, x2) b = b c = c FOLDA_IN_GGA(x1, x2, x3) = FOLDA_IN_GGA(x1, x2) U1_GGA(x1, x2, x3) = U1_GGA(x1, x3) 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: FOLDA_IN_GGA(a, .(b, X1), X2) -> U1_GGA(X1, X2, foldA_in_gga(c, X1, X2)) FOLDA_IN_GGA(a, .(b, X1), X2) -> FOLDA_IN_GGA(c, X1, X2) R is empty. The argument filtering Pi contains the following mapping: foldA_in_gga(x1, x2, x3) = foldA_in_gga(x1, x2) a = a .(x1, x2) = .(x1, x2) b = b c = c FOLDA_IN_GGA(x1, x2, x3) = FOLDA_IN_GGA(x1, x2) U1_GGA(x1, x2, x3) = U1_GGA(x1, x3) We have to consider all (P,R,Pi)-chains ---------------------------------------- (5) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 0 SCCs with 2 less nodes. ---------------------------------------- (6) TRUE