/export/starexec/sandbox2/solver/bin/starexec_run_standard /export/starexec/sandbox2/benchmark/theBenchmark.pl /export/starexec/sandbox2/output/output_files -------------------------------------------------------------------------------- YES proof of /export/starexec/sandbox2/benchmark/theBenchmark.pl # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty Left Termination of the query pattern num(g) w.r.t. the given Prolog program could successfully be proven: (0) Prolog (1) PrologToIRSwTTransformerProof [SOUND, 0 ms] (2) TRUE ---------------------------------------- (0) Obligation: Clauses: num(0). num(X) :- ','(no(zero(0)), ','(p(X, Y), num(Y))). p(0, 0). p(s(X), X). zero(0). no(X) :- ','(X, ','(!, failure(a))). no(X1). failure(b). Query: num(g) ---------------------------------------- (1) PrologToIRSwTTransformerProof (SOUND) Transformed Prolog program to IRSwT according to method in Master Thesis of A. Weinert { "root": 1, "program": { "directives": [], "clauses": [ [ "(num (0))", null ], [ "(num X)", "(',' (no (zero (0))) (',' (p X Y) (num Y)))" ], [ "(p (0) (0))", null ], [ "(p (s X) X)", null ], [ "(zero (0))", null ], [ "(no X)", "(',' X (',' (!) (failure (a))))" ], [ "(no X1)", null ], [ "(failure (b))", null ] ] }, "graph": { "nodes": { "22": { "goal": [ { "clause": 5, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" }, { "clause": 6, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "33": { "goal": [{ "clause": 7, "scope": 5, "term": "(',' (failure (a)) (',' (p T4 X6) (num X6)))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "12": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "13": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "35": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "25": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (',' (call (zero (0))) (',' (!_2) (failure (a)))) (',' (p T4 X6) (num X6)))" }, { "clause": 6, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "27": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (zero (0)) (',' (',' (!_2) (failure (a))) (',' (p T4 X6) (num X6))))" }, { "clause": -1, "scope": 3, "term": null }, { "clause": 6, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "28": { "goal": [ { "clause": 4, "scope": 4, "term": "(',' (zero (0)) (',' (',' (!_2) (failure (a))) (',' (p T4 X6) (num X6))))" }, { "clause": -1, "scope": 4, "term": null }, { "clause": -1, "scope": 3, "term": null }, { "clause": 6, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "18": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "type": "Nodes", "1": { "goal": [{ "clause": -1, "scope": -1, "term": "(num T1)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T1"], "free": [], "exprvars": [] } }, "5": { "goal": [ { "clause": 0, "scope": 1, "term": "(num T1)" }, { "clause": 1, "scope": 1, "term": "(num T1)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T1"], "free": [], "exprvars": [] } }, "8": { "goal": [{ "clause": 0, "scope": 1, "term": "(num T1)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T1"], "free": [], "exprvars": [] } }, "9": { "goal": [{ "clause": 1, "scope": 1, "term": "(num T1)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T1"], "free": [], "exprvars": [] } }, "20": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "31": { "goal": [ { "clause": -1, "scope": -1, "term": "(',' (',' (!_2) (failure (a))) (',' (p T4 X6) (num X6)))" }, { "clause": -1, "scope": 4, "term": null }, { "clause": -1, "scope": 3, "term": null }, { "clause": 6, "scope": 2, "term": "(',' (no (zero (0))) (',' (p T4 X6) (num X6)))" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } }, "32": { "goal": [{ "clause": -1, "scope": -1, "term": "(',' (failure (a)) (',' (p T4 X6) (num X6)))" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T4"], "free": ["X6"], "exprvars": [] } } }, "edges": [ { "from": 1, "to": 5, "label": "CASE" }, { "from": 5, "to": 8, "label": "PARALLEL" }, { "from": 5, "to": 9, "label": "PARALLEL" }, { "from": 8, "to": 12, "label": "EVAL with clause\nnum(0).\nand substitutionT1 -> 0" }, { "from": 8, "to": 13, "label": "EVAL-BACKTRACK" }, { "from": 9, "to": 20, "label": "ONLY EVAL with clause\nnum(X5) :- ','(no(zero(0)), ','(p(X5, X6), num(X6))).\nand substitutionT1 -> T4,\nX5 -> T4" }, { "from": 12, "to": 18, "label": "SUCCESS" }, { "from": 20, "to": 22, "label": "CASE" }, { "from": 22, "to": 25, "label": "ONLY EVAL with clause\nno(X9) :- ','(call(X9), ','(!_2, failure(a))).\nand substitutionX9 -> zero(0)" }, { "from": 25, "to": 27, "label": "CALL" }, { "from": 27, "to": 28, "label": "CASE" }, { "from": 28, "to": 31, "label": "ONLY EVAL with clause\nzero(0).\nand substitution" }, { "from": 31, "to": 32, "label": "CUT" }, { "from": 32, "to": 33, "label": "CASE" }, { "from": 33, "to": 35, "label": "BACKTRACK\nfor clause: failure(b)because of non-unification" } ], "type": "Graph" } } ---------------------------------------- (2) TRUE