2.09/1.01 YES 2.26/1.01 We consider the system theBenchmark. 2.26/1.01 2.26/1.01 Alphabet: 2.26/1.01 2.26/1.01 0 : [] --> c 2.26/1.01 cons : [a * b] --> b 2.26/1.01 div : [c * c] --> c 2.26/1.01 map : [a -> a * b] --> b 2.26/1.01 minus : [c * c] --> c 2.26/1.01 nil : [] --> b 2.26/1.01 p : [c] --> c 2.26/1.01 s : [c] --> c 2.26/1.01 2.26/1.01 Rules: 2.26/1.01 2.26/1.01 map(f, nil) => nil 2.26/1.01 map(f, cons(x, y)) => cons(f x, map(f, y)) 2.26/1.01 minus(x, 0) => x 2.26/1.01 minus(s(x), s(y)) => minus(p(s(x)), p(s(y))) 2.26/1.01 p(s(x)) => x 2.26/1.01 div(0, s(x)) => 0 2.26/1.01 div(s(x), s(y)) => s(div(minus(x, y), s(y))) 2.26/1.01 2.26/1.01 This AFS is converted to an AFSM simply by replacing all free variables by meta-variables (with arity 0). 2.26/1.01 2.26/1.01 We observe that the rules contain a first-order subset: 2.26/1.01 2.26/1.01 minus(X, 0) => X 2.26/1.01 minus(s(X), s(Y)) => minus(p(s(X)), p(s(Y))) 2.26/1.01 p(s(X)) => X 2.26/1.01 div(0, s(X)) => 0 2.26/1.01 div(s(X), s(Y)) => s(div(minus(X, Y), s(Y))) 2.26/1.01 2.26/1.01 Moreover, the system is orthogonal. Thus, by [Kop12, Thm. 7.55], we may omit all first-order dependency pairs from the dependency pair problem (DP(R), R) if this first-order part is terminating when seen as a many-sorted first-order TRS. 2.26/1.01 2.26/1.01 According to the external first-order termination prover, this system is indeed terminating: 2.26/1.01 2.26/1.01 || proof of resources/system.trs 2.26/1.01 || # AProVE Commit ID: d84c10301d352dfd14de2104819581f4682260f5 fuhs 20130616 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || Termination w.r.t. Q of the given QTRS could be proven: 2.26/1.01 || 2.26/1.01 || (0) QTRS 2.26/1.01 || (1) Overlay + Local Confluence [EQUIVALENT] 2.26/1.01 || (2) QTRS 2.26/1.01 || (3) DependencyPairsProof [EQUIVALENT] 2.26/1.01 || (4) QDP 2.26/1.01 || (5) DependencyGraphProof [EQUIVALENT] 2.26/1.01 || (6) AND 2.26/1.01 || (7) QDP 2.26/1.01 || (8) UsableRulesProof [EQUIVALENT] 2.26/1.01 || (9) QDP 2.26/1.01 || (10) QReductionProof [EQUIVALENT] 2.26/1.01 || (11) QDP 2.26/1.01 || (12) MRRProof [EQUIVALENT] 2.26/1.01 || (13) QDP 2.26/1.01 || (14) DependencyGraphProof [EQUIVALENT] 2.26/1.01 || (15) TRUE 2.26/1.01 || (16) QDP 2.26/1.01 || (17) UsableRulesProof [EQUIVALENT] 2.26/1.01 || (18) QDP 2.26/1.01 || (19) QReductionProof [EQUIVALENT] 2.26/1.01 || (20) QDP 2.26/1.01 || (21) QDPOrderProof [EQUIVALENT] 2.26/1.01 || (22) QDP 2.26/1.01 || (23) PisEmptyProof [EQUIVALENT] 2.26/1.01 || (24) YES 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (0) 2.26/1.01 || Obligation: 2.26/1.01 || Q restricted rewrite system: 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || minus(%X, 0) -> %X 2.26/1.01 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || div(0, s(%X)) -> 0 2.26/1.01 || div(s(%X), s(%Y)) -> s(div(minus(%X, %Y), s(%Y))) 2.26/1.01 || 2.26/1.01 || Q is empty. 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (1) Overlay + Local Confluence (EQUIVALENT) 2.26/1.01 || The TRS is overlay and locally confluent. By [NOC] we can switch to innermost. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (2) 2.26/1.01 || Obligation: 2.26/1.01 || Q restricted rewrite system: 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || minus(%X, 0) -> %X 2.26/1.01 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || div(0, s(%X)) -> 0 2.26/1.01 || div(s(%X), s(%Y)) -> s(div(minus(%X, %Y), s(%Y))) 2.26/1.01 || 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || minus(x0, 0) 2.26/1.01 || minus(s(x0), s(x1)) 2.26/1.01 || p(s(x0)) 2.26/1.01 || div(0, s(x0)) 2.26/1.01 || div(s(x0), s(x1)) 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (3) DependencyPairsProof (EQUIVALENT) 2.26/1.01 || Using Dependency Pairs [AG00,LPAR04] we result in the following initial DP problem. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (4) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || MINUS(s(%X), s(%Y)) -> MINUS(p(s(%X)), p(s(%Y))) 2.26/1.01 || MINUS(s(%X), s(%Y)) -> P(s(%X)) 2.26/1.01 || MINUS(s(%X), s(%Y)) -> P(s(%Y)) 2.26/1.01 || DIV(s(%X), s(%Y)) -> DIV(minus(%X, %Y), s(%Y)) 2.26/1.01 || DIV(s(%X), s(%Y)) -> MINUS(%X, %Y) 2.26/1.01 || 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || minus(%X, 0) -> %X 2.26/1.01 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || div(0, s(%X)) -> 0 2.26/1.01 || div(s(%X), s(%Y)) -> s(div(minus(%X, %Y), s(%Y))) 2.26/1.01 || 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || minus(x0, 0) 2.26/1.01 || minus(s(x0), s(x1)) 2.26/1.01 || p(s(x0)) 2.26/1.01 || div(0, s(x0)) 2.26/1.01 || div(s(x0), s(x1)) 2.26/1.01 || 2.26/1.01 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (5) DependencyGraphProof (EQUIVALENT) 2.26/1.01 || The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 2 SCCs with 3 less nodes. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (6) 2.26/1.01 || Complex Obligation (AND) 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (7) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || MINUS(s(%X), s(%Y)) -> MINUS(p(s(%X)), p(s(%Y))) 2.26/1.01 || 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || minus(%X, 0) -> %X 2.26/1.01 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || div(0, s(%X)) -> 0 2.26/1.01 || div(s(%X), s(%Y)) -> s(div(minus(%X, %Y), s(%Y))) 2.26/1.01 || 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || minus(x0, 0) 2.26/1.01 || minus(s(x0), s(x1)) 2.26/1.01 || p(s(x0)) 2.26/1.01 || div(0, s(x0)) 2.26/1.01 || div(s(x0), s(x1)) 2.26/1.01 || 2.26/1.01 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (8) UsableRulesProof (EQUIVALENT) 2.26/1.01 || 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. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (9) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || MINUS(s(%X), s(%Y)) -> MINUS(p(s(%X)), p(s(%Y))) 2.26/1.01 || 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || minus(x0, 0) 2.26/1.01 || minus(s(x0), s(x1)) 2.26/1.01 || p(s(x0)) 2.26/1.01 || div(0, s(x0)) 2.26/1.01 || div(s(x0), s(x1)) 2.26/1.01 || 2.26/1.01 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (10) QReductionProof (EQUIVALENT) 2.26/1.01 || We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN]. 2.26/1.01 || 2.26/1.01 || minus(x0, 0) 2.26/1.01 || minus(s(x0), s(x1)) 2.26/1.01 || div(0, s(x0)) 2.26/1.01 || div(s(x0), s(x1)) 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (11) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || MINUS(s(%X), s(%Y)) -> MINUS(p(s(%X)), p(s(%Y))) 2.26/1.01 || 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || p(s(x0)) 2.26/1.01 || 2.26/1.01 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (12) MRRProof (EQUIVALENT) 2.26/1.01 || By using the rule removal processor [LPAR04] with the following ordering, at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented. 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || Strictly oriented rules of the TRS R: 2.26/1.01 || 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || 2.26/1.01 || Used ordering: Polynomial interpretation [POLO]: 2.26/1.01 || 2.26/1.01 || POL(MINUS(x_1, x_2)) = 2*x_1 + 2*x_2 2.26/1.01 || POL(p(x_1)) = x_1 2.26/1.01 || POL(s(x_1)) = 2 + x_1 2.26/1.01 || 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (13) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || MINUS(s(%X), s(%Y)) -> MINUS(p(s(%X)), p(s(%Y))) 2.26/1.01 || 2.26/1.01 || R is empty. 2.26/1.01 || The set Q consists of the following terms: 2.26/1.01 || 2.26/1.01 || p(s(x0)) 2.26/1.01 || 2.26/1.01 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (14) DependencyGraphProof (EQUIVALENT) 2.26/1.01 || The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 0 SCCs with 1 less node. 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (15) 2.26/1.01 || TRUE 2.26/1.01 || 2.26/1.01 || ---------------------------------------- 2.26/1.01 || 2.26/1.01 || (16) 2.26/1.01 || Obligation: 2.26/1.01 || Q DP problem: 2.26/1.01 || The TRS P consists of the following rules: 2.26/1.01 || 2.26/1.01 || DIV(s(%X), s(%Y)) -> DIV(minus(%X, %Y), s(%Y)) 2.26/1.01 || 2.26/1.01 || The TRS R consists of the following rules: 2.26/1.01 || 2.26/1.01 || minus(%X, 0) -> %X 2.26/1.01 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.01 || p(s(%X)) -> %X 2.26/1.01 || div(0, s(%X)) -> 0 2.26/1.01 || div(s(%X), s(%Y)) -> s(div(minus(%X, %Y), s(%Y))) 2.26/1.02 || 2.26/1.02 || The set Q consists of the following terms: 2.26/1.02 || 2.26/1.02 || minus(x0, 0) 2.26/1.02 || minus(s(x0), s(x1)) 2.26/1.02 || p(s(x0)) 2.26/1.02 || div(0, s(x0)) 2.26/1.02 || div(s(x0), s(x1)) 2.26/1.02 || 2.26/1.02 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (17) UsableRulesProof (EQUIVALENT) 2.26/1.02 || 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. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (18) 2.26/1.02 || Obligation: 2.26/1.02 || Q DP problem: 2.26/1.02 || The TRS P consists of the following rules: 2.26/1.02 || 2.26/1.02 || DIV(s(%X), s(%Y)) -> DIV(minus(%X, %Y), s(%Y)) 2.26/1.02 || 2.26/1.02 || The TRS R consists of the following rules: 2.26/1.02 || 2.26/1.02 || minus(%X, 0) -> %X 2.26/1.02 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.02 || p(s(%X)) -> %X 2.26/1.02 || 2.26/1.02 || The set Q consists of the following terms: 2.26/1.02 || 2.26/1.02 || minus(x0, 0) 2.26/1.02 || minus(s(x0), s(x1)) 2.26/1.02 || p(s(x0)) 2.26/1.02 || div(0, s(x0)) 2.26/1.02 || div(s(x0), s(x1)) 2.26/1.02 || 2.26/1.02 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (19) QReductionProof (EQUIVALENT) 2.26/1.02 || We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.[THIEMANN]. 2.26/1.02 || 2.26/1.02 || div(0, s(x0)) 2.26/1.02 || div(s(x0), s(x1)) 2.26/1.02 || 2.26/1.02 || 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (20) 2.26/1.02 || Obligation: 2.26/1.02 || Q DP problem: 2.26/1.02 || The TRS P consists of the following rules: 2.26/1.02 || 2.26/1.02 || DIV(s(%X), s(%Y)) -> DIV(minus(%X, %Y), s(%Y)) 2.26/1.02 || 2.26/1.02 || The TRS R consists of the following rules: 2.26/1.02 || 2.26/1.02 || minus(%X, 0) -> %X 2.26/1.02 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.02 || p(s(%X)) -> %X 2.26/1.02 || 2.26/1.02 || The set Q consists of the following terms: 2.26/1.02 || 2.26/1.02 || minus(x0, 0) 2.26/1.02 || minus(s(x0), s(x1)) 2.26/1.02 || p(s(x0)) 2.26/1.02 || 2.26/1.02 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (21) QDPOrderProof (EQUIVALENT) 2.26/1.02 || We use the reduction pair processor [LPAR04,JAR06]. 2.26/1.02 || 2.26/1.02 || 2.26/1.02 || The following pairs can be oriented strictly and are deleted. 2.26/1.02 || 2.26/1.02 || DIV(s(%X), s(%Y)) -> DIV(minus(%X, %Y), s(%Y)) 2.26/1.02 || The remaining pairs can at least be oriented weakly. 2.26/1.02 || Used ordering: Polynomial interpretation [POLO]: 2.26/1.02 || 2.26/1.02 || POL(0) = 0 2.26/1.02 || POL(DIV(x_1, x_2)) = x_1 2.26/1.02 || POL(minus(x_1, x_2)) = x_1 2.26/1.02 || POL(p(x_1)) = x_1 2.26/1.02 || POL(s(x_1)) = 1 + x_1 2.26/1.02 || 2.26/1.02 || The following usable rules [FROCOS05] with respect to the argument filtering of the ordering [JAR06] were oriented: 2.26/1.02 || 2.26/1.02 || minus(%X, 0) -> %X 2.26/1.02 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.02 || p(s(%X)) -> %X 2.26/1.02 || 2.26/1.02 || 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (22) 2.26/1.02 || Obligation: 2.26/1.02 || Q DP problem: 2.26/1.02 || P is empty. 2.26/1.02 || The TRS R consists of the following rules: 2.26/1.02 || 2.26/1.02 || minus(%X, 0) -> %X 2.26/1.02 || minus(s(%X), s(%Y)) -> minus(p(s(%X)), p(s(%Y))) 2.26/1.02 || p(s(%X)) -> %X 2.26/1.02 || 2.26/1.02 || The set Q consists of the following terms: 2.26/1.02 || 2.26/1.02 || minus(x0, 0) 2.26/1.02 || minus(s(x0), s(x1)) 2.26/1.02 || p(s(x0)) 2.26/1.02 || 2.26/1.02 || We have to consider all minimal (P,Q,R)-chains. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (23) PisEmptyProof (EQUIVALENT) 2.26/1.02 || The TRS P is empty. Hence, there is no (P,Q,R) chain. 2.26/1.02 || ---------------------------------------- 2.26/1.02 || 2.26/1.02 || (24) 2.26/1.02 || YES 2.26/1.02 || 2.26/1.02 We use the dependency pair framework as described in [Kop12, Ch. 6/7], with static dependency pairs (see [KusIsoSakBla09] and the adaptation for AFSMs and accessible arguments in [Kop13]). 2.26/1.02 2.26/1.02 We thus obtain the following dependency pair problem (P_0, R_0, static, formative): 2.26/1.02 2.26/1.02 Dependency Pairs P_0: 2.26/1.02 2.26/1.02 0] map#(F, cons(X, Y)) =#> map#(F, Y) 2.26/1.02 2.26/1.02 Rules R_0: 2.26/1.02 2.26/1.02 map(F, nil) => nil 2.26/1.02 map(F, cons(X, Y)) => cons(F X, map(F, Y)) 2.26/1.02 minus(X, 0) => X 2.26/1.02 minus(s(X), s(Y)) => minus(p(s(X)), p(s(Y))) 2.26/1.02 p(s(X)) => X 2.26/1.02 div(0, s(X)) => 0 2.26/1.02 div(s(X), s(Y)) => s(div(minus(X, Y), s(Y))) 2.26/1.02 2.26/1.02 Thus, the original system is terminating if (P_0, R_0, static, formative) is finite. 2.26/1.02 2.26/1.02 We consider the dependency pair problem (P_0, R_0, static, formative). 2.26/1.02 2.26/1.02 We apply the subterm criterion with the following projection function: 2.26/1.02 2.26/1.02 nu(map#) = 2 2.26/1.02 2.26/1.02 Thus, we can orient the dependency pairs as follows: 2.26/1.02 2.26/1.02 nu(map#(F, cons(X, Y))) = cons(X, Y) |> Y = nu(map#(F, Y)) 2.26/1.02 2.26/1.02 By [Kop12, Thm. 7.35] and [Kop13, Thm. 5], we may replace a dependency pair problem (P_0, R_0, static, f) by ({}, R_0, static, f). By the empty set processor [Kop12, Thm. 7.15] this problem may be immediately removed. 2.26/1.02 2.26/1.02 As all dependency pair problems were succesfully simplified with sound (and complete) processors until nothing remained, we conclude termination. 2.26/1.02 2.26/1.02 2.26/1.02 +++ Citations +++ 2.26/1.02 2.26/1.02 [Kop12] C. Kop. Higher Order Termination. PhD Thesis, 2012. 2.26/1.02 [Kop13] C. Kop. Static Dependency Pairs with Accessibility. Unpublished manuscript, http://cl-informatik.uibk.ac.at/users/kop/static.pdf, 2013. 2.26/1.02 [KusIsoSakBla09] K. Kusakari, Y. Isogai, M. Sakai, and F. Blanqui. Static Dependency Pair Method Based On Strong Computability for Higher-Order Rewrite Systems. In volume 92(10) of IEICE Transactions on Information and Systems. 2007--2015, 2009. 2.26/1.02 EOF