/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 app(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, 0 ms] (4) PiDP (5) DependencyGraphProof [EQUIVALENT, 0 ms] (6) PiDP (7) PiDPToQDPProof [SOUND, 5 ms] (8) QDP (9) QDPSizeChangeProof [EQUIVALENT, 0 ms] (10) YES ---------------------------------------- (0) Obligation: Clauses: app([], X, X). app(.(X, Xs), Ys, .(X, Zs)) :- app(Xs, Ys, Zs). Query: app(g,g,a) ---------------------------------------- (1) PrologToDTProblemTransformerProof (SOUND) Built DT problem from termination graph DT10. { "root": 3, "program": { "directives": [], "clauses": [ [ "(app ([]) X X)", null ], [ "(app (. X Xs) Ys (. X Zs))", "(app Xs Ys Zs)" ] ] }, "graph": { "nodes": { "77": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "88": { "goal": [{ "clause": -1, "scope": -1, "term": "(app T29 T30 T32)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T29", "T30" ], "free": [], "exprvars": [] } }, "89": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "79": { "goal": [{ "clause": -1, "scope": -1, "term": "(app T11 T12 T14)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T11", "T12" ], "free": [], "exprvars": [] } }, "type": "Nodes", "3": { "goal": [{ "clause": -1, "scope": -1, "term": "(app T1 T2 T3)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "5": { "goal": [ { "clause": 0, "scope": 1, "term": "(app T1 T2 T3)" }, { "clause": 1, "scope": 1, "term": "(app T1 T2 T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": [], "exprvars": [] } }, "81": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "82": { "goal": [ { "clause": 0, "scope": 2, "term": "(app T11 T12 T14)" }, { "clause": 1, "scope": 2, "term": "(app T11 T12 T14)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T11", "T12" ], "free": [], "exprvars": [] } }, "83": { "goal": [{ "clause": 0, "scope": 2, "term": "(app T11 T12 T14)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T11", "T12" ], "free": [], "exprvars": [] } }, "73": { "goal": [ { "clause": -1, "scope": -1, "term": "(true)" }, { "clause": 1, "scope": 1, "term": "(app ([]) T5 T3)" } ], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T5"], "free": [], "exprvars": [] } }, "84": { "goal": [{ "clause": 1, "scope": 2, "term": "(app T11 T12 T14)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T11", "T12" ], "free": [], "exprvars": [] } }, "85": { "goal": [{ "clause": -1, "scope": -1, "term": "(true)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "75": { "goal": [{ "clause": 1, "scope": 1, "term": "(app T1 T2 T3)" }], "kb": { "nonunifying": [[ "(app T1 T2 T3)", "(app ([]) X2 X2)" ]], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [ "T1", "T2" ], "free": ["X2"], "exprvars": [] } }, "86": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } }, "76": { "goal": [{ "clause": 1, "scope": 1, "term": "(app ([]) T5 T3)" }], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": ["T5"], "free": [], "exprvars": [] } }, "87": { "goal": [], "kb": { "nonunifying": [], "intvars": {}, "arithmetic": { "type": "PlainIntegerRelationState", "relations": [] }, "ground": [], "free": [], "exprvars": [] } } }, "edges": [ { "from": 3, "to": 5, "label": "CASE" }, { "from": 5, "to": 73, "label": "EVAL with clause\napp([], X2, X2).\nand substitutionT1 -> [],\nT2 -> T5,\nX2 -> T5,\nT3 -> T5" }, { "from": 5, "to": 75, "label": "EVAL-BACKTRACK" }, { "from": 73, "to": 76, "label": "SUCCESS" }, { "from": 75, "to": 79, "label": "EVAL with clause\napp(.(X11, X12), X13, .(X11, X14)) :- app(X12, X13, X14).\nand substitutionX11 -> T10,\nX12 -> T11,\nT1 -> .(T10, T11),\nT2 -> T12,\nX13 -> T12,\nX14 -> T14,\nT3 -> .(T10, T14),\nT13 -> T14" }, { "from": 75, "to": 81, "label": "EVAL-BACKTRACK" }, { "from": 76, "to": 77, "label": "BACKTRACK\nfor clause: app(.(X, Xs), Ys, .(X, Zs)) :- app(Xs, Ys, Zs)because of non-unification" }, { "from": 79, "to": 82, "label": "CASE" }, { "from": 82, "to": 83, "label": "PARALLEL" }, { "from": 82, "to": 84, "label": "PARALLEL" }, { "from": 83, "to": 85, "label": "EVAL with clause\napp([], X19, X19).\nand substitutionT11 -> [],\nT12 -> T19,\nX19 -> T19,\nT14 -> T19" }, { "from": 83, "to": 86, "label": "EVAL-BACKTRACK" }, { "from": 84, "to": 88, "label": "EVAL with clause\napp(.(X28, X29), X30, .(X28, X31)) :- app(X29, X30, X31).\nand substitutionX28 -> T28,\nX29 -> T29,\nT11 -> .(T28, T29),\nT12 -> T30,\nX30 -> T30,\nX31 -> T32,\nT14 -> .(T28, T32),\nT31 -> T32" }, { "from": 84, "to": 89, "label": "EVAL-BACKTRACK" }, { "from": 85, "to": 87, "label": "SUCCESS" }, { "from": 88, "to": 3, "label": "INSTANCE with matching:\nT1 -> T29\nT2 -> T30\nT3 -> T32" } ], "type": "Graph" } } ---------------------------------------- (2) Obligation: Triples: appA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) :- appA(X3, X4, X5). Clauses: appcA([], X1, X1). appcA(.(X1, []), X2, .(X1, X2)). appcA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) :- appcA(X3, X4, X5). Afs: appA(x1, x2, x3) = appA(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: appA_in_3: (b,b,f) Transforming TRIPLES into the following Term Rewriting System: Pi DP problem: The TRS P consists of the following rules: APPA_IN_GGA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) -> U1_GGA(X1, X2, X3, X4, X5, appA_in_gga(X3, X4, X5)) APPA_IN_GGA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) -> APPA_IN_GGA(X3, X4, X5) R is empty. The argument filtering Pi contains the following mapping: appA_in_gga(x1, x2, x3) = appA_in_gga(x1, x2) .(x1, x2) = .(x1, x2) APPA_IN_GGA(x1, x2, x3) = APPA_IN_GGA(x1, x2) U1_GGA(x1, x2, x3, x4, x5, x6) = U1_GGA(x1, x2, x3, x4, x6) 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: APPA_IN_GGA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) -> U1_GGA(X1, X2, X3, X4, X5, appA_in_gga(X3, X4, X5)) APPA_IN_GGA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) -> APPA_IN_GGA(X3, X4, X5) R is empty. The argument filtering Pi contains the following mapping: appA_in_gga(x1, x2, x3) = appA_in_gga(x1, x2) .(x1, x2) = .(x1, x2) APPA_IN_GGA(x1, x2, x3) = APPA_IN_GGA(x1, x2) U1_GGA(x1, x2, x3, x4, x5, x6) = U1_GGA(x1, x2, x3, x4, x6) We have to consider all (P,R,Pi)-chains ---------------------------------------- (5) DependencyGraphProof (EQUIVALENT) The approximation of the Dependency Graph [LOPSTR] contains 1 SCC with 1 less node. ---------------------------------------- (6) Obligation: Pi DP problem: The TRS P consists of the following rules: APPA_IN_GGA(.(X1, .(X2, X3)), X4, .(X1, .(X2, X5))) -> APPA_IN_GGA(X3, X4, X5) R is empty. The argument filtering Pi contains the following mapping: .(x1, x2) = .(x1, x2) APPA_IN_GGA(x1, x2, x3) = APPA_IN_GGA(x1, x2) We have to consider all (P,R,Pi)-chains ---------------------------------------- (7) PiDPToQDPProof (SOUND) Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi. ---------------------------------------- (8) Obligation: Q DP problem: The TRS P consists of the following rules: APPA_IN_GGA(.(X1, .(X2, X3)), X4) -> APPA_IN_GGA(X3, X4) R is empty. Q is empty. We have to consider all (P,Q,R)-chains. ---------------------------------------- (9) 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: *APPA_IN_GGA(.(X1, .(X2, X3)), X4) -> APPA_IN_GGA(X3, X4) The graph contains the following edges 1 > 1, 2 >= 2 ---------------------------------------- (10) YES