We consider the system 1037. Alphabet: 0 : [] --> nat rec : [nat * nat * nat -> nat -> nat] --> nat s : [nat] --> nat v : [var] --> nat xplus : [nat * nat] --> nat xtimes : [nat * nat] --> nat Rules: xplus(X, 0) => X xplus(X, s(Y)) => s(xplus(X, Y)) rec(0, X, /\x./\y.Y(x, y)) => X rec(s(v(X)), Y, /\x./\y.Z(x, y)) => Z(v(X), rec(v(X), Y, /\z./\u.Z(z, u))) xtimes(X, Y) => rec(Y, 0, /\x./\y.xplus(X, y)) We use rule removal, following [Kop12, Theorem 2.23]. This gives the following requirements (possibly using Theorems 2.25 and 2.26 in [Kop12]): xplus(X, 0) >? X xplus(X, s(Y)) >? s(xplus(X, Y)) rec(0, X, /\x./\y.Y(x, y)) >? X rec(s(v(X)), Y, /\x./\y.Z(x, y)) >? Z(v(X), rec(v(X), Y, /\z./\u.Z(z, u))) xtimes(X, Y) >? rec(Y, 0, /\x./\y.xplus(X, y)) We use a recursive path ordering as defined in [Kop12, Chapter 5]. Argument functions: [[0]] = _|_ We choose Lex = {} and Mul = {rec, s, v, xplus, xtimes}, and the following precedence: xtimes > xplus > rec > s = v Taking the argument function into account, and fixing the greater / greater equal choices, the constraints can be denoted as follows: xplus(X, _|_) >= X xplus(X, s(Y)) >= s(xplus(X, Y)) rec(_|_, X, /\x./\y.Y(x, y)) > X rec(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) xtimes(X, Y) > rec(Y, _|_, /\x./\y.xplus(X, y)) With these choices, we have: 1] xplus(X, _|_) >= X because [2], by (Star) 2] xplus*(X, _|_) >= X because [3], by (Select) 3] X >= X by (Meta) 4] xplus(X, s(Y)) >= s(xplus(X, Y)) because [5], by (Star) 5] xplus*(X, s(Y)) >= s(xplus(X, Y)) because xplus > s and [6], by (Copy) 6] xplus*(X, s(Y)) >= xplus(X, Y) because xplus in Mul, [7] and [8], by (Stat) 7] X >= X by (Meta) 8] s(Y) > Y because [9], by definition 9] s*(Y) >= Y because [10], by (Select) 10] Y >= Y by (Meta) 11] rec(_|_, X, /\x./\y.Y(x, y)) > X because [12], by definition 12] rec*(_|_, X, /\x./\y.Y(x, y)) >= X because [13], by (Select) 13] X >= X by (Meta) 14] rec(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [15], by (Star) 15] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [16], by (Select) 16] Z(rec*(s(v(X)), Y, /\x./\y.Z(x, y)), rec*(s(v(X)), Y, /\z./\u.Z(z, u))) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [17] and [23], by (Meta) 17] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= v(X) because [18], by (Select) 18] s(v(X)) >= v(X) because [19], by (Star) 19] s*(v(X)) >= v(X) because s = v, s in Mul and [20], by (Stat) 20] v(X) > X because [21], by definition 21] v*(X) >= X because [22], by (Select) 22] X >= X by (Meta) 23] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= rec(v(X), Y, /\x./\y.Z(x, y)) because rec in Mul, [24], [26] and [27], by (Stat) 24] s(v(X)) > v(X) because [25], by definition 25] s*(v(X)) >= v(X) because s = v, s in Mul and [20], by (Stat) 26] Y >= Y by (Meta) 27] /\x./\z.Z(x, z) >= /\x./\z.Z(x, z) because [28], by (Abs) 28] /\z.Z(y, z) >= /\z.Z(y, z) because [29], by (Abs) 29] Z(y, x) >= Z(y, x) because [30] and [31], by (Meta) 30] y >= y by (Var) 31] x >= x by (Var) 32] xtimes(X, Y) > rec(Y, _|_, /\x./\y.xplus(X, y)) because [33], by definition 33] xtimes*(X, Y) >= rec(Y, _|_, /\x./\y.xplus(X, y)) because xtimes > rec, [34], [36] and [37], by (Copy) 34] xtimes*(X, Y) >= Y because [35], by (Select) 35] Y >= Y by (Meta) 36] xtimes*(X, Y) >= _|_ by (Bot) 37] xtimes*(X, Y) >= /\y./\z.xplus(X, z) because [38], by (F-Abs) 38] xtimes*(X, Y, x) >= /\z.xplus(X, z) because [39], by (F-Abs) 39] xtimes*(X, Y, x, y) >= xplus(X, y) because xtimes > xplus, [40] and [42], by (Copy) 40] xtimes*(X, Y, x, y) >= X because [41], by (Select) 41] X >= X by (Meta) 42] xtimes*(X, Y, x, y) >= y because [43], by (Select) 43] y >= y by (Var) We can thus remove the following rules: rec(0, X, /\x./\y.Y(x, y)) => X xtimes(X, Y) => rec(Y, 0, /\x./\y.xplus(X, y)) We use rule removal, following [Kop12, Theorem 2.23]. This gives the following requirements (possibly using Theorems 2.25 and 2.26 in [Kop12]): xplus(X, 0) >? X xplus(X, s(Y)) >? s(xplus(X, Y)) rec(s(v(X)), Y, /\x./\y.Z(x, y)) >? Z(v(X), rec(v(X), Y, /\z./\u.Z(z, u))) We use a recursive path ordering as defined in [Kop12, Chapter 5]. We choose Lex = {} and Mul = {0, rec, s, v, xplus}, and the following precedence: v > rec > 0 > xplus > s With these choices, we have: 1] xplus(X, 0) > X because [2], by definition 2] xplus*(X, 0) >= X because [3], by (Select) 3] X >= X by (Meta) 4] xplus(X, s(Y)) >= s(xplus(X, Y)) because [5], by (Star) 5] xplus*(X, s(Y)) >= s(xplus(X, Y)) because xplus > s and [6], by (Copy) 6] xplus*(X, s(Y)) >= xplus(X, Y) because xplus in Mul, [7] and [8], by (Stat) 7] X >= X by (Meta) 8] s(Y) > Y because [9], by definition 9] s*(Y) >= Y because [10], by (Select) 10] Y >= Y by (Meta) 11] rec(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [12], by (Star) 12] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [13], by (Select) 13] Z(rec*(s(v(X)), Y, /\x./\y.Z(x, y)), rec*(s(v(X)), Y, /\z./\u.Z(z, u))) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [14] and [19], by (Meta) 14] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= v(X) because [15], by (Select) 15] s(v(X)) >= v(X) because [16], by (Star) 16] s*(v(X)) >= v(X) because [17], by (Select) 17] v(X) >= v(X) because v in Mul and [18], by (Fun) 18] X >= X by (Meta) 19] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= rec(v(X), Y, /\x./\y.Z(x, y)) because rec in Mul, [20], [22] and [23], by (Stat) 20] s(v(X)) > v(X) because [21], by definition 21] s*(v(X)) >= v(X) because [17], by (Select) 22] Y >= Y by (Meta) 23] /\x./\z.Z(x, z) >= /\x./\z.Z(x, z) because [24], by (Abs) 24] /\z.Z(y, z) >= /\z.Z(y, z) because [25], by (Abs) 25] Z(y, x) >= Z(y, x) because [26] and [27], by (Meta) 26] y >= y by (Var) 27] x >= x by (Var) We can thus remove the following rules: xplus(X, 0) => X We use rule removal, following [Kop12, Theorem 2.23]. This gives the following requirements (possibly using Theorems 2.25 and 2.26 in [Kop12]): xplus(X, s(Y)) >? s(xplus(X, Y)) rec(s(v(X)), Y, /\x./\y.Z(x, y)) >? Z(v(X), rec(v(X), Y, /\z./\u.Z(z, u))) We use a recursive path ordering as defined in [Kop12, Chapter 5]. Argument functions: [[rec(x_1, x_2, x_3)]] = rec(x_3, x_2, x_1) We choose Lex = {rec} and Mul = {s, v, xplus}, and the following precedence: rec > xplus > s > v Taking the argument function into account, and fixing the greater / greater equal choices, the constraints can be denoted as follows: xplus(X, s(Y)) >= s(xplus(X, Y)) rec(s(v(X)), Y, /\x./\y.Z(x, y)) > Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) With these choices, we have: 1] xplus(X, s(Y)) >= s(xplus(X, Y)) because [2], by (Star) 2] xplus*(X, s(Y)) >= s(xplus(X, Y)) because xplus > s and [3], by (Copy) 3] xplus*(X, s(Y)) >= xplus(X, Y) because xplus in Mul, [4] and [5], by (Stat) 4] X >= X by (Meta) 5] s(Y) > Y because [6], by definition 6] s*(Y) >= Y because [7], by (Select) 7] Y >= Y by (Meta) 8] rec(s(v(X)), Y, /\x./\y.Z(x, y)) > Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [9], by definition 9] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [10], by (Select) 10] Z(rec*(s(v(X)), Y, /\x./\y.Z(x, y)), rec*(s(v(X)), Y, /\z./\u.Z(z, u))) >= Z(v(X), rec(v(X), Y, /\x./\y.Z(x, y))) because [11] and [18], by (Meta) 11] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= v(X) because [12], by (Select) 12] s(v(X)) >= v(X) because [13], by (Star) 13] s*(v(X)) >= v(X) because s > v and [14], by (Copy) 14] s*(v(X)) >= X because [15], by (Select) 15] v(X) >= X because [16], by (Star) 16] v*(X) >= X because [17], by (Select) 17] X >= X by (Meta) 18] rec*(s(v(X)), Y, /\x./\y.Z(x, y)) >= rec(v(X), Y, /\x./\y.Z(x, y)) because [19], [21], [22], [11], [27] and [28], by (Stat) 19] s(v(X)) > v(X) because [20], by definition 20] s*(v(X)) >= v(X) because s > v and [14], by (Copy) 21] Y >= Y by (Meta) 22] /\x./\z.Z(x, z) >= /\x./\z.Z(x, z) because [23], by (Abs) 23] /\z.Z(y, z) >= /\z.Z(y, z) because [24], by (Abs) 24] Z(y, x) >= Z(y, x) because [25] and [26], by (Meta) 25] y >= y by (Var) 26] x >= x by (Var) 27] rec*(s(v(X)), Y, /\z./\u.Z(z, u)) >= Y because [21], by (Select) 28] rec*(s(v(X)), Y, /\z./\u.Z(z, u)) >= /\z./\u.Z(z, u) because [29], by (F-Abs) 29] rec*(s(v(X)), Y, /\z./\u.Z(z, u), w) >= /\z.Z(w, z) because [30], by (Select) 30] /\z.Z(rec*(s(v(X)), Y, /\u./\y'.Z(u, y'), w), z) >= /\z.Z(w, z) because [31], by (Abs) 31] Z(rec*(s(v(X)), Y, /\z./\u.Z(z, u), w), x') >= Z(w, x') because [32] and [34], by (Meta) 32] rec*(s(v(X)), Y, /\z./\u.Z(z, u), w) >= w because [33], by (Select) 33] w >= w by (Var) 34] x' >= x' by (Var) We can thus remove the following rules: rec(s(v(X)), Y, /\x./\y.Z(x, y)) => Z(v(X), rec(v(X), Y, /\z./\u.Z(z, u))) We use rule removal, following [Kop12, Theorem 2.23]. This gives the following requirements (possibly using Theorems 2.25 and 2.26 in [Kop12]): xplus(X, s(Y)) >? s(xplus(X, Y)) We orient these requirements with a polynomial interpretation in the natural numbers. The following interpretation satisfies the requirements: s = \y0.1 + y0 xplus = \y0y1.y0 + 3y1 Using this interpretation, the requirements translate to: [[xplus(_x0, s(_x1))]] = 3 + x0 + 3x1 > 1 + x0 + 3x1 = [[s(xplus(_x0, _x1))]] We can thus remove the following rules: xplus(X, s(Y)) => s(xplus(X, Y)) All rules were succesfully removed. Thus, termination of the original system has been reduced to termination of the beta-rule, which is well-known to hold. +++ Citations +++ [Kop12] C. Kop. Higher Order Termination. PhD Thesis, 2012.