We consider the system Applicative_05__BTreeMember. Alphabet: 0 : [] --> a eq : [a * a] --> c false : [] --> c fork : [b * a * b] --> b if : [c * c * c] --> c lt : [a * a] --> c member : [a * b] --> c null : [] --> b s : [a] --> a true : [] --> c Rules: lt(s(x), s(y)) => lt(x, y) lt(0, s(x)) => true lt(x, 0) => false eq(x, x) => true eq(s(x), 0) => false eq(0, s(x)) => false member(x, null) => false member(x, fork(y, z, u)) => if(lt(x, z), member(x, y), if(eq(x, z), true, member(x, u))) This AFS is converted to an AFSM simply by replacing all free variables by meta-variables (with arity 0). 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]). We thus obtain the following dependency pair problem (P_0, R_0, static, all): Dependency Pairs P_0: 0] lt#(s(X), s(Y)) =#> lt#(X, Y) 1] member#(X, fork(Y, Z, U)) =#> lt#(X, Z) 2] member#(X, fork(Y, Z, U)) =#> member#(X, Y) 3] member#(X, fork(Y, Z, U)) =#> eq#(X, Z) 4] member#(X, fork(Y, Z, U)) =#> member#(X, U) Rules R_0: lt(s(X), s(Y)) => lt(X, Y) lt(0, s(X)) => true lt(X, 0) => false eq(X, X) => true eq(s(X), 0) => false eq(0, s(X)) => false member(X, null) => false member(X, fork(Y, Z, U)) => if(lt(X, Z), member(X, Y), if(eq(X, Z), true, member(X, U))) Thus, the original system is terminating if (P_0, R_0, static, all) is finite. We consider the dependency pair problem (P_0, R_0, static, all). We apply the subterm criterion with the following projection function: nu(eq#) = 1 nu(lt#) = 1 nu(member#) = 1 Thus, we can orient the dependency pairs as follows: nu(lt#(s(X), s(Y))) = s(X) |> X = nu(lt#(X, Y)) nu(member#(X, fork(Y, Z, U))) = X = X = nu(lt#(X, Z)) nu(member#(X, fork(Y, Z, U))) = X = X = nu(member#(X, Y)) nu(member#(X, fork(Y, Z, U))) = X = X = nu(eq#(X, Z)) nu(member#(X, fork(Y, Z, U))) = X = X = nu(member#(X, U)) By [Kop12, Thm. 7.35] and [Kop13, Thm. 5], we may replace a dependency pair problem (P_0, R_0, static, f) by (P_1, R_0, static, f), where P_1 contains: member#(X, fork(Y, Z, U)) =#> lt#(X, Z) member#(X, fork(Y, Z, U)) =#> member#(X, Y) member#(X, fork(Y, Z, U)) =#> eq#(X, Z) member#(X, fork(Y, Z, U)) =#> member#(X, U) Thus, the original system is terminating if (P_1, R_0, static, all) is finite. We consider the dependency pair problem (P_1, R_0, static, all). We apply the subterm criterion with the following projection function: nu(eq#) = 2 nu(lt#) = 2 nu(member#) = 2 Thus, we can orient the dependency pairs as follows: nu(member#(X, fork(Y, Z, U))) = fork(Y, Z, U) |> Z = nu(lt#(X, Z)) nu(member#(X, fork(Y, Z, U))) = fork(Y, Z, U) |> Y = nu(member#(X, Y)) nu(member#(X, fork(Y, Z, U))) = fork(Y, Z, U) |> Z = nu(eq#(X, Z)) nu(member#(X, fork(Y, Z, U))) = fork(Y, Z, U) |> U = nu(member#(X, U)) By [Kop12, Thm. 7.35] and [Kop13, Thm. 5], we may replace a dependency pair problem (P_1, R_0, static, f) by ({}, R_0, static, f). By the empty set processor [Kop12, Thm. 7.15] this problem may be immediately removed. As all dependency pair problems were succesfully simplified with sound (and complete) processors until nothing remained, we conclude termination. +++ Citations +++ [Kop12] C. Kop. Higher Order Termination. PhD Thesis, 2012. [Kop13] C. Kop. Static Dependency Pairs with Accessibility. Unpublished manuscript, http://cl-informatik.uibk.ac.at/users/kop/static.pdf, 2013. [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.